Game Development Community

GUI Help (Show Input)

by Todd · in Torque Game Engine · 10/21/2007 (3:34 am) · 2 replies

Hi Everyone,

I am in need of a little help, here is what I am wanting to do. I am working on a HUD that will show some kind of graphic when a key or mouse button is used to give feed back to the user. But am unsure as to the best way to go about it. I was thinking of a GUI control, kind of like the health bar. But show different colors or a sprite. I am also not sure how to pole the input in order to give real time feedback. Any help would be great. Thanks....

#1
10/22/2007 (6:07 pm)
As far as the gui control you might want to look into guichunkbitmapctrl (I think that's the name) that will allow you to display an image. You can use the command Schedule in script to poll data and update the image. Or you could have an image background and then guitxtctrl to update any text on top of the image background. Hope that makes sense, if not I will try and explain it better.
#2
10/24/2007 (1:33 pm)
Thanks Steve for your help. I will have to look into the Scheduling thing, I don't know much about it but will give it a try. Looking around I see a lot of info on using multiple keys for each event, but as far as using a single key for multiple events, well I just don't see any. lol guess I just have to be different. I don't know I may not be able to do this in torque script and may need to do it in c++. I was looking at GetAsyncKeyStyate () it looks like what I need, but I would much rather use a script. I just think it would be easier to maintain. Again Thanks for the help.