HOW TO: Remember Past Choices (if/elif/else)


#1

FIRST AND FOREMOST, to remember choices, you will need to use the if/lif/else code, which looks like this:

if (label1) {
} elif (label2) {
} else {
}

if is always first, elif is always in the middle, and else should always be the last one by itself

if you have 2 options, you only need to use if and else
if (label) {
} else {
}

if you have 3 options, use if then elif then else
if (label1) {
} elif (label2) {
} else {
}

if you have more than 3 options, keep using elif for the middle parts, but always make sure that if is first and else is last
if (label1) {
} elif (label2) {
} elif (label3) {
} elif (label4) {
} else {
}

There are 2 methods to remembering past choices:

1- The choice name and option method
2- Using GAINS

1. Choice Name & Option Method

Name your choice by adding the name next to the word choice and put it inside parentheses.

Here is an example:

NARRATOR
What do you want to eat?

choice (FOOD)
“Spaghetti” {

} “Donuts” {

} “Sandwich” {
}

TO REMEMBER THE ABOVE CHOICE, USE THE IF/ELIF/ELSE CODE WITH THIS FORMAT: (choice_name is "Option Name")

if (FOOD is “Spaghetti”) {
[scene for spaghetti choice here]

} elif (FOOD is “Donuts”) {
[scene for donuts choice here]

} else {
[scene for sandwhich choice here]
}

NOTES:
This is the best method to use for dressing games!

This method will not work with a customization template or repeated choices:

Customization templates have repeated choices. Inside each choice is a goto that leads back to the label to start the choice over again, so technically whatever choice you tapped on does not get remembered since the choice gets repeated.

Your choice name and option titles need to match exactly

If your choice name is “YUM_food” and your option name is “I LoVe DonuTS!!”, then the format for the if/elif/else needs to be (YUM_food is “I LoVe DonuTS!!”)

Wrap straight brackets around the choice name to reference that option in dialogue

You can use the choice name to reference what the reader chose in dialogue; just wrap straight brackets around the choice name.

CHARACTER
Today I had [FOOD] for lunch.

If the reader chose “Spaghetti”, then they will see:

CHARACTER
Today I had Spaghetti for lunch.

(but be warned that whatever option title is will be what the reader will see)
If the option title was “I want to eat Spaghetti!!”, then readers will see this:

CHARACTER
Today I had I want to eat Spaghetti!! for lunch.

2. USING FLAGS/GAINS

You can have your readers gain certain flags by just using the code: gain flag_name

Here is an example:

NARRATOR
What do you want to drink?

choice
“Orange Juice” {
gain orange_juice

} “Coffee” {
gain coffee

} “Water” {
gain water
}

TO REMEMBER THE ABOVE CHOICE, USE THE IF/ELIF/ELSE CODE WITH JUST THE GAIN NAME INSIDE PARENTHESES ()

if (orange_juice) {
[scene for orange juice here]

} elif (coffee) {
[scene for coffee here]

} else {
[scene for water here]
}

NOTES:

  1. Once a flag is gained, you cannot “un-gain” it. So be sure to not use this method with dressing games. If you do, you will need to put a “yes/no” choice inside each outfit option with the gain inside the “yes” choice. See an example of that HERE
  2. Gain names cannot have spaces or special characters. They can only have letters, numbers, and/or underscores.

How do i remember outfit choices
If/elif problem
How to save dress choices
Future Episodes for my story: Ink - Remembering Female and Male Customization (CLOSED)
Manna's Help Thread: For coding, directing and more
How do I make clothing choices remember in the next scene or chapter?
Help gain script trouble (better for me to show you)
Choices from one chapter affecting the other?
Having Trouble Remembering Choices
Dara's Official Help Thread (GET HELP HERE!)
Help with If, Elif, Else!
Trouble with remembering past choices
Dara's Official Help Thread (GET HELP HERE!)
I need help saving choices
If, elif, else problem
How do I put a remembered choice?
A Guide to Typed-in Choices
If/elif/else /gains HELP
There is a { on line 750 that does not have a matching
How can you remember a past choice
Directing Help please!:)
How to Remember Choices?
If/Elif/Else Between Episodes
Help me with this error on remembering choices
Reader Choices and other issues :/
It's Not Working
HELP ME "There is a { on line 1398 that does not have a matching }" HELP ME
Using advanced choices. (The simple ones,)
Remembering Choices Error
Dara's Official Help Thread (GET HELP HERE!)
Rude’s Here to Help! Ask your questions babes 💙
Dara's Official Help Thread (GET HELP HERE!)
I need help - In need of some assistance
I'm having trouble with changing outfits (HELP)
Winter - Here to Help: Advice & Questions!
Dara's Official Help Thread (GET HELP HERE!)
Remembering past choices
Need help with advanced choices!
Dara's Official Help Thread (GET HELP HERE!)
A Complete List of Props and How to Use Them (Hidden Props Also!)
A coding question regarding conditions
"Stupid" questions that never get answered? Get The Help Here!
Using more than one gain in choices
Directing Help and Assistance From a Purple Ghost For All Your Episode Needs
Character mentions another characters choice, please help!
Dara's Official Help Thread (GET HELP HERE!)
Dara's Official Help Thread (GET HELP HERE!)
Dara's Official Help Thread (GET HELP HERE!)
I need help with outfit choices
Manna's Help Thread: For coding, directing and more
Dara's Official Help Thread (GET HELP HERE!)
Making Choices - advanced
Complex choices
Help? (Again) Errors? :fearful:
Dara's Official Help Thread (GET HELP HERE!)
Dara's Official Help Thread (GET HELP HERE!)
Dara's Official Help Thread (GET HELP HERE!)
:grin: Resources for Creators
Directing Help and Assistance From a Purple Ghost For All Your Episode Needs
"Stupid" questions that never get answered? Get The Help Here!
Automatically to the first option of the choice
"Stupid" questions that never get answered? Get The Help Here!
Keeping same outfit to next episode, help?
I need help with the "dressing up" aspect of choices on Episode
Do you need help? Well help is here!
Rude’s Here to Help! Ask your questions babes 💙
"Stupid" questions that never get answered? Get The Help Here!
"Stupid" questions that never get answered? Get The Help Here!
Dara's Official Help Thread (GET HELP HERE!)
"Stupid" questions that never get answered? Get The Help Here!
Dara's Official Help Thread (GET HELP HERE!)
I need help with the points system/ remembering past choices / gains
Big choices in story
Branching on episode
I really need someone to help me with a few questions i have about creating a story
Dara's Official Help Thread (GET HELP HERE!)
Choice Not Being Remembered
"Stupid" questions that never get answered? Get The Help Here!
Rude’s Here to Help! Ask your questions babes 💙
Dara's Official Help Thread (GET HELP HERE!)
How do I do "Or" in Episode?
Dara's Official Help Thread (GET HELP HERE!)
Dara's Official Help Thread (GET HELP HERE!)
The Points System
Multiple Love Interests
I need help remembering!
SCRIPT ERRORS you just can't seem to fix: GET THEM FIXED HERE!
Can anyone explain me about the gains and the ifs?
REMEMBERING! choices HELPPPPP
Choices Carrying Over Between Episodes
Gem Choice for Dressing Up - Directing HELP!
Unexpected String :(
Help with Remembering Choices
Help With Remembering Choices!
Directing Problem: Smooth Directing
"Stupid" questions that never get answered? Get The Help Here!
Needing help please
Adding gem choices
How to continue a label from a previous choice
Dara's Official Help Thread (GET HELP HERE!)
Dara's Official Help Thread (GET HELP HERE!)
Dara's Official Help Thread (GET HELP HERE!)
#2

but I’ve never used “else” cuz it didn’t work at all :confused:


#3

If you’re using gains, you have to remember to reset story progress. Otherwise it should always work.


#4

Can you do that on mobile?


#5

Mobile creation? No you can’t. This is only for directing using the script in the writer’s portal online.


Dara's Official Help Thread (GET HELP HERE!)
#6

alright thank you!


OUTFIT CHOICE,help
#7

do u have to use [ outfit changing scene] ?


#8

No you replace that with your outfit changing script scene.


#9

oh what? sorry im vv confused now


#10

[outfit changing scene] gets replaced with the script/commands to have your character change into the outfits

so this:

choice
"Short Dress" {
[outfit changing scene]

changes into this: (or whatever you want)

choice
"Short Dress" {
@CHARACTER changes into Outfit
@CHARACTER is blush

How to do choices with clothes
#11

ohhh thanks :pray:t4: :sparkling_heart:


#12

How do you reset gains


#13

You can’t, unfortunately.


Script Troubles
#14

hi , I’m a little confused and i need your help.
it keeps saying that error and i don’t know what to do.


#15

What’s after the “hell no” choice in your script?


#16

nothing , but another label.


#17

Then there should be 1 more ending bracket at the end:

}
“Hell no!” {

goto choosing_outfits

}
}


#18

Thank you so much!!! it finally worked :heart:


#19

i’m sorry to bother you again but i have come across another problem.


#20

“else” needs to be by itself

} else {