Bug / Crash ObiParticleRenderer is never lit in build. - Printable Version +- Obi Official Forum (https://obi.virtualmethodstudio.com/forum) +-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html) +--- Forum: Obi Fluid (https://obi.virtualmethodstudio.com/forum/forum-3.html) +--- Thread: Bug / Crash ObiParticleRenderer is never lit in build. (/thread-3045.html) |
ObiParticleRenderer is never lit in build. - Nathan_TRC - 05-08-2021 I am using URP. I am rendering the particles using ObiParticleRenderer with the Obi/URP/Particles shader. I got it looking exactly how I want in Editor, but for some reason, when building, the particles are always unlit, Which turns my nice white particles into an ugly grey. Any ideas what could be causing this? RE: ObiParticleRenderer is never lit in build. - Nathan_TRC - 05-08-2021 FIX: I found a fix for this problem, and it is a weird one, so I am keeping this up in case someone else runs into this problem. I had a camera that was active at scene start, and disabled in another scripts start method. I noticed that when the camera was turned on, the problem was fixed for the entire time that build was up (If i changed scenes and came back, it was still fixed). So, the fix was making it so the camera was turned off 1 frame after the scene started, instead of on Start. Not sure why this error happens, and why it doesnt happen in editor. RE: ObiParticleRenderer is never lit in build. - josemendez - 06-08-2021 (05-08-2021, 10:48 PM)Nathan_TRC Wrote: FIX: I found a fix for this problem, and it is a weird one, so I am keeping this up in case someone else runs into this problem. Sounds like a bug in URP to me. Particles are rendered using a pretty simple shader that makes use of Unity's built-in shader macros for lighting. There's no reason turning on/off a camera should affect lighting or shading in any way. Still, will try to reproduce it and raise a bug report with Unity if needed. thanks! |