I have a shader that I used in Unity 2.x that utilizes transparency and has a depth-only pass that it renders first, so it won't render the faces behind the faces in front. I am now trying to upgrade this to a Unity3 surface shader but surface shaders don't seem to support render passes and as such I cannot make a depth-only pass.
How would I go about producing the same thing with a surface shader?
The problem there is unity tells me: "SubShader commented out; uses Unity 2.x per-pixel lighting. You should rewrite shader into a Surface Shader." Is there somewhere I can check up on how Unity wants me to implement said vertex/fragment shader, since it obviously doesn't like the old way?
– anon62078424Actually, I was not quite correct in my reply. Surface shaders do in fact support transparency (they will just always use forward rendering). But they still won't allow multiple passes. But you can still use normal vertex lighting in passes. Look at the "Alpha-VertexLit.shader" in our builtin shaders for an example.
– jonas-echterhoff