I'm not using any special characters. Everything has been typed in using a text editor.
However, I *think* I've found the problem. I'm not sure because it's so hard to get it to show up.
Code: ags
There's a missing "else" clause at the end which means that if the mouse is not over a button, it's not clear what it'll set gStatusLineLabel to.
If that's not it, then I have no idea.
However, I *think* I've found the problem. I'm not sure because it's so hard to get it to show up.
// Top menu bar tooltips
if (gMenubar.Visible)
{
GUIControl* myButton = GUIControl.GetAtScreenXY(x, y);
string labelText;
if (myButton == gMenuExit)
{
StrCopy(labelText, "Exit game");
}
else if (myButton == gMenuHelp)
{
StrCopy(labelText, "Help");
}
else if (myButton == gMenuInv)
{
StrCopy(labelText, "Inventory");
}
else if (myButton == gMenuLoad)
{
StrCopy(labelText, "Load game");
}
else if (myButton == gMenuNew)
{
StrCopy(labelText, "Restart game");
}
else if (myButton == gMenuOptions)
{
StrCopy(labelText, "Options");
}
else if (myButton == gMenuPda)
{
StrCopy(labelText, "PDA");
}
else if (myButton == gMenuSave)
{
StrCopy(labelText, "Save game");
}
gStatusLineLabel.SetText(labelText);
}
There's a missing "else" clause at the end which means that if the mouse is not over a button, it's not clear what it'll set gStatusLineLabel to.
If that's not it, then I have no idea.