I am trying to give a metallic look to the font I am using for the gui panels.
After a long testing, by assigning a metal texture to a newly create material with a Transparent/Specular shader to the font, in the editor scene i get more or less the effect that I would like to obtain (with almost every other test, i get either just a color change or weird effects, or nothing at all) as in the picture.
But then, once I hit play, in the game (tried in editor and in webplayer), the text it’s just plain black. Is there anything i am doing wrong, or any hint to a tutorial on how to manage text materials? I tried to change the font from dynamic to unicode too, but nothing seems to change.
Nothing, spent the morning around it and I coulnd’t find a solution. Also all the tutorial and stuff I found are about the old text management before the 4.6.
If any of you guys has any idea or hint, be welcome to offer it (I hate going fast on complex parts of the game, then all of a sudden stuck for 2 days in something that should have been easy peasy)
My guess is that you have a screen space Overlay GUI.
This screen-space Overlay GUI is not lit by any light, and without any light your Specular shader will not work.
The only reason i looks ok in the editor is because unity is previewing the GUI as A object in the scene (Where is a light).
You can try to use a bitmap font that looks ok.
Maybe there is a way to bring the Transparent/Specular to work with a screen-space - Camera GUI.
Hi! That was indeed the problem, I absolutely didn’t think on it, me dumb! Thanks man!
A side question now, I managed to create a fnt+png bitmap font with shoebox, is there a way to get to use it in the UI font? I can’t seem to find any (i found somewhere mentioned that it can’t be used, and somewhere else that it can be used)
I indeed played around with Shoebox for a couple of days trying to achieve the font. At a certain point it seemed to have worked, i produced png and fnt file (in xml), got it into unity, used a script ( taken from Unity 4.6 Bitmap font? - Unity Engine - Unity Discussions ) but the result was awful.
Somehow the font got into unity, but then when i tried to use it, I only got huge letters completely out of any sorting, looking all black or all white, and absolutely unreadable. In shoebox apparently the recognition of the letter looked ok.