show_error

Displays a pop-up message with a custom error string.

Syntax:

GML Code Example

show_error(str, abort);


Argument Description
str The string to show in the pop-up message.
abort Whether to abort (true) or not (false).


Returns: N/A


Description

This function will show a custom string as an error message and give the option to abort the game afterwards if necessary.

NOTE: THIS FUNCTION IS FOR DEBUG USE ONLY.


Example:

GML Code Example

if room != rm_Dungeon
 {
 show_error("Error: Went to wrong area. Aborting game.", true);
 }
 

The above code will check to see if the room that the player is in is "rm_Dungeon" and if not it will show an error message and force the user to abort the game.


Back: Debugging



No Examples Submitted

Does this page need better examples? Be the first to Submit

No Edits Suggested

Is this page unclear or not descriptive enough? Suggest an edit to the page and with enough upvotes your changes will be made.

No Questions Have Been Ask

Do you have a question about this page? Ask it Here