'Ask first' on Restart Game

Started by AndersM, Sat 23/12/2006 19:49:57

Previous topic - Next topic

AndersM

Hi there. I want to have an 'Ask First' popup when I press the restart game button.
The script so far looks like this:

if (IsKeyPressed(361) == 1) RestartGame();

I want it to be somelike the quit game option;

Ã,  if (IsKeyPressed(27) == 1) QuitGame(1);

but putting an 1 in the RestartGame () only returnas a 'wrong number of parameters'. I can't find the script part that controlls the 'ask first' for the QuitGame, so I can't see how it's constructed and therefore not copy it to the Restartgame feature..Ã,  Help?

Masse


Rui 'Trovatore' Pires

Well, that'd probably be because RestartGame doesn't support that kind of "ask first" - therefore, it's not on the manual because it doesn't exist. Which makes sense. You'll have to make a custom Yes/No GUI to call up whenever key361 is pressed, or use SSH's Yes/No module (I think. I may be imagining things).
Reach for the moon. Even if you miss, you'll land among the stars.

Kneel. Now.

Never throw chicken at a Leprechaun.

SSH

12

Rui 'Trovatore' Pires

Whatever your crazy cybernetically-enhanced brain has decided to name it.
Reach for the moon. Even if you miss, you'll land among the stars.

Kneel. Now.

Never throw chicken at a Leprechaun.

SMF spam blocked by CleanTalk