Game Development Community

startupGui.cs, second splash image not placed as scripted - NOT A BUG

by Richard Ranft · in Torque 3D Professional · 01/16/2011 (6:18 pm) · 2 replies

Torque 3D 1.1 b3

// A list of the splash screens and logos
   // to cycle through. Note that they have to
   // be in consecutive numerical order
   StartupGui.bitmap0      = "art/gui/background0.png";
   StartupGui.logo0        = "art/gui/T3Dsplash.png";
   StartupGui.logoPos0     = "460 220";
   StartupGui.logoExtent0  = "413 273";
   
   StartupGui.bitmap1      = "art/gui/background.png";
   StartupGui.logo1        = "art/gui/Warbots-splash.png";
   //StartupGui.logoPos1     = "460 220";
   //StartupGui.logoExtent1  = "413 273";

if I uncomment the StartupGui.logoPos1 and .logoExtent1 values StartupGui.logo1 is displayed approximately 100 pixels up and 20 pixels to the left of the location of StartupGui.logo0. Used as shown the second image appears in the correct location.

About the author

I was a soldier, then a computer technician, an electrician, a technical writer, game programmer, and now software test/tools developer. I've been a hobbyist programmer since the age of 13.


#1
01/17/2011 (9:08 pm)
Hey Richard, looking at the code I don't see why it would do that unless the warbots-splash is a different size than the T3Dsplash image. The images are being displayed in a GuiBitmapButtonCtrl that has HorizSizing and VertSizing set to center which may be cause the shift. If you want an easier way to handle splash screens try guiSplashMgrCtrl.
#2
01/18/2011 (12:31 am)
Naw, made sure that they were the same size to avoid any weirdness.

Then, I changed the logo0 image for one that is a different size, made sure the h and v position are set to "center" in startupGui.gui, commented out logoPos0 and it centers automatically, but then logo1 is shown about half its width from the left side unless I specify logoPos1.

Much weirdness. I'm going to look into that resource you posted.