Should be incredibly simple, but I just can’t get it to work whatever I try. Very straight forward in other modes, but GLSL just won’t work as expected.
I can set a colour at startup using the RGB to Intensity function but despite adding in F-curves for the colours this won’t animate in the game.
Object Color just defaults to black at startup whatever colour is selected, so that’s no use at all. This can be changed via python so would have been very useful if it actually worked.
Solutions and / or example files would be appreciated.
Thanks for the responses HG1. Unfortunately these are all for normal objects, which I have no issues with.
The actual font objects behave completely differently for some reason, just turning black whatever object colour they’re set to. I’ve tried Object Colour curves and the obj.color() python function with the same results.
If you’re using the texture method with the texface option set to ‘text’ then you need to use the object color option like others have said.
However, Moguri has started to implement various animation enhancements for the BGE as part of his GSoC project, and one of them is allowing the use of material F-Curves (which will bring a lot more freedom for those needing their materials animated)
Does anyone have a working example file of this I can cross reference settings with? I have material diffuse set to white and object colour set to white. In the display port the ‘@’ symbol mirrors this, changing colour as it should. If you set the object colour to blue it will appear blue. I can also see the animation results this way by moving through the frames and observing the colour changes.
As soon as you start the game engine though, it just goes black (actually it may be going invisible, but the background is black so appears this way).
That doesn’t seem to work correctly at my end either, it just disappears on startup. Perhaps an issue with hardware compatibility? Though I’m running a GTX460, which as far as I’m aware fully supports GLSL (certainly runs all the example shaders I’ve tried).
I seem to have got it working though by completely removing the texture and material from the text objects, then the object colour correctly applies. Looks like there’s a conflict between settings going on somewhere, but I’ve spent enough time trying to fix this without trying to narrow it down further. Can now press on in other areas.