The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Script Trainer Battle Scripting

Notices
For all updates, view the main page.

Binary ROM Hacking Need a helping hand or just want to talk about binary ROM hacks? Get comments and answers to any ROM Hacking-related problems, questions or thoughts you have here.

Ad Content
Reply
 
Thread Tools
  #1   Link to this post, but load the entire thread.  
Old March 14th, 2018 (10:38 PM).
Hillsy13's Avatar
Hillsy13 Hillsy13 is offline
 
Join Date: Aug 2016
Gender: Male
Posts: 157
So I am trying to script a trainer battle where the trainer stand in front of an area making you battle them to progress, then after being beaten the screen fades to black and they have disappeared, like the rocket grunt in celadon in fire red. Here is the script I've been using (on pokemon emerald btw).

#dynamic 0x2E9710

#org @event
lock
faceplayer
trainerbattle 0x2 0x1 0x0 0x82E97BF 0x82E9803 0x82E977B
release
end

'---------------
#org 0x2E977B
msgbox 0x82E9816 MSG_NORMAL '"Curses, foiled by a kid!"
fadescreen 0x1
setflag 0x1200
hidesprite 0x6
fadescreen 0x0
release
end


'---------
' Strings
'---------
#org 0x2E97BF
= Prepare to be defeated!

#org 0x2E9803
= Dang you beat me

#org 0x2E9816
= Curses, foiled by a kid!



So when I talk to the trainer in game, literally nothing happens ahah. So any help regarding what might be wrong here would be appreciate. Cheers.
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old March 15th, 2018 (6:15 AM). Edited March 15th, 2018 by Skeli.
Skeli's Avatar
Skeli Skeli is offline
Lord of the Rings
 
Join Date: Apr 2014
Location: Canada
Age: 24
Gender: Male
Nature: Adamant
Posts: 300
Try writing your script like this

#dynamic 0x2E9710
#org @event
lock
faceplayer
msgbox 0x82E97BF MSG_NORMAL
closeonkeypress
trainerbattle 0x3 0x1 0x0 0x82E9803
msgbox 0x82E9816 MSG_NORMAL '"Curses, foiled by a kid!"
fadescreen 0x1
hidesprite 0x6
fadescreen 0x0
release
end
__________________
Pokemon Unbound

Reply With Quote
Reply

Quick Reply

Join the conversation!

Create an account to post a reply in this thread, participate in other discussions, and more!

Create a PokéCommunity Account
Ad Content

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 9:17 AM.