Layered sprites and sprites over BG layering

Description of your first forum.
Post Reply
Dirk
Posts: 2
Joined: Fri Mar 09, 2018 5:30 am

Layered sprites and sprites over BG layering

Post by Dirk » Fri Mar 09, 2018 9:05 pm

Hi!

On the reddit sub I found an interesting question and I wondered if this is planned. I'll quote the reddit post by Meshuggah333.
I have a simple question about a relatively complex topic : Will sprites layering and sprites over BG layering be supported in an automated manner?

It's a very cool way to get better gfx, it has been discussed here in detail (somewhat nsfw as the guy is a bit rude in his posts)

While it hardly goes to SNES level, it's still a good technic.
I guess it's not practical to use this technique with each and every sprite, but enhancing the main character would be nice and maybe the end boss/es.
User avatar
FrankenGraphics
Posts: 37
Joined: Wed Mar 07, 2018 11:36 am

Re: Layered sprites and sprites over BG layering

Post by FrankenGraphics » Fri Mar 09, 2018 10:35 pm

You can theoretically layer all 64 sprites on top of each other if you had wanted it, but always remember the PPU can't show more than 8 sprites per scanline. Sometimes you can get away with layering sprites but in most cases (in action oriented games), it tends to become impractical really quick.

When layering sprites over BG, you typically want to avoid doing it in the "active" field of play, that is, anywhere where a lot of sprite-based entities will be on the same y axis a lot. For example a moon in the sky in a platformer or the like is a good use of this technique.

For static screens, it's free for all as long as you respect the basic limitations. Here's an example i did a while ago where sprites are used to mask attribute clashes and add a bit of highlight here and there as well. It using almost every sprite in 8x16 mode, so there's not much wiggle room left. Here, you can see the difference when the sprites are disabled.

To answer the question, i don't think NESmaker needs to support a special case. just place an entity on top of another and you have sprite-on-sprite layering. Or just place an entity somewhere withot movement and you have a static sprite on bg layer. It just needs to be applied very moderately in order to not cause trouble in other ends. NES game design is all about balancing between pitfalls, even with a nifty tool like NESmaker.
www.frankengraphics.com - NES homebrew blog
DChilders84
Posts: 26
Joined: Sat Apr 21, 2018 12:43 am
Location: Colorado, USA
Contact:

Re: Layered sprites and sprites over BG layering

Post by DChilders84 » Mon Apr 30, 2018 12:26 am

Question regarding this topic. Is this how Capcom was able to allow for more than 3 colors in the Megaman sprite?
User avatar
Kasumi
Posts: 93
Joined: Fri Mar 09, 2018 11:13 pm

Re: Layered sprites and sprites over BG layering

Post by Kasumi » Mon Apr 30, 2018 12:49 am

Yes, see the bottom right of this image:
Image
DChilders84
Posts: 26
Joined: Sat Apr 21, 2018 12:43 am
Location: Colorado, USA
Contact:

Re: Layered sprites and sprites over BG layering

Post by DChilders84 » Tue May 01, 2018 1:34 am

Very interesting infographic, Kasumi. Thank you!
User avatar
dale_coop
Posts: 508
Joined: Fri Feb 16, 2018 7:05 am

Re: Layered sprites and sprites over BG layering

Post by dale_coop » Tue May 01, 2018 9:41 pm

Thank you again, Kasumibfor your infographic, a very useful memo.
-----
Sorry about my poor english
All I need: A Damn Fine Cup of Coffee
SuperMar10Brothe
Posts: 33
Joined: Sat Aug 11, 2018 4:43 pm

Re: Layered sprites and sprites over BG layering

Post by SuperMar10Brothe » Sat Aug 11, 2018 4:45 pm

But how exactly do you layer sprites for the player character? how do i do what capcom did with megaman in nesmaker?
User avatar
MistSonata
Posts: 132
Joined: Fri Feb 16, 2018 7:10 am

Re: Layered sprites and sprites over BG layering

Post by MistSonata » Sat Aug 11, 2018 10:29 pm

Well, the problem right now isn't layering itself, you can make two objects and put them in the same place, but it's moving them around at the same time that's tricky. Depending on the layered sprite's position in the character's animation, you'll need to make offset tables and write ASM to use them.

For example, I was able to make it so that in one of my games, a little fireball would be attached to my ship to act as a thruster, and it worked okay but it took a month of work and it took up an object slot that I really could have used. If you're willing to dig into the ASM, you can do a lot of things, though, but until you learn how to do them, I would highly recommend sticking to the 3 color per 8x8 tile limit on sprites.
User avatar
Gregg Richardson
Posts: 10
Joined: Sun May 27, 2018 6:16 pm

Re: Layered sprites and sprites over BG layering

Post by Gregg Richardson » Sun Aug 12, 2018 4:33 pm

I was planing and working on 6 colors for 16x16 tile character, before NES Maker was out. I watched and learning from a video that was out in 8/8/2018, but he didn't show how to do this. I end up scrap my sprites idea and remake into 3 colors 16x24 tile character instead.
Post Reply