How do you get choices to work?


I’m new to coding and using Choicescript. I’ve been stuck trying to get choices to go where I need them to go for a while now. I can only get the first one out of three to work. The other two aren’t showing up when I test it. How do you get two of the choices to lead to death, while the other to the next chapter? There aren’t any impacts to stats or variables with this one. (I see lots of Tylenol in my future trying to implement variables, commands, stats, etc. into the story.)
Here’s an example of how it looks:

*goto_scene death
*goto_death scene
*goto_ scene chapter2

I have chapter2 in the scenes folder and on the startup list.


You should check out the intro to choicescript stuff here

Since you haven’t posted it in code, I don’t know what your indentations look like. You could have problems there. You also have a command that doesn’t exist (*goto_death scene --> it should be *goto_scene death). The biggest thing though, is that a choice should look like this:

    *goto next
    *goto_scene death

You don’t use the *choice command everytime you have a new option, that’s what the #'s are for

You should also check out the wiki

Edit: since you have edited your original post, I have more to say

The commands associated with your options must be in the body of the option, which you can see in my example above. You also don’t need a *goto_scene chapter2 if in your startup chapter two comes directly after this, you need to use the *finish command


Check out the links listed above. Also look at the example code for dragon to see how it can be used.

I’m going to disagree slightly with sviyagin, in that i think the use of goto_scene instead of finish is perfectly acceptable to use, and sometimes trying to use both seems to cause unnecessary confusion to people new to choicescript. I almost never use finish, because I find it easier to be 100% sure of where I’m pointing the goto that way (instead of having to be sure I haven’t changed the order of scenes in the startup,) but either will do the trick, it’s personal preference :slight_smile:


you need to use the finish command

Well, you don’t need to. I don’t think I’ve ever used the *finish command actually. I’ve even got a part where depending on what you’ve done in the game you can start in one scene and swap to another, or if you get to the other scene first, you could swap to the first!

Anyway the OP really needs to take a gander through the tutorial. I recommend this one:

What I did myself was actually make a little document with all of the commands and interactions explicitly written out for my own benefit. Looks like this:

like this

Like this:

Like 19 pages of that actually. The process of creating it really helped a lot with internalising all of the basic elements of the markup language so I could focus on solving the more complicated problems. I never need to refer to it now.


Definitely check out the links everyone mentioned, especially the wiki! It’s something I’ve looked at often, and I find it very helpful.

Now that I’ve put the checkpoint system into my WIP, I’m not sure how or where I could even use *finish, since everything has to jump over to the checkpoint scene first. :thinking:


I made a mistake on the example. I meant to put *goto_scene death. But I found my mistake. I must have overread where it said you have to indent the *goto. Thanks for everyone’s help.