Zophar's Message Domain

Go Back   Zophar's Message Domain > Emulation Talk > Rom Hack

Reply
 
Thread Tools Display Modes
Old 10-19-2008, 12:43 AM   #1
Caesura
Junior Member
 
Join Date: Oct 2008
Location: Iowa
Posts: 17
Default New here and looking for some help in a megaman hack

I'm simply trying to replace the megaman sprite with protoman (because protoman is a badass) and I've got the sprite down--I know how to anyway--and most of the color.

I have a problem though. During gameplay, once a check point is passed and the character dies, he comes back to the checkpoint in his original colors. Which sucks. If the pause menu is brought up the colors go back to custom! I'm working on this with the emulator FCEUXD SP. And I've checked out the hex editor and found the hex values where the color changes. If I "freeze" these values the colors work fine, but the problem isn't fixed for other emulators. I'd kind of like to be able to make this a permanent fix.

Anybody know how to fix this issue?
Caesura is offline   Reply With Quote
Old 10-19-2008, 01:02 AM   #2
Ugly Joe
Senior Member
 
Ugly Joe's Avatar
 
Join Date: Dec 2003
Posts: 1,461
Default

This would imply that Megaman's palette exists in more than one location in the ROM. You've successfully replaced one (or more) of them, but not all of them. Search the ROM for any remaining copies of Megaman's original palette and replace it with Protoman's palette.
__________________
Ugly Joe is offline   Reply With Quote
Old 10-19-2008, 02:33 AM   #3
Caesura
Junior Member
 
Join Date: Oct 2008
Location: Iowa
Posts: 17
Default

Okay, so I've gone through the hex and searched for any sequence of C211 (dark blue, light blue) and replaced all the results of the search with 3D06 (red, gray). During the game, it'll still revert though. I can see where it changes too. I just can't keep it changed.

During emulation though, only the hex only changes in "NES memory" view, and I can't change (or figure out how to) change that.

edit. and thanks for the help!
and 2C not C2 sorry

Last edited by Caesura; 10-21-2008 at 07:50 PM.
Caesura is offline   Reply With Quote
Old 10-19-2008, 04:04 AM   #4
Ugly Joe
Senior Member
 
Ugly Joe's Avatar
 
Join Date: Dec 2003
Posts: 1,461
Default

So you can see in the NES memory view where the color change is made? Like, you can see the bytes 3D 06 being overwritten with C2 11? If that's the case, you're probably best off using the debugger. Setup a write breakpoint for the memory addresses that are being used to store Megaman's palette. Play the game until you know it's going to write in the Megaman palette and then take a look at the debugger. With any luck, you'll be able to determine where it's pulling the old blue palette colors from.

Also, which Megaman game are you hacking?
__________________
Ugly Joe is offline   Reply With Quote
Old 10-19-2008, 06:49 AM   #5
Caesura
Junior Member
 
Join Date: Oct 2008
Location: Iowa
Posts: 17
Default

Yeah, I can see where it overwrites, and I know when it overwrites.

I looked into the debugger, but I haven't actually been able to understand it. I'm not sure how to make breakpoints and I definitely don't know how to write, or understand, conditions.

I'm just working on the first for now (it's definitely not my favorite). I figured it'd be the easiest to understand. This is my first ever hack. Besides playing with the sprites in that megaman 7 8-bit file.
Caesura is offline   Reply With Quote
Old 10-21-2008, 02:21 PM   #6
Caesura
Junior Member
 
Join Date: Oct 2008
Location: Iowa
Posts: 17
Default

I've messed around with the debugger a little bit. I still don't understand break points, but I found this:

$03E1:3D 06 0F AND $0F06,X @ $1005 = #$80(/DF)

and it gets overwritten by this:

$03E1:2C 11 0F BIT $0F11 = #$00

soooo... what does that mean? I'll keep messing around with it.
Caesura is offline   Reply With Quote
Old 10-22-2008, 02:07 AM   #7
The 9th Sage
Senior Member
 
The 9th Sage's Avatar
 
Join Date: Mar 2004
Location: NY State in the US
Posts: 17,439
Default

I have a friend who knows a LOT about Megaman, and he says this (note that I can't take credit for this):

Quote:
at 1C2AA is a routine that includes A9 2C and A9 11. the 2C and 11 are palette values he needs to change. he would have been able to find this by using FCEUXD's debugger and setting a write breakpoint on 3E1. when he respawns at either of the last two checkpoints, the debugger will break and show him the address where the palette writing is happening. going back a single instruction shows where the value is loaded from.
__________________
Just can't wait to bomb some Dodongos.
---
http://www.xanga.com/zeldadd

Twitter
The 9th Sage is offline   Reply With Quote
Old 10-22-2008, 04:10 AM   #8
Caesura
Junior Member
 
Join Date: Oct 2008
Location: Iowa
Posts: 17
Default

Thanks, and thank your friend for me!

That worked. I knew where to write the breakpoint but I don't know how to write conditions, which is why I couldn't do that part myself. Can anyone direct me to a good tutorial?
Caesura is offline   Reply With Quote
Old 10-22-2008, 11:21 AM   #9
Ugly Joe
Senior Member
 
Ugly Joe's Avatar
 
Join Date: Dec 2003
Posts: 1,461
Default

Check the second half of this post:

http://www.the-interweb.com/serendip....html#extended

That's the only documentation I've ever been able to find on FCEUXD SP's conditional breakpoints. It's really all you need, though.
__________________
Ugly Joe is offline   Reply With Quote
Old 10-23-2008, 02:15 PM   #10
Caesura
Junior Member
 
Join Date: Oct 2008
Location: Iowa
Posts: 17
Default

I've seen this, and read through it. I get lost around here:

"A condition is a simple C-style expression. Supported values are A (register), X (register), Y (register), N, V, U, B, D, I, Z, C (all flags), hex numbers of the form #1234 and values at (CPU) memory locations of the form $1234. These values can be compared using the operators ==, !=, >=, <=, > and <. Two or more expressions can be connected using conditional OR (||) or conditional AND (&&)."

The terms "register" "flags" and the multiple operations listed confuses me.
Caesura is offline   Reply With Quote
Reply

Thread Tools
Display Modes

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. The time now is 12:01 AM.

Contact Us - Zophar's Domain - Archive - Top

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.