Page 1 of 1

'torch' effect ?

Posted: Sat Oct 21, 2017 11:17 pm
by KanedaFr
Here comes another "how would you do that ?" post ;)

I'd like to add a torch effect on my game, when you're on a cave.
By torch effect, i mean this circle around when everything (tile/sprite) not INSIDE it won't be visible.
Something near
Image
without the blur effect of course

I assume i add to use a plan with a hole on it, and handle priorities BUT i wonder if it could also be done by sprites, using shadow/hightlight ?

Re: 'torch' effect ?

Posted: Sun Oct 22, 2017 12:48 am
by Moon-Watcher
Mickey Mania do it without any effect and works okay for me
https://youtu.be/iL6xnm5pJIM?t=1093

Re: 'torch' effect ?

Posted: Sun Oct 22, 2017 1:11 am
by Sik
That's the SNES version though (SNES has it easy)... here's the Mega Drive counterpart
https://youtu.be/6znkZOa5EBE?t=817

The question is whether you want to waste a plane or not. Wasting a whole plane on it makes things much easier, but it means no parallax (or minimal one, if aided through sprites or software rendering the parallax). That said, using sprites for a cutout is probably even less flexible because of sprite bandwidth (in fact, at the top and bottom borders you'll actually be unable to render sprites).

Another alternative (which I recall seeing in a PC Engine game) is to rewrite the tilemap as you move around to darken tiles that are further away. But that's relatively low resolution and eats up palettes (neither are an issue on the PCE since you can waste palettes and using many of them for blurring helped make up for the low resolution... but this is a MD we're talking about). Alternatively you can use different tiles instead of the same tile with different palettes, at the expense of more memory. Either case this is horribly cumbersome to do.

Re: 'torch' effect ?

Posted: Sun Oct 22, 2017 11:59 am
by Miquel
KanedaFr wrote:
Sat Oct 21, 2017 11:17 pm
i wonder if it could also be done by sprites, using shadow/hightlight ?
As the image you post no. Other sprites will be not obscured or, totally hidden while the scenario remains visible.

But you can do it with normal sprites.

Re: 'torch' effect ?

Posted: Sun Oct 22, 2017 2:51 pm
by Manveru
It is not exactly the same, but you can keep the two planes using h/s, like in The lost World https://youtu.be/VPzKP8zubs0?t=1h53m36s. The only thing is i don't know how they do it :lol:

Re: 'torch' effect ?

Posted: Sun Oct 22, 2017 4:12 pm
by Miquel
Also notice you can do it all, including the "blur effect", with palettes. In fact, palettes are the most powerful technique there is, most of the timer overlooked because they are easy.