Run into an "Expected Choice Body" Error

Hi!

I just started learning Choicescript last night, but am running into problems. I have uploaded the images of my issues.

I’m not sure what I am doing wrong?

Capture|690x391

It’s very hard to tell what’s wrong without looking at the code you used. :slight_smile:

Hi and welcome to the forum and Choicescript :slight_smile:

I would assume you used the *choice command on there without indents (you’ll learn to hate them)

here’s a vid tutorial on the basics:

There’s also tools like chronicler or CSIDE to make coding easier, as well as the unofficial discord server.

1 Like

Since you haven’t pasted any of your code, try this.

Hi sorry, i’m thing to learn my way around here. Here is the code:

*title Zombie Outbreak
*author RDSIII
*scene_list
startup
beginning
middle
end
*create leadership 0
*create strength 0

You wake up to loud banging outside of your house. You figured it was a neighborhood dog. You groggily get out of bed to check. Moving your curtain slightly and looking through your blinds, you notice a man outside of your window getting torn apart by other men and one woman. They look pale and there is blood all over them. They seem to be eating the man. What will you do?

*choice
#Go back to sleep. It’s his problem.
#Call 911. This man needs help and these people need to be arrested!
#Go out and help the man. A friend in need is a friend indeed!
*finish

Choices look like this:

*choice
  #Option
    Body
  #Option
    Body
  #Option
    Body

You’re missing the choice body for all those options.

1 Like

you can format your code by adding three ` above and below

Ok, so like @RETowers explained, you’re missing the choice body.
In a regular *choice you will have to tell the system to do something (typically with a *goto command) after the “text body” of the choice. In a *fake_choice you don’t have to do that.

Also, you won’t want to use *finish unless you’re done with the current scene and want to move on to the next.

Examples:

*choice
 #Go back to sleep. It’s his problem.
  You go back to sleep.
  *goto option1
 #Call 911. This man needs help and these people need to be arrested!
  You pick up your phone and start dialing.
  *goto option2
 #Go out and help the man. A friend in need is a friend indeed!
  You decide to go and offer help.
  *goto option3

*label option1
This is what happens if we pick the first option.

*label option2
This is what happens if we pick the second option.

*label option3
This is what happens if we pick the third option.

I should note that if you have the above labels as they are you will run into all three options because ChoiceScript processes things in order. You’ll want to tell it to go somewhere else after the text.

Here’s a *fake_choice example:

*fake_choice
 #Go back to sleep. It’s his problem.
  You go back to sleep.
 #Call 911. This man needs help and these people need to be arrested!
  You pick up your phone and start dialing.
 #Go out and help the man. A friend in need is a friend indeed!
  You decide to go and offer help.

But before you do anything, you get a sudden pain in your chest.

In the above example, the game will go directly to “But before you do anything, you get a sudden pain in your chest.” right after you pick an option.

1 Like

Thanks bro i’ll read this closely!

1 Like