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

How would I remember choices from past chapters? Would I still use the same gains from that chapter?

The whole guide above is for remembering choices for later in the same episode or in future episodes. Both methods work through out all chapters.

Alright thanks.

Hey,
yes the choice is in Episode 1 and this is in Episode 2. I am using my phone, I tried everything - reseting the story etc, she does change the outfit, but it’s not the one I picked her :smiley:

This is the first code:

1 Like

Change the quotation marks in your if/elif/else. Right now they’re not the correct script font. The option names should be red in the script just like in the choice. Also the “dress” needs to be all lower case for “Blue dress” in the elif because that’s what you have in your choice.

1 Like

You are a lifesaver! Thank you so much! :slight_smile:

Hey hey :slight_smile:
How can I remember multiple choices for example hair, outfit and make up?
Thank you! Xxxx

For hair and makeup, it’s best to use a duplicate character if you are trying to switch back to the original hair and mouth color. The only other way to actually remember template choices it by using the points system.

For outfits, it’s in the guide above.

2 Likes

Hi, I need a little help for my story. In my story I put

choice
“Option 1”{

gain PANDEROSA_beachparty1
}
“Option 2”{

gain PANDEROSA_beachparty2
}
“Option 3”{

gain PANDEROSA_beachparty3
}

and later on put

if (PANDEROSA_beachparty 1 is Option 1) {
@cut to zone 1
@PANDEROSA changes into PANDEROSA_beachparty1

} elif(PANDEROSA_beachparty2 is Option 2) {
@cut to zone 1
@PANDEROSA changes into PANDEROSA_beachparty2

} else {
@cut to zone 1
@PANDEROSA changes into PANDEROSA_beachparty3

}

but instead of the character dressing in the selected choice, she changes into the last option.
Thank you!

You’re combining the two methods together. If you’re using gains, then only the gain name needs to be inside the parentheses

if (PANDEROSA_beachparty1 is Option 1) {

} elif (PANDEROSA_beachparty2 is Option 2) {

} else {

}

2 Likes

So, from experience, I figured out that if you’re just doing two choices, you use if and elif. Because when I used if and else, it wouldn’t work. It would say it was wrong. But when I replaced the else with elif, it let me save. Idk why it did that for me, it could be different for others, so just sharing what happened. :slight_smile:

1 Like

If the “else” isn’t working then it means your code must not be correct.

Oh. But when I replaced the else with elif, it worked. And it said there was no errors.

You may not get any errors in your script, but that doesn’t mean it’s correct. You can have “if (bananas)” but your gain name was actually banana without an “s” and there would be no errors in your script. But if you test your story it would not work.

The only reason why “else” would give you errors is if your adding something next to it. Like the guide says above, “else” needs to be by itself without anything in parentheses next to it.

ohhhh! That makes A LOT of sense! :grin: Because I do have the parentheses next to it. Lol that you for correcting me.

2 Likes

Ahh, it works now!! Thank you so much.

2 Likes

Can it remember more things like all of the lip colors? or all hairstyles? :grin: thank you

For choice name and option:

For gains:

1 Like

Hiii, this thread was so helpful but I have just one question.

In my preview mode and script will the gains reset or no? When I’m busy previewing my story and pick a choice which has a gain to see whether the script in that scene or area is correct or not, can that only be my final choice? I’m not able to preview my other outcomes from the gains that I’ve written. I’ve heard that gains don’t reset but is that also the case when you’re busy writing the script and want to preview it?

Thank you in advance x

Gains reset when you reset story progress in the app or refresh the page for the web previewer. If you just restart the episode, you will gain all gains if you play through all choices which will result in the if/elif/else not working correctly.

1 Like