• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

Development: Fancy Knowledge #3 - Using Two Different Musics In One Event

Mastermind_X

ASM-Hacker
92
Posts
17
Years
Fancy Knowledge #3 - Using Two Different Musics In One Event

Heyho. Some people asked how zel was able to use more than 1 music in his battles. I created that feature a year ago and called it "jukebox". I think it's time now to explain how it works... (I think zel won't have a problem if i tell it...)

You can find it here:
http://sfc.pokemon-inside.net/lesson.php?id=13&lang=en


greetz
MX

P.S. If you find offsets for other versions than Fire Red US and you want to share them with others post them in this thread or send me a PM.
 
230
Posts
16
Years
  • Seen Jan 3, 2010
Hey, the tutorial is really nice, it will find sure good use in many hacks.

I don't like being noobish and ask questions in wrong places, but isn't it October already, M_X? :P
 

cooley

///Keepin' it simple
1,148
Posts
17
Years
Very useful, indeed. I would make a tool, but I don't know if I can...or rather feel like it.
I'll be using this, and good luck! Especially with that Day&Night System ;)
 

Mastermind_X

ASM-Hacker
92
Posts
17
Years
Your page is kind of in disorder about the binary...
Anyway,thanks~

Uhm. What exactly do you mean? Oo

Edit: @ Martin™
It is. Well. Do you want to have a D/N system that crashes for unknown reasons when you switch pokemon in battle? ^^° I try to fix that problem... -.-
 
Last edited:
219
Posts
16
Years
Well,sorry for my bad English...I mean this:


picture.php
 

Lady Berlitz

Cinnamon ♪
1,770
Posts
16
Years
This tutorial seems quite useful. I liked how you said that it's "fancy knowledge", Mastermind.
I will definitely be using this in the future for my hack.

Thanks for writing/translating this, Mastermind.
 
230
Posts
16
Years
  • Seen Jan 3, 2010
@M_X: Ah, so that is the reason. Sorry then ^^" I hope you will be able to fix it.

Anyway, I am going to try out this tutorial, it will sure be great for me - already planned different wild Pokémon music on different parts of region. I would like to ask: Where the heck you know all this from? You're amazing, did you know?

@liuyanghejerry: Which browser are you using? If Internet Explorer 6- or one of browsers using its rendering engine (Maxthon for example), it should not be a surprise. If you're using a more standards-compilant browser such as IE8 or Firefox and the rest, then I have no idea.
 

Megiddo-san

Barium - Summer '12 Return?
1,308
Posts
16
Years
I have double checked my hex and have tried both hex and decimal for music values, but it isn't working for me. This is the script that changes it. #org @begin
setvar 0x1014 0x298
setvar 0x1016 0x299
message @this
boxset 6
release
end
#org @this
= Music test.
 

ZodiacDaGreat

Working on a Mobile System
429
Posts
17
Years
@Megiddo - It doesn't work like that, you have to use it before a wildbattle or trainerbattle. How?

1. Well, find the song that the wildbattle/trainerbattle plays.
2. Setvar 0x1014 the song it plays. (Original Song)
3. Setvar 0x1016 to the song you want it to play.

Ao, in simple terms its changing the played music, through setvars, by setting the original song to 0x1014 and set a new song to 0x1016. If the vars don't work, it can be changed:
0xcfff64:
[14 10 00 00] // nr of 1st variable containing music number to replace
[15 10 00 00] // nr of 2nd variable containing music number to replace
[16 10 00 00] // nr of 1st variable containing the value to replace with
[17 10 00 00] // nr of 2nd variable containing the value to replace with
[FF FF 00 00] // value the vars have to be set to in order to disable the track loader
[55 E4 06 08] // std_func_getvaradress + 1; don't change it!
[0F D1 1D 08] // return adress + 1
[9C 32 4A 08] // channel table (usually you don't have to change it)
[CC 32 4A 08] // pointer to the music-pointer-table
Change 1410, 1510, 1610, 1710 to something that works, thats the veryr reason why MX, block quoted this part.

Anyway, Good News is you may see a tool soon :)
 

Megiddo-san

Barium - Summer '12 Return?
1,308
Posts
16
Years
I think I need new ones. I tried putting them before a trainerbattle in a script. Thanks. I'm going to try others.

Edit: I just made that work by using different variables. It needn't be in the same script.
 
Last edited:

Drayano

Axe me a question, I dare you.
210
Posts
19
Years
I've tried to do this a couple times now and each time I try the game just stops; you try to load the game, the blue background of the intro opens, and it just stops there.

I've double checked the hex to make sure I've input it correctly and I've put it in the same locations as described on the tutorial, so I've also used the same pointer in the second part where I'm attaching it to the musicloader.

I tried toying around with the var numbers in the hex (the 14 10 00 00, 15 10 00 00 etc) but changing them didn't fix anything. As far as I can tell the Fire Red ROM started doing this intro freeze after I put in the hex that is in the first part of the tutorial.

Either way, I've tried this three odd times now and got the same result every time... would anyone happen to have any idea why the game keeps doing this whenever I put in the hex?

edit: Okay I took a look at AdvanceMap at the broken ROM and it seems that all of the tiles are broken :x
 
Last edited:
37
Posts
13
Years
  • Age 27
  • Seen Feb 7, 2014
Drayano, it doesn't work with my ROM either for some reason. I'm having the same problem as you. Luckily I made a backup.
 

thanethane98

Self Proclaimed Expert
82
Posts
11
Years
  • Seen Nov 16, 2013
Drayano, it doesn't work with my ROM either for some reason. I'm having the same problem as you. Luckily I made a backup.

I had the same problem at first, but I found out what I did wrong. You have to remember to flip your offset when putting it into the music loader. Such as, I had 0x810211 as my offset. So I originally put that in as 81 02 11 00, while I needed to put it in as 11 02 81 08. I'm not an expert with this, but I'm pretty sure that 08 always needs to go on the end of the offset, somebody can correct me if I'm wrong though.

Good luck!
 
13
Posts
13
Years
  • Seen Jan 31, 2014
When I go to this part Im kinda lost lol

01 49 08 47 00 00 [XX XX XX XX] 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

And my pointer is F1 FE CF 08 also but everytime i do this from 0x1DD0F6 to 0x1DD10E
my rom will end up crashing.
 

thanethane98

Self Proclaimed Expert
82
Posts
11
Years
  • Seen Nov 16, 2013
When I go to this part Im kinda lost lol

01 49 08 47 00 00 [XX XX XX XX] 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

And my pointer is F1 FE CF 08 also but everytime i do this from 0x1DD0F6 to 0x1DD10E
my rom will end up crashing.

How exactly does it crash? When I originally did this, my hex editor actually expanded the rom when I typed in stuff like this, which leads to the ROM being unusable.

I've actually managed to get this working, but to do it I had to take a look at another hack that had successfully done this. Take a look at Azure Horizons if you're stuck, the makers of it have it inserted and working correctly so it's a great example.
 
13
Posts
13
Years
  • Seen Jan 31, 2014
Thanks thanethane98 for the input. :)
It didn't crash this time and you was right that
was a great example.

Now all I need help is the setvar.
Btw. I am using pokescript.
 
Last edited:

thanethane98

Self Proclaimed Expert
82
Posts
11
Years
  • Seen Nov 16, 2013
Thanks thanethane98 for the input. :)
It didn't crash this time and you was right that
was a great example.

Now all I need help is the setvar.
Btw. I am using pokescript.
I believe with the modified version used in Azure Horizons it's 7030 and 7033. That worked for me in XSE, and it should work for you no matter what program you're using for scripting. :)
 

thanethane98

Self Proclaimed Expert
82
Posts
11
Years
  • Seen Nov 16, 2013
I've actually been looking for something like this for the last little bit, actually. I'll have to give this a try and give it a shot at implementing it in a hack.

Although, with a repointed sound table, this will be fun.

Good luck. :)

The only problem I've had with this at the moment is that it seems to have errors when you attempt to use it with a normal trainer (one that battles you when you're in their sight). Has anyone else had this issue?
 
13
Posts
13
Years
  • Seen Jan 31, 2014
#org $script
setvar 0x7030 0x297
setvar 0x7033 0xblah
trainerbattle 0x00 0x0001 $see $win
$see 1 = Battle me!
$win 1 = I lost.
message $after
$after 1 = You're tough.
boxset 6
release
end

This my script for pokescript
And it still not working for me.
Is it the same for xse :)
 
Last edited:
Back
Top