- Home /
Unity3d 2D mode lighting?
I have TOP DOWN 2D game.
When i shoot bullet from a 2d sprite barrel, i want to see a light flash on the background sprite at least, nothing fancy.
How would i go about achieving this, I'm really not sure.
I know i can make a point light source in 3D to achieve that effect but in 2D i have no clue.
UPDATE:
I tried creating a diffuse particle sprite material but the effect sucks balls. I have to make the light HUGE to get any effect on the background sprite and even when i do its in big chunks.
I'm trying to create the lighting on small tiny sections like a muzzle flash on a 2D gun barrel. Is there a technique for doing this?
UPDATE 2: Wait isn't lighting calculated from like the vertices of the sprite or something like that? Is there any way to make the background sprite contain more "pieces" so lighting looks more natural on it? thanks. or is there a better way to do this.
Answer by luniac · Jun 29, 2014 at 01:34 AM
OH I GOT IT!!!
SETTING THE LIGHT RENDER IMPORTANCE TO IMPORTANT DID THE TRICK, NOW IT RENDERS BEAUTIFULLY AND SOFTLY ON THE BACKGROUND SPRITE. THIS IS BEAUTIFUL!
and dont forget to set sprite material to custom one: sprite->diffuse
love this engine :)
Your answer
Follow this Question
Related Questions
Unity2D Lighting on a TileMap 0 Answers
Writing a 2D shadow shader for top-down game 0 Answers
Unity 2D lights only lighting hemisphere? 0 Answers
Create Shaded area Unity2D 1 Answer
Tile mesh is mysteriously darkened as compared to other GameObjects 1 Answer