Game Development Community

How to make a guiTextControl Transparent or blend with the back ground

by Shakey · in Torque Game Builder · 01/26/2010 (5:13 pm) · 2 replies

I know I have a lot of questions but I am about to use this as an example in an upcoming project.

As far as the debug information displayed how do you get the guiTextControl to render with transparency. I have tries all types of things. I can get the font to change color but I want the control to be transparent, blend into the background.

www.xtremeware.net/picts/TGBKart.jpg

#1
01/26/2010 (6:10 pm)
You have to create a graphic for it that has semi-transparency from it's alpha channel (using the PNG format). The image should be located in your project's common/gui/images folder as textEdit.png (or just search for textEdit.png). What I would do is make a separate copy of it and then create a separate GuiTextEditProfile (GuiTextEditTransparentProfile maybe?) so that if you want regular text edit boxes, you can use both. Hope that helps.
#2
01/28/2010 (5:41 am)
You should also be able to, in the profile used on the text field, set opaque to false and set its fill color to something like "0 0 0 0".

So....
opaque = false;
fillColor = "0 0 0 0";