Else script error

Code

INT. BLACK - NIGHT
@pause for 2

label choose_gender

    NARR
Hello.

    NARR
Are you a male or female?

choice “Male” {

gain chose_male
goto final_choice

} “Female” {

gain chose_female
goto final_choice

}

label final_choice

    NARR
Are you sure?

choice"Yes" {

goto continue_story

}“No” {

goto choose_gender
}

label continue_story

    NARR
Great! Now lets customize |bold|YOU.

if (chose_male) {

@YOUM enters from left to screen center
@YOUM starts shiftweight

label choose_name_male

input What is your name? | What is your name? | Done (YOUM)

    NARR
Hey (YOUM).

} else (chose_female) {

@YOUF enters from left to screen center

@YOUM enters from left to screen center
@YOUF starts shiftweight

label choose_name_female

input What is your name? | What is your name? | Done (YOUF)

    NARR
Hey (YOUF).

}

label customise_male
@pause for a beat

label customise_female
@pause for a beat

the coding error is with the else part, it says did you forget to put the word choice or put the characters name in all caps

“else” needs to be by itself.

Also, if you’re using gains, you can’t have a yes/no confirmation choice after the gender choice. There needs to be a yes/no choice inside the male option and inside the female option with the gains inside the “yes” options. The way your choice is formatted right now, readers will gain both gains if they decide to go back and choose a different gender.

Check this out to see how it should be formatted.

1 Like

Ah ok. I’ve sorta fixed that part up, but now its come up with a new error.

What have I done now? :joy:

Labels can’t have spaces. Change the space into an underscore.

like this?

label_customise_female ?? sorry coding is confusing

1 Like

No it’s like:
goto story_start

ah ok, I understand now. thanks @SkyM @Dara.Amarie

1 Like

Ofc!

1 Like