The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Script What command was it to play music in battles?

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 January 23rd, 2019 (2:18 AM). Edited January 24th, 2019 by Ace Trainer Slash.
Ace Trainer Slash's Avatar
Ace Trainer Slash Ace Trainer Slash is offline
If you give me about two hours, I can make scripts without a guide!
 
Join Date: Jun 2018
Location: Australia.
Age: 20
Gender: Male
Nature: Jolly
Posts: 235
Hi. :)

So, since I'm making a hack (for Fire Red), where most important trainers in the game intend to use the Champion's battle theme, I'm not sure what command, nor where to put it within a script. I can create a simple trainer battle script, but I'm unsure what command it is to play that specific theme during a trainer battle, nor where I should put that command in the script to actually function.

Any help is greatly appreciated. :)
__________________
I run Dedenne, and I don't regret it one bit!
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old January 23rd, 2019 (11:25 PM).
Ace Trainer Slash's Avatar
Ace Trainer Slash Ace Trainer Slash is offline
If you give me about two hours, I can make scripts without a guide!
 
Join Date: Jun 2018
Location: Australia.
Age: 20
Gender: Male
Nature: Jolly
Posts: 235
Quote:
Originally Posted by Petuuuhhh View Post
So this should play a song before you start the trainerbattle. Make sure to read XSE's scripting commands to see how playsong works.
Code:
special 0x03B
playsong
trainerbattle
Ok, so I executed the script, specifically like this:
special 0x03B
playsong 0x12B 0x0
trainerbattle etc...

And the result was my trainer crashing the game, and turning the screen red, what was it that I did incorrectly?
__________________
I run Dedenne, and I don't regret it one bit!
Reply With Quote
  #3   Link to this post, but load the entire thread.  
Old January 24th, 2019 (12:46 AM).
DrFuji's Avatar
DrFuji DrFuji is offline
Heiki Hecchara‌‌
 
Join Date: Sep 2009
Location: Aussie
Age: 30
Gender: Male
Nature: Jolly
Posts: 1,693
If you've attached the script to a trainer with a view radius, the game will crash; the only battles you can give battles custom music via scripting are ones that are activated by talking to an NPC or by stepping on a green script tile. This is because a trainer with a view radius must have trainerbattle as the first command in the script.

If in your case the script isn't attached to a trainer with a view radius then ¯\_(ツ)_/¯
__________________
Reply With Quote
  #4   Link to this post, but load the entire thread.  
Old January 24th, 2019 (2:13 AM).
Ace Trainer Slash's Avatar
Ace Trainer Slash Ace Trainer Slash is offline
If you give me about two hours, I can make scripts without a guide!
 
Join Date: Jun 2018
Location: Australia.
Age: 20
Gender: Male
Nature: Jolly
Posts: 235
Quote:
Originally Posted by DrFuji View Post
If you've attached the script to a trainer with a view radius, the game will crash; the only battles you can give battles custom music via scripting are ones that are activated by talking to an NPC or by stepping on a green script tile. This is because a trainer with a view radius must have trainerbattle as the first command in the script.

If in your case the script isn't attached to a trainer with a view radius then ¯\_(ツ)_/¯
Ah, ok, well that's ok I guess, I wanted to give Youngster Joey his own Champion battle theme to be somewhat funny, but normal trainer battle fits too. I've got some stationary trainers in my hack that will utilise this information perfectly. :) Thanks for the help!, and to Petuuuhhh too! :)
__________________
I run Dedenne, and I don't regret it one bit!
Reply With Quote
  #5   Link to this post, but load the entire thread.  
Old January 24th, 2019 (4:59 AM).
BirdstarCat13 BirdstarCat13 is offline
 
Join Date: Nov 2017
Gender: Male
Posts: 476
Firstly - Welcome back!

Secondly - I think this might be what you're looking for
__________________
-------------------------
I hate signatures that are just a line of text without any clear division. You weirdos know who you are ;)
Reply With Quote
  #6   Link to this post, but load the entire thread.  
Old January 24th, 2019 (8:58 PM).
Ace Trainer Slash's Avatar
Ace Trainer Slash Ace Trainer Slash is offline
If you give me about two hours, I can make scripts without a guide!
 
Join Date: Jun 2018
Location: Australia.
Age: 20
Gender: Male
Nature: Jolly
Posts: 235
Quote:
Originally Posted by BirdstarCat13 View Post
Firstly - Welcome back!

Secondly - I think this might be what you're looking for
Firstly, Thankyou for welcoming me back, secondly, this should be useful too! Thanks! :D
__________________
I run Dedenne, and I don't regret it one bit!
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
Thread Tools

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:13 AM.