gms_show_replace randomly crashes

Posted by Jenraux
Hi, when I try to add a custom login to my game, it boots correctly usually 2 or 3 times, but after that, every boot results in a crash.

I don't think it's the .scn file that's causing the problem, as it loads the customized login window fine on initial boot and 2nd boot usually, and then randomly stops working on subsequent boots until I remove the code, test the game, and then add the code back in.

Here's the error I get on 3rd and subsequent boots of the game:


___________________________________________
###########################################################
FATAL ERROR in
action number 1
of Create Event
for object obj_gms:

Unexpected token '['
at gml_Script_wle_parse_layout (line 303) - show_error("Unexpected token '['", global.__xwindow_error_type);
###########################################################
--------------------------------------------------------------------------------------------
stack frame is
gml_Script_wle_parse_layout (line 303)
called from - gml_Script_wle_load (line 35) - _ret = wle_parse_layout(str_layout, data_p, data_c, -1);
called from - gml_Script_gms_show_replace (line 6) - global.__xls_window = wle_load(argument1);
called from - gml_Object_obj_gms_CreateEvent_1 (line 15) - gms_show_replace(wt_login,'<constants>

Any help appreciated.

Replies (4)

Last message on 3 Dec 2018

Jenraux (Topicstarter) on 27 Nov 2018, 22:19:57
Completely restarting.

I can click green test, login, works, close game, click green test, login, works, close game, click green test, crashes when trying to do the gms_show_replace this time.

Not sure what changes, between each time, as I haven't edited the gmx at all.
Size43 (Administrator) on 2 Dec 2018, 13:53:12
Would you mind mailing your project to me at gamemakerserver@outlook.com so I can take a look?
Jenraux (Topicstarter) on 3 Dec 2018, 16:58:22
Hello,

I've emailed the project to you with some additional info.
Size43 (Administrator) on 27 Nov 2018, 15:47:41
What do you mean by 'boot'? Are you completely closing and restarting the game, or just using game_restart()?