At the moment, I'm trying to make a script where you have to battle two other opponents before the third opponent becomes available for battle. I'm using flags for this.
What happens now, is that I have to talk to the person I defeated first before the flag gets activated. What am I doing wrong?
This is the script
#dyn 0x740000
#org @start
'-----------------------------------
checkflag 0x238
if true jump @flagalreadyset
trainerbattle 0x0 0x9 0x0 @begin @defeat
setflag 0x238 ---> this flag only gets activated when I talk to the trainer after battle, it doesn't get activated automatically after battle.
end
#org @flagalreadyset
msgbox @sensei ' You've been lucky. I...
callstd MSG_LOCK ' Built-in lock command
end
#org @begin
= You? Beat me? Hah! I can smash\nrocks with my bare fists!
#org @defeat
= But that doesn't make me a great\ntrainer...
#org @sensei
= You've been lucky. I wonder if\nyou could beat sensei too.
What happens now, is that I have to talk to the person I defeated first before the flag gets activated. What am I doing wrong?
This is the script
#dyn 0x740000
#org @start
'-----------------------------------
checkflag 0x238
if true jump @flagalreadyset
trainerbattle 0x0 0x9 0x0 @begin @defeat
setflag 0x238 ---> this flag only gets activated when I talk to the trainer after battle, it doesn't get activated automatically after battle.
end
#org @flagalreadyset
msgbox @sensei ' You've been lucky. I...
callstd MSG_LOCK ' Built-in lock command
end
#org @begin
= You? Beat me? Hah! I can smash\nrocks with my bare fists!
#org @defeat
= But that doesn't make me a great\ntrainer...
#org @sensei
= You've been lucky. I wonder if\nyou could beat sensei too.