I’ve got a shader that I’m using for debug visualization using the GL system. It’s a pretty straightforward shader called Simple-Line.shader:
Shader "Hidden/Line"
{
SubShader
{
Pass
{
Blend SrcAlpha OneMinusSrcAlpha
ZWrite Off
Cull Off
Fog { Mode Off }
BindChannels
{
Bind "vertex", vertex
Bind "color", color
}
}
}
}
My problem is, when creating builds, Unity is frequently spitting out the following error, which causes the build to fail:
Making a minor tweak to the shader file (like adding a newline and saving) seems to resolve the issue. But why is this a problem in the first place? I’m definitely NOT marking the shader as HideFlags.DontSave in my editor code anywhere. Is there a naming conflict between my asset and some internal Unity asset? Any ideas on how I could fix this once and for all?