My choices and set not working

i want to put the character’s name on the stats screen when choosing a choice,but it’s not working my Code is this

(choicescript_stats.txt)

Name: $!{name}

(startup.txt)

*choice
#Jonh
*goto male
*set name “Jonh”
#Peter
*goto male
*set name “Peter”

(The “Peter” choice isn’t showing up in the chapter either)

It could be because you’re skipping to the goto male before reaching the set point. Set the name then end with the scene change.

1 Like

It should be ${name}. You can use fake_choice to set a name too, if it isn’t a long branch.

2 Likes

I think you forgot the indentation.

It should be like this

*choice
  #John
    *set name "John"
    *goto male
  #Peter
    *set name "Peter"
    *goto male
  

Also the command *goto label should be placed after the the *set command.

2 Likes

“It worked here, thank you. I added the ‘goto’ after like you and Shancall mentioned earlier, but it was giving another error. So I tried adding more indentation, and it worked.”

This topic was automatically closed 24 hours after the last reply. If you want to reopen your WiP, contact the moderators.