View Single Post
  #8674    
Old August 13th, 2013 (05:37 AM).
Wobbu's Avatar
Wobbu Wobbu is offline
Oro
Moderator
 
Join Date: Mar 2012
Location: With the Mooshroom
Gender: Male
Nature: Relaxed
Posts: 2,343
Quote originally posted by Mauri:
So, like this?

Code:
trainerbattle <etc>..
checktrainerflag 0x<ID>
if 0x1 goto @win
// if you loose
Right? Or have i to compare the last result?
Yeah, if the trainer has been defeated, then the flag will be set. You don't need to check a variable, just do if 0x1 goto.
If you want to do a script with the actual trainerbattle in it, then this is what you want:
Code:
trainerbattle 0x3 0xYYY 0x0 @intro @defeat
Iirc, trainerbattle 0x3 allows execution after the battle, even if you lose.
__________________