I’ve searched everywhere but I can’t seem to find a solution to my exact problem.
I’m currently creating a game where you branch off in to different stories (scenes) depending on your stats. For example if your relationship stats with person A is higher than with B and C, you will end up with person A. If your relationship is higher with B than with A and C, you will end end up with B and so on.
My first try of coding this was supposed to be who you’d dream of (depending on the stats) and looked like this:
*label A
*if (A > 0)
*if (A > B)
*if (A > C)
*goto dreamA
*else
*goto B
*label B
*if (B > A)
*if (B > C)
*if (B > 0)
*goto dreamB
*else
*goto C
etc...
I don’t think it’s correct considering I always get an error: It is illegal to fall in to an *else statement; you must *goto or *finish before the end of the indented block.
Could somebody explain how to do this? Sorry in advance if this has been asked before.
Make sure to have a *else for every *if you have. When the code gets to *if (A>B) and this is incorrect (A isn’t bigger than B), there will be an error.
I never thought of this, will definitely try it. In this case it’s not just A, B and C, I have about 4-5 labels so I would need to use a lot parentheses for this thank you nevertheless.