I’ve been using Unity3D for only few weeks, and so far I’m playing with basic game objects and some C# scripting.
In my project I have a 3DText and a plane being used as a back wall. I want to be able to see the text shadow on the back wall.
My first idea was to try to project some kind of lighting over the text - like the point light. Although the light “hits” the back wall, it seems the 3dtext is ignored by the light, as if it wasn’t there.
You’d need to use a shader that supports shadows. This is a bit hard with transparency, since only the transparent/cutout shaders work with shadows, not the standard transparent shaders. None of the built-in cutout shaders will quite work properly with 3DText, since you’d get a complaint about the shader wanting normals (3DText meshes do not have normals), and you wouldn’t be able to change the text color, so it would only be black, plus text looks a bit funky using a cutout shader (also no anti-aliasing):
If that’s not good enough, you can either write a custom shader that supports 3DText meshes with shadows, or use some other technique, such as actual meshes in the shape of text, which will work with standard non-transparent shaders and won’t have any of the above problems. (Plug!)
That was a very through explanation, thanks. It seems to be the solution is not that simple, at least for me. I need the ability to use colors, and even having texts with different colors for each character.