The MakeCode Forums 3: The Multiversal Convergence

Hey um @ChimbroDaPro is it okay if I use vortex in one of my games? He’ll just be mentioned but I understand if no

3 Likes

Chimbro made a topic about how people use his characters.

5 Likes

Yo @ChimbroDaPro could you guide me in the art of the specific making of such game?

Oh yeah sure! So long as it works with what @CopySprite sent

2 Likes

Oh uh, I mean, sure! What do you wanna know?

1 Like

How did you make the text boxes for the game?

Oh sure, I mean my method was extremely straightforward since I was extremely stupid but yeah sure, I’ll try to explain it! Basically all I did was set it up as two big functions, one that kind of builds the UI for the actual topic screen with inputs of every specific thing you want to personalise the first post, and one that changes the post after a given period of time as an input for the function as well as more personalisation inputs.

Like this basically (its my first time trying to pseudocode PLEASE DONT SUE ME!):

function setupTopic(userImage, userMessage, userName) {
    // organise all that stuff 
    let myTextSprite = textStuff(userName)
    let userImg = spriteThing(userImage, Post)
    myTextSprite.position(x,y)
    userImg.position(x,y)
    // more post specific stuff here
    
    /* do that for userMessage and any other thing you want, 
    like a like button or something
    or a like counter
    or something */

    // then you add all your UI Sprites like the reply button etc
}

The setup function literally just sets up the actual scene of the new area, and once you have all the variables defined in it, you can use the second function to move the topic along, mainly by moving all the “post” parts up and remaking them with the first part of the setup function. You can make this easier by just giving everything that’s a part of a post the sprite kind of Post or something, and then using some weird way to move them (you could try my easing extension!!! I used this one animation thing but my easing function would be much easier and coooler).

Here’s how I organised it (and still would organise it):

function newPost(userImage, userMessage, userName, time) {
    // move everything up
    for (array of all sprites of kind Post) {
        value.autoDestroy = true // suuuper important
        easeSpriteOrMoveSpriteOrWhatever(value, x, y, time) // y should be negative 
    }
   after(time) {
        // now we make a new 'post' by making a new set of Post sprites again
        let myTextSprite = textStuff(userName)
        let userImg = spriteThing(userImage, Player)
        myTextSprite.position(x,y)
        userImg.position(x,y)
    }
}

And… yeah I mean thats really it. Looking back, I would make the “recreating all the Post sprites” thing its own separate function since I ended up reusing it in two places, but yeah

3 Likes

Thanks!