My problem is that no matter what, character pc is always whatever is the last elif (ie. in this case, Jake). I've switched the order of the if/elif positions to make sure this the case. I've tried making individual ifs instead of an if/elif branch, and that hasn't worked. Can someone help me figure out how to fix this and why this method works incorrectly as it does?
in screens.rpy
Code: Select all
screen perkselection():
zorder 100
imagebutton:
hover bondico
idle bondico
action SetVariable("perkchoice","Bond")
xpos 0.5
ypos 0.1
focus_mask True
imagebutton:
hover empathyico
idle empathyico
action SetVariable("perkchoice","Empathy")
xpos 0.5
ypos 0.4
focus_mask True
imagebutton:
hover calmico
idle calmico
action SetVariable("perkchoice","Calm Spirit")
xpos 0.4
ypos 0.25
focus_mask True
imagebutton:
hover adrenico
idle adrenico
action SetVariable("perkchoice","Adrenaline")
xpos 0.6
ypos 0.25
focus_mask True
Code: Select all
label lab_perksel:
show screen perkselection
label setchar:
pause
nar "Equip [perkchoice]?"
menu:
"Yes":
if perkchoice == "Bond":
define pc = Character("Dwight")
define pca = Character("Claudette")
define pcb = Character("Jake")
define pcc = Character("Meg")
elif perkchoice == "Empathy":
define pc = Character("Claudette")
define pca = Character("Dwight")
define pcb = Character("Jake")
define pcc = Character("Meg")
elif perkchoice == "Adrenaline":
define pc = Character("Meg")
define pca = Character("Dwight")
define pcb = Character("Jake")
define pcc = Character("Claudette")
elif perkchoice == "Calm Spirit":
define pc = Character("Jake")
define pca = Character("Dwight")
define pcb = Character("Claudette")
define pcc = Character("Meg")
else:
jump lab_perksel
jump scene001
"No":
jump lab_perksel