Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
(1 edit)

Hi! I have a question. I'm rendering an object using chunks. It's drawn in sections. The initial shadow works fine, but when I delete a chunk, the shadow remains intact. How can I re-render the shadow? Any advice?

And another question, how can I prevent light from passing through the walls?


// Shadow

_shadow = new Crystal_ShadowSprite(id, sprite_index, image_index, CRYSTAL_SHADOW.DYNAMIC);

_shadow.shadowLength = 0.1; 

_shadow.fixedBase = false; 

_shadow.followLightAngle = false; 

_shadow.Apply();

Hello!

I think in this case you could use shadow.Destroy() when deleting the chunk, and shadow.Apply() to re-add the shadow to the renderer.

Regarding preventing light from passing through walls, see: Light leaks through the wall (even with shadows)

(+1)

Thx!