How to list scenes

Back at it again with another post because I haven’t quite found a concrete answer. For the *scene_list, how do you list all of them if you have branching scenes? For example:


Chapter one contains this:

    *goto_scene tadam
    *goto_scene stuffhappens
   *goto morewords

However, in tadam, it will return to the scene file Chapter1 to continue. In stuffhappens, it will go to Chapter 2. And say in morewords, it goes to back to Chapter1 as well. So how is this listed in *scene_list? Does this make sense? I think I have it figured out, but I’d rather make sure.

You don’t need to list all your scenes in the scene list if you’re doing them the way you’re doing them. You just need to tell the system what goes next after you *finish the end of Chapter 1, Chapter 2, etc., and in what order. When you start to branch out to your other scenes, they don’t need to be listed in the scene list to be called, but you do want to use the *go_sub commands if you haven’t already learned those!

1 Like

Oooh okay, I think I get it. Well, not the gosub- I’ve looked it up but it doesn’t quite make sense?? Is it okay if I ask if you could, say, simplify it for my idiot self?;;

*go_sub is like leaving a bookmark for your game to go to one scene and remember its place when it goes back. For example, your game would go like this:

Chapter 1

       *gosub_scene tadam

(In other words, not *goto_scene, but *gosub_scene)

Now, you said that in tadam, the game will eventually return to the scene file Chapter1.

But if you use a *goto_scene Chapter1 in tadam, the system will just start at the beginning of Chapter1 all over again.

Instead, in tadam, you use *return when you want to go back, which tells the game to return to the last *gosub it executed: aka just after the choice that sent us to tadam in the first place (seen above).

This way the game can pick up in Chapter1 where it “left off” before the branch, rather than going back to the beginning of Chapter1 and starting the chapter all over again.

Does that make sense?

EDIT: the other main reason why you would use *gosub_scene and not *goto_scene is because when you use *goto_scenes, things like *temp (temporary variables) or *hide_reuses are “reset”, as if you’re playing that scene file for the very first time. Using *gosub_scene means jumping to another scene file and then jumping back in such a way that the system remembers those variables, because you didn’t technically “leave” the scene.

It makes a little more sense now. the whole concept of *gosub is weird to me, period :laughing:

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.