Hey,
First post. I'm in the early stages of starting my adventures in NES development. One thing I just don't understand is how characters like the ones in Double Dragon II were made. What I mean is that if I understand correctly only three colors are allowed on a character (with one transparency). I've seen a video in which the eyes of Marion in Mario 2 were created using a white box.
But the Double Dragon characters seem to have black outlines, highlights and more. Unless I'm counting wrong, some have at least 4-5 colors.
I'm starting my character design and I don't understand how this is being done and if I am able to implement the same thing for my characters (Making a Beat 'em up.)
Thanks!
How were sprites like the characters from Double Dragon II done? (Palette)
-
ImperialWalker
- Posts: 9
- Joined: Thu Mar 20, 2025 10:42 pm
-
tokumaru
- Posts: 12673
- Joined: Sat Feb 12, 2005 9:43 pm
- Location: Rio de Janeiro - Brazil
Re: How were sprites like the characters from Double Dragon II done? (Palette)
Individual sprites (i.e. 8x8 or 8x16 units) can only use a single palette (i.e. transparency + 3 colors), but that doesn't mean that ALL units have to use the same palette. In some games, such as Contra, there's a clear separation between the sprites that use different palettes (from the waist up it's one palette, from the waist down it's another). In other games, the sprites are mixed in more elaborate ways and it isn't so easy to tell where exactly the splits/overlaps are.
So the answer is yes, you can use more than 3 colors when designing NES sprites, but you have to be very mindful of your resources:
1- If you're gonna be using 2 or more palettes on a single character, it's obvious that these palettes can't be exclusive to this character because the NES only has 4 palettes for ALL sprites on the screen! So choose your colors carefully, so that the same palettes can be reused across many different characters.
2- Since the NES can only show 8 sprites per scanline, you can't go all out and overlap a bunch of them to create a 6 or 9-color sprite with no restrictions of which colors go where, or your game will be an absolute flicker fest. Try to avoid more than 3 sprites sharing the same horizontal lines, because if you get to 4 that's already half of your sprite budget spent on a single character.
Basically, plan your sprites carefully if you want them to have more than 3 colors each. If you can split the colors vertically like in Contra, that's the least wasteful way to give the impression of more colors. If you need more than 3 colors for a specific are such as the face, you can throw 1 extra sprite in there like in SMB2 or Mega Man. What you really can't do is add a second layer of sprites on top of the whole sprite, because that'll eat through your sprite budget in a heartbeat.
If you haven't tried it already, open a game that you think has interest sprites in Mesen and take a look at its sprite viewer - there you can hover the mouse over the individual sprites to see how larger characters are formed. You may want to pause the emulation though, because most NES games have some form of sprite cycling that shuffles their positions in the OAM, so things might hard to follow if emulation isn't paused.
So the answer is yes, you can use more than 3 colors when designing NES sprites, but you have to be very mindful of your resources:
1- If you're gonna be using 2 or more palettes on a single character, it's obvious that these palettes can't be exclusive to this character because the NES only has 4 palettes for ALL sprites on the screen! So choose your colors carefully, so that the same palettes can be reused across many different characters.
2- Since the NES can only show 8 sprites per scanline, you can't go all out and overlap a bunch of them to create a 6 or 9-color sprite with no restrictions of which colors go where, or your game will be an absolute flicker fest. Try to avoid more than 3 sprites sharing the same horizontal lines, because if you get to 4 that's already half of your sprite budget spent on a single character.
Basically, plan your sprites carefully if you want them to have more than 3 colors each. If you can split the colors vertically like in Contra, that's the least wasteful way to give the impression of more colors. If you need more than 3 colors for a specific are such as the face, you can throw 1 extra sprite in there like in SMB2 or Mega Man. What you really can't do is add a second layer of sprites on top of the whole sprite, because that'll eat through your sprite budget in a heartbeat.
If you haven't tried it already, open a game that you think has interest sprites in Mesen and take a look at its sprite viewer - there you can hover the mouse over the individual sprites to see how larger characters are formed. You may want to pause the emulation though, because most NES games have some form of sprite cycling that shuffles their positions in the OAM, so things might hard to follow if emulation isn't paused.
Last edited by tokumaru on Fri Mar 21, 2025 12:03 am, edited 2 times in total.
-
Gilbert
- Posts: 616
- Joined: Sun Dec 12, 2010 10:27 pm
- Location: Hong Kong
Re: How were sprites like the characters from Double Dragon II done? (Palette)
By cleverly spliting the sprites into regions that use tiles of different palettes, and overlaying tiles of different palettes.
Take this sprite of Billy for example: It's split into the top (head), middle (body) and bottom (feet) regions, with the top and bottom regions using one palette of 3 colours and the middle using another palette.
I think (part of?) the hand uses tiles overlaid on the body.
Note that I haven't really checked the game at the moment, but I just analyse it from a screenshot.
The actual implementation shouldn't be too far off.
Actually the first game uses similar tricks, but the developers had better experience when making the sequel to have sprites with shading that look more colourful.
(ninjaed by tokumaru)
Take this sprite of Billy for example: It's split into the top (head), middle (body) and bottom (feet) regions, with the top and bottom regions using one palette of 3 colours and the middle using another palette.
I think (part of?) the hand uses tiles overlaid on the body.
Note that I haven't really checked the game at the moment, but I just analyse it from a screenshot.
The actual implementation shouldn't be too far off.
Actually the first game uses similar tricks, but the developers had better experience when making the sequel to have sprites with shading that look more colourful.
(ninjaed by tokumaru)
You do not have the required permissions to view the files attached to this post.
-
tokumaru
- Posts: 12673
- Joined: Sat Feb 12, 2005 9:43 pm
- Location: Rio de Janeiro - Brazil
Re: How were sprites like the characters from Double Dragon II done? (Palette)
If you have an artist doing the art for you, these limitations may be hard to explain if the person is not already familiar with the hardware's limitations. There are many good artists out there that will ask you "how many colors per sprite?", and if you go "well, sometimes 3, sometimes 6, and it depends on the part of the character you're drawing" they might be very confused!
So take your time explaining the technical limitations to them, and provide lots of examples of how existing games combine sprites that use different palettes to form more colorful characters (outline the individual sprites, show which palettes are shared among all characters, etc.) and never, ever let them forget that there can only be 8 sprites per scanline, so they absolutely can't go crazy with the sprite overlap.
So take your time explaining the technical limitations to them, and provide lots of examples of how existing games combine sprites that use different palettes to form more colorful characters (outline the individual sprites, show which palettes are shared among all characters, etc.) and never, ever let them forget that there can only be 8 sprites per scanline, so they absolutely can't go crazy with the sprite overlap.
-
ImperialWalker
- Posts: 9
- Joined: Thu Mar 20, 2025 10:42 pm
Re: How were sprites like the characters from Double Dragon II done? (Palette)
Thanks for the explanation. Sorry I didn't respond earlier I didn't get notifications of any replies.tokumaru wrote: Thu Mar 20, 2025 11:55 pm Individual sprites (i.e. 8x8 or 8x16 units) can only use a single palette (i.e. transparency + 3 colors), but that doesn't mean that ALL units have to use the same palette. In some games, such as Contra, there's a clear separation between the sprites that use different palettes (from the waist up it's one palette, from the waist down it's another). In other games, the sprites are mixed in more elaborate ways and it isn't so easy to tell where exactly the splits/overlaps are.
I think I'm starting to understand.

These are the characters I've been working on for my Beat 'Em Up. I think I might have already shot myself in the foot with the number of sprites per character. The two characters on the left are the main two players and the guy in red is one of the enemies.
I was watching some footage of TMNT 2 for NES and realized that the maximum number of enemies on the screen at once is three (plus two Turtles). They just spawn super fast when one is defeated. I was hoping that I could do the same, but from what you guys are saying, I might be running into scan line issues almost immediately since I still have fists, weapons, kicks, etc that would need to be loaded.
If my math is correct I could technically have 4 players on the screen at once as it would only be 60 Sprites, but that only leaves 4 for all the other stuff. Plus, as I mentioned the scanline issues.
I think my pallets might be okay (unless I'm mistaken).
-
ImperialWalker
- Posts: 9
- Joined: Thu Mar 20, 2025 10:42 pm
Re: How were sprites like the characters from Double Dragon II done? (Palette)
I am the artist on this one. It is a bucket list thing to create a simple little beat 'em up. I posted my concepts in the post above. I think I'm already in trouble with my designs.tokumaru wrote: Fri Mar 21, 2025 12:14 am If you have an artist doing the art for you, these limitations may be hard to explain if the person is not already familiar with the hardware's limitations. There are many good artists out there that will ask you "how many colors per sprite?", and if you go "well, sometimes 3, sometimes 6, and it depends on the part of the character you're drawing" they might be very confused!
So take your time explaining the technical limitations to them, and provide lots of examples of how existing games combine sprites that use different palettes to form more colorful characters (outline the individual sprites, show which palettes are shared among all characters, etc.) and never, ever let them forget that there can only be 8 sprites per scanline, so they absolutely can't go crazy with the sprite overlap.
-
ImperialWalker
- Posts: 9
- Joined: Thu Mar 20, 2025 10:42 pm
Re: How were sprites like the characters from Double Dragon II done? (Palette)
Thank you. That is a great way of demonstrating it. Very clever of them. I've posted my concepts, but I think I'm already in trouble with my designs.Gilbert wrote: Thu Mar 20, 2025 11:59 pm By cleverly spliting the sprites into regions that use tiles of different palettes, and overlaying tiles of different palettes.
Take this sprite of Billy for example:
dd2palette.png
It's split into the top (head), middle (body) and bottom (feet) regions, with the top and bottom regions using one palette of 3 colours and the middle using another palette.
I think (part of?) the hand uses tiles overlaid on the body.
Note that I haven't really checked the game at the moment, but I just analyse it from a screenshot.
The actual implementation shouldn't be too far off.
Actually the first game uses similar tricks, but the developers had better experience when making the sequel to have sprites with shading that look more colourful.
(ninjaed by tokumaru)
-
tokumaru
- Posts: 12673
- Joined: Sat Feb 12, 2005 9:43 pm
- Location: Rio de Janeiro - Brazil
Re: How were sprites like the characters from Double Dragon II done? (Palette)
Well, 64 sprites per frame and 8 per scanline are just the hardware limits, actual sprite usage can be higher than that (as long as your code is prepared to deal with it) if you're not bothered by the flicker.
If you really plan on having so many sprites on screen at once that you're consistently hitting the 64-sprite limit, maybe you should consider using 8x16 sprites instead of 8x8. They are a little more wasteful (more blank space) and not as easy to combine with different palettes, but your sprite coverage nearly doubles.
Many of the later NES games used 8x16 sprites, since they were competing against 16-bit games and were trying to display bigger characters in larger quantities.
If you really plan on having so many sprites on screen at once that you're consistently hitting the 64-sprite limit, maybe you should consider using 8x16 sprites instead of 8x8. They are a little more wasteful (more blank space) and not as easy to combine with different palettes, but your sprite coverage nearly doubles.
Many of the later NES games used 8x16 sprites, since they were competing against 16-bit games and were trying to display bigger characters in larger quantities.
-
tokumaru
- Posts: 12673
- Joined: Sat Feb 12, 2005 9:43 pm
- Location: Rio de Janeiro - Brazil
Re: How were sprites like the characters from Double Dragon II done? (Palette)
The one on the left would probably work fine with a main black-blue-tan palette, and just the eyes and teeth overlayed in white. Try to keep that overlay not wider than 8 pixels in order to keep the sprite count down.
The one in the middle you typically wouldn't see on the NES, because the brown is so dark that it would probably blend too much with the black. In NES games where sprites had outlines, it was common practice to do the outline with the darkest color available, not necessarily with black. In this case, it'd probably make sense to do the outline in brown, so the main palette is brown-blue-tan, and again a white overlay for eyes and teeth.
The one on the right would probably work well with black and blue (probably using player 1's palette) from the waist down, and a black-red-tan palette from the waist up. A blue overlay could be used for the shirt that you can see under the jacket, but you could make things simpler and reduce flicker if you just gave him a black shirt.
-
Anna_TeamRocket
- Posts: 62
- Joined: Sat Jan 04, 2025 3:21 am
Re: How were sprites like the characters from Double Dragon II done? (Palette)
I think you could also use the two-tiles tall sprites, not exactly sure how would it work out, but I assume it would definitely save up on the used space for sprite memory allocation. I think it's also how it works in the game Lode Runner, considering the fact how unoptimal the tile design looks there, would make a lot more sense if it used the double sprite size. Also, I think 3 by 5 tile sprites is quite a pretty solution, but usually when it comes to the NES, 2 by 4 is sufficient.ImperialWalker wrote: Fri Mar 21, 2025 7:59 pm These are the characters I've been working on for my Beat 'Em Up. I think I might have already shot myself in the foot with the number of sprites per character.
Code: Select all
PPUCTRL $2000 Write
%00000000
||||||++ nametable map sector
|||||+-- VRAM increment per r/w PPUDATA
||||+--- sprite pattern table 0:0000 1:1000
|||+---- background pattern table
||+----- sprite size 0:8x8 1:8x16
|+------ PPU master/slave select: always 0
+------- when Vblank occurs, call NMIYou do not have the required permissions to view the files attached to this post.