summaryrefslogtreecommitdiff
path: root/pokemontools/redmusicdisasm.py
diff options
context:
space:
mode:
authorU-Fish-PC\Daniel <corrnondacqb@yahoo.com>2013-10-22 02:24:37 -0400
committerU-Fish-PC\Daniel <corrnondacqb@yahoo.com>2013-10-22 02:24:37 -0400
commited174d243287d8c1fdae31d0b30e014d554c0241 (patch)
tree0fcff3238ba253eb0e75b838598a23a40a42f616 /pokemontools/redmusicdisasm.py
parentc57e0f0706608a4acba89182945bec975a43acfd (diff)
Update redmusicdisasm and redsfxdisasm
Diffstat (limited to 'pokemontools/redmusicdisasm.py')
-rwxr-xr-xpokemontools/redmusicdisasm.py23
1 files changed, 15 insertions, 8 deletions
diff --git a/pokemontools/redmusicdisasm.py b/pokemontools/redmusicdisasm.py
index ad370cd..3ed5a4d 100755
--- a/pokemontools/redmusicdisasm.py
+++ b/pokemontools/redmusicdisasm.py
@@ -1,5 +1,5 @@
-import config
-config = config.Config()
+import configuration
+config = configuration.Config()
rom = bytearray(open(config.rom_path, "r").read())
songs = [
@@ -49,22 +49,26 @@ songs = [
"MeetFemaleTrainer",
"MeetMaleTrainer",
"UnusedSong",
- #"SurfingPikachu",
- #"MeetJessieJames",
- #"YellowUnusedSong",
]
-
+"""
+songs = [
+ "YellowIntro",
+ "SurfingPikachu",
+ "MeetJessieJames",
+ "YellowUnusedSong",
+ ]
+"""
music_commands = {
0xd0: ["notetype", {"type": "nibble"}, 2],
0xe0: ["octave", 1],
- 0xe8: ["unknownmusic0xe8", 1],
+ 0xe8: ["togglecall", 1],
0xea: ["vibrato", {"type": "byte"}, {"type": "nibble"}, 3],
0xeb: ["pitchbend", {"type": "byte"}, {"type": "byte"}, 3],
0xec: ["duty", {"type": "byte"}, 2],
0xed: ["tempo", {"type": "byte"}, {"type": "byte"}, 3],
0xee: ["unknownmusic0xee", {"type": "byte"}, 2],
0xf0: ["stereopanning", {"type": "byte"}, 2],
- 0xf8: ["unknownmusic0xf8", 1],
+ 0xf8: ["executemusic", 1],
0xfc: ["dutycycle", {"type": "byte"}, 2],
0xfd: ["callchannel", {"type": "label"}, 3],
0xfe: ["loopchannel", {"type": "byte"}, {"type": "label"}, 4],
@@ -189,6 +193,7 @@ for i, songname in enumerate(songs):
if songname == "PalletTown": header = 0x822e
if songname == "GymLeaderBattle": header = 0x202be
if songname == "TitleScreen": header = 0x7c249
+ if songname == "YellowIntro": header = 0x7c294
if songname == "SurfingPikachu": header = 0x801cb
bank = header / 0x4000
startingaddress = rom[header + 2] * 0x100 + rom[header + 1] - 0x4000 + (0x4000 * bank)
@@ -212,6 +217,8 @@ for i, songname in enumerate(songs):
if curchannel == 1:
labels.append(0x719b)
labelsleft.append(0x719b)
+ labels.append(0x71a2)
+ labelsleft.append(0x71a2)
if curchannel == 2:
labels.append(0x721d)
labelsleft.append(0x721d)