Gui Button Highlighting.
by Rodney Rindels - Torqued · in Torque Game Builder · 05/09/2006 (10:30 pm) · 3 replies
Ok I am at a loss on this one.
All of my art resources are in my project/data/images directory.
I followed the instructions I found on TDN, all of these images exist, i tried naming button_h.png also with no change as one example I found posted suggested.
When you move the mouse over the button, tons of the following start spitting out...
so my question is , do you have to load these somehow different than pulling up the gui editor, picking a button and setting the name of the bitmap? the normal bitmap shows up fine. and the command actually fires.
This happened on version 2 and still on version 3, maybe I just have something wrong?
Thanks in Advance,
Rodney
All of my art resources are in my project/data/images directory.
I followed the instructions I found on TDN, all of these images exist, i tried naming button_h.png also with no change as one example I found posted suggested.
When you move the mouse over the button, tons of the following start spitting out...
Set::getObject index out of range. ResourceObject::construct: NULL resource create function for 'button.png_h'. ResourceObject::construct: NULL resource create function for 'button.png_h'. ResourceObject::construct: NULL resource create function for 'button.png_h'. ResourceObject::construct: NULL resource create function for 'button.png_h'.
so my question is , do you have to load these somehow different than pulling up the gui editor, picking a button and setting the name of the bitmap? the normal bitmap shows up fine. and the command actually fires.
This happened on version 2 and still on version 3, maybe I just have something wrong?
Thanks in Advance,
Rodney
#2
I wish they just had seperate fields for those, I dont like assuming what to name things.
Thanks chris, works now.
Rod
05/09/2006 (10:43 pm)
Derf. makes sense. I figured they were parsing off the name or something. I wish they just had seperate fields for those, I dont like assuming what to name things.
Thanks chris, works now.
Rod
#3
Hehe... The reason I could actually answer this question was because I have a notepad next to my desk with Normal, Highlited, Depressed and Inactive written on it (capitalized like that) because I keep on thinking D is Down and need to remind myself all the time!
05/09/2006 (10:54 pm)
Quote:I wish they just had seperate fields for those, I dont like assuming what to name things.
Hehe... The reason I could actually answer this question was because I have a notepad next to my desk with Normal, Highlited, Depressed and Inactive written on it (capitalized like that) because I keep on thinking D is Down and need to remind myself all the time!
Torque Owner Chris Schirlinger
button_n.png
button_h.png
button_d.png
button_i.png
For Normal, Highlited, Depressed and Inactive
(I guess you could leave the inactive one out if you weren't gonna disable it)
Then, when you point your GUI's button image to the button, you point it to... "button"
No _h, no .png, nothing! Just "button", leave the rest of the text out
The software, when it wants a HIGHLITED, will add the "_h" to the end and tries to find the image file, or add "_n" when it wants the normal image and so on