Game Development Community

Gui Bitmap Button Control Bug

by Gellyware · in Torque Game Builder · 01/21/2008 (7:12 pm) · 3 replies

It seems in TGB v1.6 that there is a bug with the Gui Bitmap Button Control.

I'm getting the following errors for my bitmap button:

Could not locate texture: game/data/images/dialog_button.png_h
Could not locate texture: game/data/images/dialog_button.png_d
Could not locate texture: game/data/images/dialog_button.png_i

it seems that TGB is appending the _h, _d, and _i behind the file extension instead of the file name.


Any suggestions as to how to fix this?

#1
01/22/2008 (1:43 am)
I think you need to tell TGB the file name without the extension.
#2
01/22/2008 (3:51 am)
Yes, in the GUI file it needs to look like this for example:
new GuiBitmapButtonCtrl() {
      canSaveDynamicFields = "0";
      Profile = "AudibleButtonProfile";
      HorizSizing = "right";
      VertSizing = "bottom";
      Position = "382 336";
      Extent = "260 54";
      MinExtent = "8 2";
      canSave = "1";
      Visible = "1";
      Command = "pause(true);";
      hovertime = "1000";
      groupNum = "-1";
      buttonType = "PushButton";
      bitmap = "./btncontinue";
   };

bitmap="./btncontinue.png" will give errors.

Greg
#3
01/22/2008 (4:08 pm)
Interesting!

Thanks... that worked.

TGB automatically added the extension when I selected the .png file from within the GUI builder. Guess TGB should automatically remove the extension instead of having to go back into the guiprofile to change that.

Thanks guys.