Question about layering and priorities

Ask anything your want about Megadrive/Genesis programming.

Moderator: BigEvilCorporation

Post Reply
elusive
Very interested
Posts: 57
Joined: Fri Jan 27, 2012 12:03 am

Question about layering and priorities

Post by elusive » Thu Jul 21, 2016 5:41 pm

I think I know the answer to this, but I'll ask anyway:
Is it possible to have a Sprite behind a graphic plane without setting priorities on either the Sprite or bg plane? Basically what I want to do is enable shadow mode without having background elements be the normal colors.

I don't think this is possible without setting priority on the background plane, but maybe there's a trick/workaround to it, aside from altering palette data?

Stef
Very interested
Posts: 3131
Joined: Thu Nov 30, 2006 9:46 pm
Location: France - Sevres
Contact:

Re: Question about layering and priorities

Post by Stef » Fri Jul 22, 2016 7:03 am

No you can't do that, that is a reason why the hilight / shadow mode isn't much used in game. Setting shadow operator on priority is a terrible constraint.
In your specific case, what you can do is to have your sprite in low priority while plane is high (so your sprite is in shadow) then use a second sprite in low priority which overlap the first one with the highlight operator (color index = $3E) so it will bring your background sprite back to normal color.

elusive
Very interested
Posts: 57
Joined: Fri Jan 27, 2012 12:03 am

Re: Question about layering and priorities

Post by elusive » Fri Jul 22, 2016 10:19 am

That's what I thought, thanks Stef :) I'll just have everything drop a few shades down via palette shifting. It looks fine this way, but was hoping there was an alternate method.

Post Reply