Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Zeldix :: MSU-1 Hacking :: MSU-1 Development :: Finished
Page 2 of 4
Page 2 of 4 • 1, 2, 3, 4
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
That's a lot to take in all at once. I'm going to keep at this until I get it though. Thank you once again for your time. I will probably ask for more help again in the next couple of days
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
I do that shit for 20 years now, so I trapped into all this. You can upload a trace log if snippets if it crashes and I look over it
Conn- Since : 2013-06-30
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
It feels like you won't be free until every game has a music hack made. lol. I'll do my best to try and help if I am able to.
I'm going to try to trace backwards until i can figure out why the databanks are called as they are
In sound test, they're loaded at 02e102 I believe, from $e1d5 - $e1d7 maybe there's a root to all of this with more sane numbers and easier hijacking... one can always dream
in stage 1 this gets loaded at 00c8b6 from $d098-d09a..
looking more into that, it seems many data banks are listed in order in here from d098 to d0af ... I have no ability to understand what's going on anymore. I'll call this one a goose chase and get back to writing code I think
I'm going to try to trace backwards until i can figure out why the databanks are called as they are
- Code:
Complete list of databanks:
81 ba 15
41 d6 08
05 ae 08
32 ed 15
1e b9 08
59 c6 08
34 ea 0a
cd cc 08
41 d6 08
ab e4 08
17 f7 08
a2 f2 0a
In sound test, they're loaded at 02e102 I believe, from $e1d5 - $e1d7 maybe there's a root to all of this with more sane numbers and easier hijacking... one can always dream
in stage 1 this gets loaded at 00c8b6 from $d098-d09a..
looking more into that, it seems many data banks are listed in order in here from d098 to d0af ... I have no ability to understand what's going on anymore. I'll call this one a goose chase and get back to writing code I think
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
You seem to have bad luck my friend. It looks like the music is hardcoded and doesn't use indexes. In the music menu, they are indexed on $0f92, but not in the game as far I see
This is then as pointer stored to $10-$12 in little endian:
In order to complete your music, I'd suggest to make a breakpoint in the sound menu ($08/8000) and look if the value at $10 differs for all tracks (e.g., 15/ba81 is the track 21 in the music bank), so track $81 for msu pcm. Strangely, the bank for mute is the same as for track 1 there (08/AE05) but this is probably steered via a play command (the stz $2140 mute addresses I gave in my previous post).
That's the pointer for the first track, pointing to $15/BA81 (alike you listed).$00/C72A A9 81 BA LDA #$BA81 A:00FF
$00/C72D A0 15 00 LDY #$0015 A:BA81
$00/C730 20 A9 8B JSR $8BA9 [$00:8BA9] A:BA81 X:0820 Y:0015
This is then as pointer stored to $10-$12 in little endian:
- Code:
$00/8BA9 C2 F8 REP #$F8 A:BA81 X:0820 Y:0015
$00/8BAB 85 10 STA $10 [$00:0010] A:BA81 X:0820 Y:0015
$00/8BAD 84 12 STY $12 [$00:0012] A:BA81 X:0820 Y:0015
$00/8BAF 22 00 80 08 JSL $088000[$08:8000] A:BA81 X:0820 Y:0015
In order to complete your music, I'd suggest to make a breakpoint in the sound menu ($08/8000) and look if the value at $10 differs for all tracks (e.g., 15/ba81 is the track 21 in the music bank), so track $81 for msu pcm. Strangely, the bank for mute is the same as for track 1 there (08/AE05) but this is probably steered via a play command (the stz $2140 mute addresses I gave in my previous post).
Conn- Since : 2013-06-30
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Quickly copied the values
$10, $11, $12
0 05 ae 08
1 05 ae 08
2 32 ed 15
3 1e b9 08
4 59 c6 08
5 34 ea 0a
6 cd cc 08
7 05 ae 08
8 32 ed 15
9 32 ed 15
10 32 ed 15
11 41 d6 08
12 41 d6 08
13 41 d6 08
14 41 d6 08
15 ab e4 08
16 ab e4 08
17 ab e4 08
18 ab e4 08
19 17 f7 08
20 17 f7 08
21 81 ba 15
22 1e b9 08
23 cd cc 08
24 a2 f2 0a
So even more bad luck you have music banks as well.
So when tracks use the same pointers, e.g. 11 - 14, you need to differ from the bank that is stored in the menu here:
$02/E156 8D 40 21 STA $2140 [$02:2140] A:4102
Track 11: $02/E156 8D 40 21 STA $2140 [$02:2140] A:4101
Track 12: $02/E156 8D 40 21 STA $2140 [$02:2140] A:4102
Track 13: $02/E156 8D 40 21 STA $2140 [$02:2140] A:4104
Track 14: $02/E156 8D 40 21 STA $2140 [$02:2140] A:4105
So yes, complex. Somehow e.g., above is missing the value 03, but it is a valid track.
Edit: pointer 41 d6 08 and bank 03 lead to track 19 somehow.
$10, $11, $12
0 05 ae 08
1 05 ae 08
2 32 ed 15
3 1e b9 08
4 59 c6 08
5 34 ea 0a
6 cd cc 08
7 05 ae 08
8 32 ed 15
9 32 ed 15
10 32 ed 15
11 41 d6 08
12 41 d6 08
13 41 d6 08
14 41 d6 08
15 ab e4 08
16 ab e4 08
17 ab e4 08
18 ab e4 08
19 17 f7 08
20 17 f7 08
21 81 ba 15
22 1e b9 08
23 cd cc 08
24 a2 f2 0a
So even more bad luck you have music banks as well.
So when tracks use the same pointers, e.g. 11 - 14, you need to differ from the bank that is stored in the menu here:
$02/E156 8D 40 21 STA $2140 [$02:2140] A:4102
Track 11: $02/E156 8D 40 21 STA $2140 [$02:2140] A:4101
Track 12: $02/E156 8D 40 21 STA $2140 [$02:2140] A:4102
Track 13: $02/E156 8D 40 21 STA $2140 [$02:2140] A:4104
Track 14: $02/E156 8D 40 21 STA $2140 [$02:2140] A:4105
So yes, complex. Somehow e.g., above is missing the value 03, but it is a valid track.
Edit: pointer 41 d6 08 and bank 03 lead to track 19 somehow.
Conn- Since : 2013-06-30
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Thanks for taking the time to work on that game
I didn't do much progress with the soundtrack recently, but I did a master of 12 tracks (out of 24), so they are pretty much done. I already started a few other tracks, but I'm not happy with them yet.
I didn't do much progress with the soundtrack recently, but I did a master of 12 tracks (out of 24), so they are pretty much done. I already started a few other tracks, but I'm not happy with them yet.
JustinBailey- Rope
- Since : 2021-08-05
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Conn, you don't need to work more on this game.. I think I have it. if you do want to, that is OK, but I absolutely think I can pull this off now.
Some songs are in multiple databanks. every "stage" databank has a boss intro track on 3. every "stage" has the map music (not played in sound test due to a bug) on 1.
Some stages have additional boss themes or stage themes on 4 5 and 6. I did a play through of the game and wrote down every track that was used and what the accumulator values were. I should be able to use the accumulator value and the databank to determine the track to play.
Thanks for checking it out, JustinBailey, and thank you for the tracks you have already done. Is there a way for you to share your current work so some could be converted for a proof-of-concept on the hack?
Take your time finishing the other tracks, and only if you want to, there's no pressure here, the "worst case" scenario is this game doesn't get a music pack until the remake comes out next spring.
Some songs are in multiple databanks. every "stage" databank has a boss intro track on 3. every "stage" has the map music (not played in sound test due to a bug) on 1.
Some stages have additional boss themes or stage themes on 4 5 and 6. I did a play through of the game and wrote down every track that was used and what the accumulator values were. I should be able to use the accumulator value and the databank to determine the track to play.
JustinBailey wrote:Thanks for taking the time to work on that game
I didn't do much progress with the soundtrack recently, but I did a master of 12 tracks (out of 24), so they are pretty much done. I already started a few other tracks, but I'm not happy with them yet.
Thanks for checking it out, JustinBailey, and thank you for the tracks you have already done. Is there a way for you to share your current work so some could be converted for a proof-of-concept on the hack?
Take your time finishing the other tracks, and only if you want to, there's no pressure here, the "worst case" scenario is this game doesn't get a music pack until the remake comes out next spring.
Last edited by Cubear on Fri 26 Nov 2021 - 0:58; edited 1 time in total
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
The current state of my hack is: I have the SPC mute working with some minor glitches, I think I need to move my breakpoints and NOP out some command fragments like you said earlier.
I am collecting the currently playing databank and the currently playing track to some free ram that did not get touched during a run of the game or in the sound test.
This means at any given moment I have all the data I need to play correct tracks via MSU-1, collected in a space that only I update.
My ASM is kind of shaky still but all I need is to somehow combine two numbers into one. Maybe just by adding them together. The databank pointer that goes onto $10 (moved to $0172) and the current accumulator value. that is enough information to select track, but some combinations are all going to lead to the same pcm being played.
Something I'd like to do is fix the sound test code so PCM packs are easier to test in there. 14 and 16 are both the same song and I believe one of them was intended to be the map music. you can see they're both in different databanks.
I may be able to fix this for just MSU1 music by making a special case for it, but ideally I'd fix it in the rom itself if I had the know-how lol.
Eventually I will need to figure out the fadeout code for the songs and how the game calls music dimming when you pause, but it hasn't been a focus yet. I also don't exactly know how I'm going to include SPC fallback, but I'm sure I can figure it out. I do have all the data I need for it
I am collecting the currently playing databank and the currently playing track to some free ram that did not get touched during a run of the game or in the sound test.
This means at any given moment I have all the data I need to play correct tracks via MSU-1, collected in a space that only I update.
My ASM is kind of shaky still but all I need is to somehow combine two numbers into one. Maybe just by adding them together. The databank pointer that goes onto $10 (moved to $0172) and the current accumulator value. that is enough information to select track, but some combinations are all going to lead to the same pcm being played.
Something I'd like to do is fix the sound test code so PCM packs are easier to test in there. 14 and 16 are both the same song and I believe one of them was intended to be the map music. you can see they're both in different databanks.
I may be able to fix this for just MSU1 music by making a special case for it, but ideally I'd fix it in the rom itself if I had the know-how lol.
Eventually I will need to figure out the fadeout code for the songs and how the game calls music dimming when you pause, but it hasn't been a focus yet. I also don't exactly know how I'm going to include SPC fallback, but I'm sure I can figure it out. I do have all the data I need for it
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Adding the accumulator to $10 or $11 will not work to come up with a value for track playing. there is just a little too much overlap between values, sadly.
Perhaps I need to check the initial values and write them as 10 20 30 40 50 60 70 80 90 a0 b0 and then the accumulator value can be the second digit, like a1 a2 a3 a4 a5 a6 to load the track.. it certainly would be more human readable in the end after that translation. lol
Perhaps I need to check the initial values and write them as 10 20 30 40 50 60 70 80 90 a0 b0 and then the accumulator value can be the second digit, like a1 a2 a3 a4 a5 a6 to load the track.. it certainly would be more human readable in the end after that translation. lol
Last edited by Cubear on Thu 25 Nov 2021 - 14:42; edited 1 time in total
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
I think thère are 12 distinct pointers, so you can map like this:
Pointer 05 ae 08 :pcm $00-0f
Pointer 32 ed 15: pcm $10-1f
And so on.
Then simply add the track upon,
Example:
Tracks 11-14 use the same pointers but different entries then, so you can map the pointer to
$30-3f and have track $31, $32, $34 $35 as pcm then.
Be sure you clear the carry before adding anything, otherwise you cause glitches.
Code looks like
Lda $7e0010
CMP #$41
Bne next compare
Lda #$30
CLC
ADC $track number ram
Sta $2004
...
Pointer 05 ae 08 :pcm $00-0f
Pointer 32 ed 15: pcm $10-1f
And so on.
Then simply add the track upon,
Example:
Tracks 11-14 use the same pointers but different entries then, so you can map the pointer to
$30-3f and have track $31, $32, $34 $35 as pcm then.
Be sure you clear the carry before adding anything, otherwise you cause glitches.
Code looks like
Lda $7e0010
CMP #$41
Bne next compare
Lda #$30
CLC
ADC $track number ram
Sta $2004
...
Conn- Since : 2013-06-30
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Thanks! And sure, no problem. Do you need a specific format?Cubear wrote:Thanks for checking it out, JustinBailey, and thank you for the tracks you have already done. Is there a way for you to share your current work so some could be converted for a proof-of-concept on the hack?
Check your PM
JustinBailey- Rope
- Since : 2021-08-05
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
JustinBailey wrote:Thanks! And sure, no problem. Do you need a specific format?Cubear wrote:Thanks for checking it out, JustinBailey, and thank you for the tracks you have already done. Is there a way for you to share your current work so some could be converted for a proof-of-concept on the hack?
Check your PM
Any format is generally fine. They will all need to be converted to PCM @ 44100 Hz in order to be used. I've done a little bit of this in the past, but if you'd like to learn, be my guest. I certainly will not refuse any help on this.
I used the tutorial at https://forum.starmen.net/forum/Community/PKHack/MSU1-A-sort-of-tutorial-showcasing in order to convert my first tracks, including setting loop points etc.
Edit: I'm giving them a listen now and I think you've done a fantastic job on your arrangements. You probably have a better idea of where you want them to loop than I would. I should make a list of which tracks need to loop but I think it might be "everything aside from "map"
Last edited by Cubear on Fri 26 Nov 2021 - 20:09; edited 2 times in total
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
In other news the hack is at the final stages for a proof-of-concept.
These final bits are really tricky though and I just KNOW there's an easier way to do what I'm doing. I just have no idea what it may be.
I've condensed the "track play" A value down to one byte, databank on the tens, track number on the ones. I don't know how to map multiple tracks to the same number of MSU1 PCM track in a nice way.
I think I'll just do a real hacky solution for now and let Conn groan at my bad code lol.
so far here is the track list, sound test values on the left, my internal values on the right
These final bits are really tricky though and I just KNOW there's an easier way to do what I'm doing. I just have no idea what it may be.
I've condensed the "track play" A value down to one byte, databank on the tens, track number on the ones. I don't know how to map multiple tracks to the same number of MSU1 PCM track in a nice way.
I think I'll just do a real hacky solution for now and let Conn groan at my bad code lol.
so far here is the track list, sound test values on the left, my internal values on the right
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
If you finished your asm in some sort you could always send it to me so I take a glimpse at it - to e.g., verify hooks and such.
I think a mute track is always perfect if you let the spc play pointer 05 ae 08 with track 0 here
I think a mute track is always perfect if you let the spc play pointer 05 ae 08 with track 0 here
Conn- Since : 2013-06-30
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
I'll just post it publically! I'm not ashamed, being that this is my first work, I think I am doing really good.
The rom does need to be expanded in order to apply this patch. I just could not find any freespace in the rom at all.
I do not have: SPC fallback. MSU-1 detection, MSU-1 playing, Fades, Dimming, or anything else of this sort. The patch at this point writes a lot of information to ram values around the $0170 mark since it didn't seem to be accessed at all.
Essentially, right now this patch mutes all the music and collects data for me. It will NOT play any replacement soundtrack. I also didnt test it after I made a bunch of edits to it.... be kind
e: ok. the edits i did broke every single thing. let me tinker with things a bit before i repost this
The rom does need to be expanded in order to apply this patch. I just could not find any freespace in the rom at all.
I do not have: SPC fallback. MSU-1 detection, MSU-1 playing, Fades, Dimming, or anything else of this sort. The patch at this point writes a lot of information to ram values around the $0170 mark since it didn't seem to be accessed at all.
Essentially, right now this patch mutes all the music and collects data for me. It will NOT play any replacement soundtrack. I also didnt test it after I made a bunch of edits to it.... be kind
e: ok. the edits i did broke every single thing. let me tinker with things a bit before i repost this
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Okay, here it is! I've commented out the jump to my track enumerator code for now as that is wholly untested.. but it looks like it should work?
it's only step one of two though, still need to figure out multiple values to the same track.
there's also one fairly big glitch that I can find. It crashes when moving from the main menu to the attract mode / demo. it seems to be running $00d25f which doesn't properly exist.
Not sure how to fix this.
it's only step one of two though, still need to figure out multiple values to the same track.
there's also one fairly big glitch that I can find. It crashes when moving from the main menu to the attract mode / demo. it seems to be running $00d25f which doesn't properly exist.
Not sure how to fix this.
- Attachments
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Nice! I am glad to see you are making progress! That is awesome, great work
JUD6MENT- Since : 2018-04-19
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Yeah! I'm looking forward to having some play testers soon!
the crash for demo/attract is because it calls yet another different address to write the track number to the SPC. the demo is silent though, so i just need to make it jump to the right address to not crash and it should be fine.
E: I've fixed this crash in a kind of destructive way but its fine.
Once I can translate my track addresses into something readable by the MSU1 I will be on easy street.
the crash for demo/attract is because it calls yet another different address to write the track number to the SPC. the demo is silent though, so i just need to make it jump to the right address to not crash and it should be fine.
E: I've fixed this crash in a kind of destructive way but its fine.
Once I can translate my track addresses into something readable by the MSU1 I will be on easy street.
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
That asm looks very nice, much better than those I usually write
The hook point at 08/802c doesn't look very good though, it is called multiple times..
I'd make it this way:
;----------------------------
; hook area
;index the database pointer that is already at $10
org $088011
JSL pointer
;get track index out of db (these are multiple calls
org $00/D25A ;covers some musics
JSL playtrack1
NOP
;level music
org $00cd4a
JSL playtrack2
NOP
;soundmenu
org 02e154
JSL soundmenu
NOP
;----------------------------------------
; free code area
; map db to high 4bit
org $208000
pointer:
SEP #$20 ; part of native hook overwritten code
LDA $10; lowest byte to differentiate music databank
; map tracks to $0180
cmp #$05; db1
BNE $07
LDA #$10
STA $0180
jmp endPointer
cmp #$32; db2
BNE $07
LDA #$20
STA $0180
jmp endPointer
....; rest db entries here: copy paste mainly
; if nothing found, e.g. pre-title screen
LDA #$CC
RTL
endPointer:
; mute (write 81 ba 15 to $10)
LDA #$81
STA $10
LDA #$ba
STA $11
LDA #$15
STA $12
LDA #$CC ; part of native code
RTL
;-----------------------------------
; track indicies (map track indicies to low 4bit)
playtrack1:
SEP #$20
CLC
ADC $0180
STA $0180 ; track with index is now at $0180
JSR msu
LDA #$00 ;mute it
STA $2140
RTL
playtrack2: ; level music
LDA #$02
CLC
ADC $0180
sta $0180
jsr msu
LDA #$00 ;mute it
STA $2140
RTL
soundmenu:
SEP #$20
CLC
ADC $0180
STA $0180
jsr msu
lda #$00
STA $2140 ;(mute
;-----msu code stuff
msu:
LDA $0180
STA $2004
STZ $2005
STZ $2006
loop:
Bit $2000
BVS loop
;---- if you have no loop tracks
lda $0180
cmp #$xx ;1st noloop track
beq noloop
cmp #$yy ;2nd noloop track
beq noloop
;.......
LDA #$03 ;all other loop
bra $02
noloop:
LDA #$01
STA $2007
LDA #$FF
STA $2006
RTS
; COMMON NOTE, be carefeul with these pre-game stuff
$08/8011 gets 3 breakpoints prior the title screen. These cases should be handled (do nothing)
The hook point at 08/802c doesn't look very good though, it is called multiple times..
I'd make it this way:
;----------------------------
; hook area
;index the database pointer that is already at $10
org $088011
JSL pointer
;get track index out of db (these are multiple calls
org $00/D25A ;covers some musics
JSL playtrack1
NOP
;level music
org $00cd4a
JSL playtrack2
NOP
;soundmenu
org 02e154
JSL soundmenu
NOP
;----------------------------------------
; free code area
; map db to high 4bit
org $208000
pointer:
SEP #$20 ; part of native hook overwritten code
LDA $10; lowest byte to differentiate music databank
; map tracks to $0180
cmp #$05; db1
BNE $07
LDA #$10
STA $0180
jmp endPointer
cmp #$32; db2
BNE $07
LDA #$20
STA $0180
jmp endPointer
....; rest db entries here: copy paste mainly
; if nothing found, e.g. pre-title screen
LDA #$CC
RTL
endPointer:
; mute (write 81 ba 15 to $10)
LDA #$81
STA $10
LDA #$ba
STA $11
LDA #$15
STA $12
LDA #$CC ; part of native code
RTL
;-----------------------------------
; track indicies (map track indicies to low 4bit)
playtrack1:
SEP #$20
CLC
ADC $0180
STA $0180 ; track with index is now at $0180
JSR msu
LDA #$00 ;mute it
STA $2140
RTL
playtrack2: ; level music
LDA #$02
CLC
ADC $0180
sta $0180
jsr msu
LDA #$00 ;mute it
STA $2140
RTL
soundmenu:
SEP #$20
CLC
ADC $0180
STA $0180
jsr msu
lda #$00
STA $2140 ;(mute
;-----msu code stuff
msu:
LDA $0180
STA $2004
STZ $2005
STZ $2006
loop:
Bit $2000
BVS loop
;---- if you have no loop tracks
lda $0180
cmp #$xx ;1st noloop track
beq noloop
cmp #$yy ;2nd noloop track
beq noloop
;.......
LDA #$03 ;all other loop
bra $02
noloop:
LDA #$01
STA $2007
LDA #$FF
STA $2006
RTS
; COMMON NOTE, be carefeul with these pre-game stuff
$08/8011 gets 3 breakpoints prior the title screen. These cases should be handled (do nothing)
Conn- Since : 2013-06-30
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
It's going to take me a long time to work through that post!
And yeah, I thought about trying to nix the 088000 area hook, i did move it earlier in to that zone to avoid it loading so much, just like you did... but I can't hook during track play because $10-$12 change by the time it is called. Can only read those addresses during databank load, which is all in there afaik. I tried to keep everything in there as "light" as possible to hopefully not mess it up.
I've done lots of work / corrections since I posted my file, I was just about to update the post with a new one and then I see you saw all my bad and wrong code. oops
And yeah, I thought about trying to nix the 088000 area hook, i did move it earlier in to that zone to avoid it loading so much, just like you did... but I can't hook during track play because $10-$12 change by the time it is called. Can only read those addresses during databank load, which is all in there afaik. I tried to keep everything in there as "light" as possible to hopefully not mess it up.
I've done lots of work / corrections since I posted my file, I was just about to update the post with a new one and then I see you saw all my bad and wrong code. oops
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
The code I posted above could actually work already (xkas and lorom on top), only the database mapping is missing I will test it with the sound menu later probably
Conn- Since : 2013-06-30
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
I never intended for you to do so much work on this!
Conn, I think the most useful information you can give me now is how the MSU1 chip knows which numbers are for which tracks. I can't seem to find it anywhere.
Do I need to translate everything down to $01-$18 or could I somehow map other numbers to that easily?
Conn, I think the most useful information you can give me now is how the MSU1 chip knows which numbers are for which tracks. I can't seem to find it anywhere.
Do I need to translate everything down to $01-$18 or could I somehow map other numbers to that easily?
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
You have 11 music banks.
I mapped them by the pointer at 7e0010:
I checked the value at $10 being 41 and if yes, it should play pcm $60-6f. This I made with
lda #$60
STA $0180 (free ram)
$02e154
In the game it is for intro $00D25A for level $00cd48... and so on.
Then I just added the picked value to $0180:
further I didn't come, I surely don't play to the boss to have its hook.
Attached asm works so far, you can map all tracks by making a breakpoint 2004 in the music test menu. It also plays the msu music with a mute.
Note: there is no spc fallback (and not easily to implement) so better have all tracks substitute
Rom should be 1.5 MB (expand first before applying the asm, otherwise use the ips, it expands automatically.
Have fun
I mapped them by the pointer at 7e0010:
- Code:
; $10, $11, $12
; index $0x: 05 ae 08: tracks 0(mute), 1, 7
; index $1x: 32 ed 15: tracks 2, 8, 9 10
; index $2x: 1e b9 08: tracks 3, 22
; index $3x: 59 c6 08: tracks 4
; index $4x: 34 ea 0a: tracks 5
; index $5x: cd cc 08: tracks 6, 23
; index $6x: 41 d6 08: tracks 11, 12, 13 14
; index $7x: ab e4 08: tracks 15, 16, 17, 18
; index $8x: 17 f7 08: tracks 19, 20
; index $9x: 81 ba 15: tracks 21
; index $ax: a2 f2 0a; tracks 24
I checked the value at $10 being 41 and if yes, it should play pcm $60-6f. This I made with
lda #$60
STA $0180 (free ram)
- Code:
cmp #$41; tracks 11,12,13,14
BNE $08
LDA #$60
STA $0180
jmp endPointer
$02e154
In the game it is for intro $00D25A for level $00cd48... and so on.
Then I just added the picked value to $0180:
- Code:
SEP #$20
CLC
ADC $0180
STA $0180 ; track with index is now at $0180
JSR msu
further I didn't come, I surely don't play to the boss to have its hook.
Attached asm works so far, you can map all tracks by making a breakpoint 2004 in the music test menu. It also plays the msu music with a mute.
Note: there is no spc fallback (and not easily to implement) so better have all tracks substitute
Rom should be 1.5 MB (expand first before applying the asm, otherwise use the ips, it expands automatically.
Have fun
Conn- Since : 2013-06-30
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
You beat me to it lol. you rat. you fink.
JK JK much love.
I'm still going to finish off mine and post it up. i just about have it translating all the different permutations for databank + track to sound test track number. Mine also has all the hooks i think it needs for a full playthrough. I may even be able to get SPC fallback working, given enough time.
JK JK much love.
I'm still going to finish off mine and post it up. i just about have it translating all the different permutations for databank + track to sound test track number. Mine also has all the hooks i think it needs for a full playthrough. I may even be able to get SPC fallback working, given enough time.
Re: Pocky & Rocky / Kiki Kaikai: Nazo no Kuro Manto
Lol, I didn't beat you, only tried to help you. I think the asm I pulled up works so far, so you can adapt as much as you like. It's all your project
Conn- Since : 2013-06-30
Page 2 of 4 • 1, 2, 3, 4
Zeldix :: MSU-1 Hacking :: MSU-1 Development :: Finished
Page 2 of 4
Permissions in this forum:
You cannot reply to topics in this forum