show_question

Displays a pop-up question.

Syntax:

show_question(str);


Argument Description
str The string to show in the pop-up question.


Returns: Boolean


Description

This function creates a pop-up message box with two buttons for "Yes" and "No". It returns true or false depending on which one of the two buttons the user presses.

NOTE: THIS FUNCTION IS FOR DEBUG USE ONLY.


Example:

if score > 500
   {
   if show_question("Continue to next room?")
      {
      room_goto(rm_Level2);
      }
   else game_end();
   }

The above code will check the score and if it is over 500, it will ask the user if they wish to continue or not and if the "yes" button is clicked it will go to another room, but if the "no" button is selected it will end the game.


Back: Debugging
Next: show_debug_message
© Copyright YoYo Games Ltd. 2018 All Rights Reserved