[SOLVED] Problems restoring the status line after restoring a game.

Started by Sslaxx, Sat 26/03/2011 12:26:02

Previous topic - Next topic

Sslaxx

So, using the basic Sierra template I've got it so that after it restores the game it restores the status bar and icon line.

But. It restores the icon bar, but not the status bar. It doesn't do this in the close_restore_dialogue, it doesn't do this with repeatedly_execute. And I'm at a loss as to why.

I created this custom function to restore the icon bar and status line:

Code: ags
function DoTheStatusLine (bool IsVisible)
{
 // Sets up the status line (and associated icon bar). Makes them visible if true, otherwise not.
 if (IsVisible)
 {
	gStatusline.Visible = true;
	gIconbar.Visible = true;
 } else
 {
	gStatusline.Visible = false;
	gIconbar.Visible = false;
 }
 return;
}


In repeatedly_execute, it gets called like this (rooms 900 and above are used for menus etc):
Code: ags
 if (player.Room <= 899 && (!gIconbar.Visible))
 {
  gIconbar.Visible = true;
 }


http://sslaxx.twu.net/SQ3.7z has the whole project.

[EDIT: Oh duh, I've only just noticed what I had in repeatedly_execute. So I replaced it with gStatusline instead! And that fixed it. Never mind me then, sorry.]
Stuart "Sslaxx" Moore.

SMF spam blocked by CleanTalk