Ok, its been a while since I tried to code for this. The ones on the forms seem to only work if there is only a two choices. For my story, I have it where the player can pick 4 different regions to start out. I want to keep this stat hidden and want to carry it over to the other scenes. I have it like the one below for the next scene. I having hard time of getting to work right.
Any help would be much appreciated.
*if region = 1
*goto northern
*elseif region = 2
*goto Southern
*elseif region = 3
*goto Western
*elseif region = 4
*goto Eastern
*finish
Well I tried doing it how you did it and the next scene just shows all the paths at once. For the stats screen I have this. Nothing to different.
*label screen
*stat_chart
text Name
percent health
text leadership
text strength
text agility
text intelligence
text treasury
text stealth
opposed_pair Honor
Cunning
opposed_pair favor
Imperial court: Favor
Unfavor
*line_break
*if region = 1
text northern
*finish
*elseif region = 2
text southern
*finish
*elseif region = 3
text western
*finish
*elseif region = 4
text eastern
*finish
*create region 0
*fake_choice
#1
*set region "1"
#2
*set region "2"
#3
*set region "3"
#4
*set region "4"
*if region = 1
text northern
*finish
*elseif region = 2
text southern
*finish
*elseif region = 3
text western
*finish
*elseif region = 4
text eastern
*finish
I can get it to work with it on the startup but I need it to work with the next scene. I tried doing something like this below but it still shows it. When I pick the other options, it will show like that path and the ones below it.
“You take the Eastern road
You take the Western road”
or
“*
You take the southern road
You take the Western road
You take the Eastern road”
Gower what do you mean?
*temp region_location
*if region = 1
*goto screen
*elseif region = 2
*goto screen
*elseif region = 3
*goto screen
*elseif region = 4
*goto scree
I think it is best practice, when having an “if” followed by a bunch of "elseif"s, to have the last one be “else” rather than “elseif”–not able to format the code to show you at the moment, alas.
Here was the solution!
(Just had to add *goto and a label)
*label Northern
You have gone the northern road.
*goto continue
*label Southern
You take the southern road
*goto continue
*label Western
You take the Western road
*goto continue
*label Eastern
You take the Eastern road
*goto continue
*label continue
@Snowpanther Bad kitty. Don’t encourage the brute force approach.
@Wakabam45 There’s a couple mistakes, so let’s take them one at a time. First, in your stats screen, you have text northern on it’s own line. If you want it to appear as a chart, you need:
*stat_chart
text foo <-- Where foo is the variable you want to show.
However, before that we need to make sure we have the right variable. What I’m assuming you want to show is something like this:
Region: Northern
If that’s the case, you need to *set region "Northern" (and southern, eastern, and western). Then, instead of text northern, you use:
*stat_chart
text region
No ifs or anything else. That work for you?
(Oh, and @Gower is right. If you start an *elsif chain, you need to finish it with an *else else it’s going to throw and error.)