DARA’S GUIDE: Remember Choices with if/elif/else

Thanks

I have an error. It says, Expected else or elif () after if block. What does that mean?

This is awesome, thanks, Dara. I have a question do u now who makes stories covers? I sort of need one.

Post a screenshot of your script.

Do gains carry choices over different episodes?

Yes both these methods carry over

Okay sure.

Quick question, is it normal for the web previewer to not remember gains within the same episode? It seems to be fine on the mobile previewer but on the web it almost seems like it picks a random if or else statement to go with.

You have to play through the choice first then play through the if/elif/else for it to work. If you refresh the page, that resets the gains.

The choice is finished, the if/elif/else thing comes after all that. I’ve tried several times on the web previewer and cannot get it to correctly choose the next line based on the gains. It’s fine, it seems to work on mobile and it’s not a crucial thing yet so if it shows the wrong one this time it’ll be fine. In the future though it might be an issue.

Refresh the page so the gains can reset. If keep restarting the episode and play through the choice multiple times, you’re gaining all of those gains.

1 Like

Oh!! Got ya. That makes sense! Thanks for your quick replies :smile:

1 Like

I need some help! ;-;
I can’t make the choices work. Here’s an example:

choice
“Drive and try to get to school in time” {
gain drive_and_try_to_get_to_school_in_time
(Dialogue)
} “Try to get there by yourself in time” {
gain try_to_get_there_by_yourself_in_time
(Dialogue)
}
if (try_to_get_there_by_yourself_in_time) {
(Dialogue)

It just kinda ignores it. What am i doing wrong? Tell me if ya know!

Thank you so much!

try:

if (try_to_get_there_by_yourself_in_time) {
#scene
}else{
#try_to_get_there_by_yourself_in_time
#scene
}

remember to reset your story progress before testing out gains

1 Like

I did that exact template and it’s still saying “Unexpected expression: Did you leave out the word ’choice’, or forget put a character name in ALL CAPS?”
image|281x500

Okay nevermind I realized my mistake :sweat_smile:

Thanks! :smiley: It works now.

I have a question… I am trying to carry the choices to the next episode. So do I make the choices in the first episode & the if/elif/else in the second episode?

or do I just do it all in the first episode?

you can use them in whichever episode you want :slight_smile: