Register | Login
Views: 19364387
Main | Memberlist | Active users | ACS | Commons | Calendar | Online users
Ranks | FAQ | Color Chart | Photo album | IRC Chat
11-02-05 12:59 PM
1 user currently in Rom Hacking: hukka | 2 guests
Acmlm's Board - I2 Archive - Rom Hacking - This may very well be, a stupid question.
  
User name:
Password:
Reply:
 

UserPost
Heian-794
Posts: 649/896
Thanks for that, NetSplit! That document looks really complete and useful; hadn't seen it before.
NetSplit
Posts: 11/117
Why did you make a new thread?

And yes, it's possible to change the color of an individual background tile in one specific NES mapper, but that won't realy help you in this situation. If you mean sprite tiles, though, then I'd imagine it's fairly easy to do in SMB. I'm sure there's someone here with more knowledge about the SMB ROM than I who could help you out, if this is what you're trying to do.

Additionally, Heian-794, I wouldn't recommend that color table. The one in The Art of ROM Hacking is much better; I wouldn't trust any table that shows 1D as black.
Parasyte
Posts: 302/514
Changing the palette used by a single sprite tile is very easy. You can use FCEUXD to peek at the sprite memory, and with some knowledge of the NES sprite format (available in Y0SHi's nestech.txt) you can figure out which of the 64 sprite tiles is the one you wish to change. From there, work backwards through the use of write breakpoints to discover which routine sets the palette for the tile, and where the palette data actually comes from.

In order to change the palette of a single background tile, you will find much more difficult. As mentioned, it is impossible to change the palette used by a single background tile on NES without the use of the MMC5 mapper (and even this takes a bit of work to accomplish). Once again, Y0SHi's nestech.txt will help you understand how backgrounds are built on NES. Backgrounds are created from two seperate 'tables' - one to place the tiles (name table), and another to set the palette for those tiles (attribute table). The attribute table is set up in a way that it DOES NOT allow setting the palette to only a single tile. Instead, each 2-bit entry in the attribute table will assign a palette to 4 tiles in a 2x2 grid. If you do the math, each byte contains 4 entries (2-bit * 4 = 8-bit = 1 byte).
If that's not confusing enough, finding where and how the attribute table is setup also requires write breakpoints and 'fluent' assembly knowledge.


With that taken care of, may I ask what it is you want to change? Someone may already have the information you are looking for.
tuna
Posts: 232/2
Changing the palette of one 8x8 tile is, in fact, impossible without using a certain mapper. You're better off just changing the palette of all of them, since just changing one tile is rediculously hard and such.

Also, make sure the tile (or object) you want to change doesn't have another version with another palette.
phishit
Posts: 13/13
ahh thanks for that information. i understand how too change the color for the game but not an individual tile. Anyone know how to do this
Heian-794
Posts: 647/896
This is not at all a stupid question, and is in fact a bit complicated.

If you're running FCEUXD or Nesticle, you should be able to check the palette. Find the code for the color of the tile you want to edit on this nifty chart:

http://www.spoonybard.com/docs/paletdat.html

(For example, 08 is brown. Let's imagine that you want to make that brown into light grassy green, 29.)

And then find that in the ROM, which is much easier said than done in many cases. A helpful hint is to look at the sequence of palette colors used in the emulator and search for them all in a row; e. g. brown-magenta-orange, also known as 08-15-16. There should be many fewer instances of 081516 than just 08, which would be the proverbial needle in a haystack. Find the 081516 and change it to 291516. Now see if the tile you want to change is different. If it isn't, then you changed the wrong byte, so try again.

BTW, if what you're asking is how to change the color of one tile while leaving other examples of the same tile, which are on the screen at the same time, unchanged, then I'll have to defer to more knowledgeable hackers, who will presumably toss a barrage of flames my way.

Heian
phishit
Posts: 12/13
But How do you change the color of an individual tile in an NES game? I am currently working on SMB1 and it would be real helpful if i knew how to do this. I know its possible, because in super luigi by darknight the colors are different than normal. Is there a simple way to do this or do i have to go through a s***load of programming?
Acmlm's Board - I2 Archive - Rom Hacking - This may very well be, a stupid question.


ABII


AcmlmBoard vl.ol (11-01-05)
© 2000-2005 Acmlm, Emuz, et al



Page rendered in 0.003 seconds.