From 097c5b101dfc4adf1051cf4295c436bec0cd279d Mon Sep 17 00:00:00 2001 From: Josue Acevedo Date: Thu, 14 Jul 2016 14:00:16 -0500 Subject: [PATCH] Fix open ride error messages Some error messages aren't properly displayed because 'gGameCommandErrorText' is replaced with 'STR_NONE' before it's displayed. This only happens with commands that use multiple commands inside them for do another "job" (or do another check). --- src/game.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/game.c b/src/game.c index 59665fb65c..22fd991a0e 100644 --- a/src/game.c +++ b/src/game.c @@ -455,7 +455,6 @@ int game_do_command_p(int command, int *eax, int *ebx, int *ecx, int *edx, int * } flags = *ebx; - gGameCommandErrorText = STR_NONE; if (gGameCommandNestLevel == 0) { gGameCommandIsNetworked = (flags & GAME_COMMAND_FLAG_NETWORKED) != 0; @@ -570,6 +569,7 @@ int game_do_command_p(int command, int *eax, int *ebx, int *ecx, int *edx, int * if (gGameCommandNestLevel == 0 && (flags & GAME_COMMAND_FLAG_APPLY) && RCT2_GLOBAL(0x0141F568, uint8) == RCT2_GLOBAL(0x013CA740, uint8) && !(flags & GAME_COMMAND_FLAG_ALLOW_DURING_PAUSED) && !(flags & GAME_COMMAND_FLAG_NETWORKED)) window_error_open(gGameCommandErrorTitle, gGameCommandErrorText); + gGameCommandErrorText = STR_NONE; return MONEY32_UNDEFINED; }