Help with branching

I’m pretty much at my wits end with my story as my readers keep getting the wrong LI and I cannot for the life of me figure out why! Can someone possibly take a look at my coding and help me with this?

at your service :raised_hand:

The issue I’m having has been ongoing throughout my story, and last time I had this issue, another author told me to change my label names to something more complicated, so that’s why I have the odd names. And although that worked for a little while, this newest chapter is having issues again. The people that chose Welly as their LI, are getting Floyd. There is a female and a male version of Welly, but the readers are only getting Floyd.

Below is each branch within the newest chapter and the labels that go with them.

Branch #1

if (girl_welly_888){
goto alternative_response
} if (boy_welly_999){
goto alternative_response
}if (boy_floyd_777){
goto flora_floyd_reply
}

Branch 1, Label 1:

label flora_floyd_reply

Branch 1, Label 2:

label alternative_response

Branch #2

if (girl_welly_888){
goto next_scene
} if (boy_welly_999){
goto next_scene
}if (boy_floyd_777){
goto get_down
}

Branch 2, Label 1:

label get_down

Branch 2, Label 2:

label next_scene

Branch #3

if (girl_welly_888){
goto funeral_scene
} if (boy_welly_999){
goto funeral_scene
}if (boy_floyd_777){
goto celebrate_reply
}

Branch 3, Label 1:

celebrate_reply

Branch 3, Label 2:

label funeral_scene

Branch #4

if (girl_welly_888){
goto cliffside_welly_female
} if (boy_welly_999){
goto cliffside_welly_male
}else{
goto parknight
}

Branch 4, Label 1:

label cliffside_welly_male

Branch 4, Label 2:

label cliffside_welly_female

Branch 4, Label 3:

label parknight

i think you should use point system instead. this is because points can be set to 0, but for flags- if a flag is gained, it can’t be removed. thus if the code acts up and gives two flags to the reader, they will get the wrong li.

also, be sure to end the branch with a “goto a_scene_same_for_both_the_LIs” or else it will send the reader to the very next label.

here’s what i meant: (idk if i explained that well lol but basically create an end/next scene label)

        NARRATOR
    Choose an LI.

choice
"Fem Welly" {
@CHOOSEMWELLY =0
@CHOOSEFWELLY =1
@CHOOSEFLOYD =0
} "Male Welly" {
@CHOOSEFWELLY =0
@CHOOSEMWELLY =1
@CHOOSEFLOYD =0
} "Floyd" {
@CHOOSEMWELLY =0
@CHOOSEFWELLY =0
@CHOOSEFLOYD =1
}

################ BRANCH 1 #################

if (CHOOSEFWELLY=1){
goto alternative_response
} elif (CHOOSEMWELLY=1){
goto alternative_response
} else {
goto flora_floyd_reply
}

#Branch 1, Label 1:

label flora_floyd_reply

        NARRATOR
    This is floyd speaking.

goto end

#Branch 1, Label 2:

label alternative_response

        NARRATOR
    This is Welly speaking.

goto end

#Mutual story branching

label end

        NARRATOR
    Help.

I’m not sure I fully understand what you did. :laughing: Can you explain it to a simpleton like myself?

ah, no worries :> aren’t we all simpletons

basically, this code uses point system to remember gender preferences.

here, if the reader chooses female version of welly, they get 1 choosefwelly point. this point is later used to ‘send’ the reader to the labelled scenes for female welly. this is same for choosemwelly (which helps in remembering that the reader chose male welly), and choosefloyd (for floyd). these can be renamed to anything you like.

choice
"Fem Welly" {
@CHOOSEMWELLY =0
@CHOOSEFWELLY =1
@CHOOSEFLOYD =0
} "Male Welly" {
@CHOOSEFWELLY =0
@CHOOSEMWELLY =1
@CHOOSEFLOYD =0
} "Floyd" {
@CHOOSEMWELLY =0
@CHOOSEFWELLY =0
@CHOOSEFLOYD =1
}

now here, we’re using the previous points (or rather, remembering them) to send the reader to the appropriate scenes- like those with 1 choosefwelly point (which denotes they chose the female welly Li) get to read the alternative_response label. those with 1 choosefloyd point (i wrote else here since it was the last possible option) read the flora_floyd_reply label.

if (CHOOSEFWELLY=1){
goto alternative_response
} elif (CHOOSEMWELLY=1){
goto alternative_response
} else {
goto flora_floyd_reply
}

noww, there are 2 ready-made labels here (the ones you made). i made an extra label named end, aka the ‘mutual’ label (because it sends the reader to a scene which will remain same, regardless of the reader’s li gender choice. if we don’t specify to send the reader to this label at the end of the branch, readers with 1 choosefloyd point (or readers who chose floyd as their Li) will get welly’s scene after floyd’s scene.

#Branch 1, Label 1:

label flora_floyd_reply

        NARRATOR
    This is floyd speaking.

goto end

#Branch 1, Label 2:

label alternative_response

        NARRATOR
    This is Welly speaking.

goto end

#Mutual story branching

label end

        NARRATOR
    Help.

im sorry if it’s still confusin, im not the best at explaining. altho if you want, i could edit your script for u ^^

Okay, thank you so much for your explanation! It did help a lot!

So, I understand how points work but in this chapter, they don’t choose their love interest because they already chose in a previous chapter using gains. So, how do I implement these points now?

you can add this Li choice in the beginning of the current chapter :>

I’ve changed it all and added the choice at the beginning and it seems to be working great! I was reluctant to do so because this has been an ongoing issue in which readers have had to choose their LI multiple times. But, they’ll just have to accept it if they want the issue fixed!

Thank you so much for your help, you’re an absolute gem and a total lifesaver! :heart:

1 Like

glad i could be of help! <3