I've made a custom Champion battle for my Pokémon FireRed romhack, included with different music for the final battle. Namely, Deoxys' battle theme.
However, for some reason the Trainerbattle script is triggered twice. Once with the Deoxys battle theme, and once with the regular battle theme. It's the same battle twice as well, so I don't think there's an issue with the rematch script.
The code I'm using is as follows:
Does anybody know what might be causing this problem?
---UPDATE---
I've managed to solve the problem. As it turns out, there's an issue with trainerbattle 0x3 that causes it to play a second time with the default music if the music is changed with special 0x3B and playsong. The way to fix this is to rework it into a different battle type. I personally used trainerbattle 0x0, which turned out to work perfectly.