Game Development Community

OnWake/OnSleep functions not working...

by Orion the Hunter · in Torque Game Builder · 12/07/2012 (8:30 pm) · 0 replies

//--- OBJECT WRITE BEGIN ---
%guiContent = new GuiBitmapCtrl(NowLoadingGui) {
canSaveDynamicFields = "0";
isContainer = "1";
Profile = "GuiDefaultProfile";
HorizSizing = "right";
VertSizing = "bottom";
Position = "0 0";
Extent = "1024 768";
MinExtent = "8 2";
canSave = "1";
Visible = "1";
hovertime = "1000";
bitmap = "~/data/images/nowloading.png";
wrap = "0";
};

function NowLoadingGui::onWake()
{
_newGame();
readFile();
echo("Loading...");
}

function NowLoadingGui::onSleep()
{
echo("Done.");
}
//--- OBJECT WRITE END ---