From: Holger Schemel Date: Sat, 2 Dec 2023 11:58:31 +0000 (+0100) Subject: moved function call for getting door state to variable declaration X-Git-Tag: 4.3.8.0~24 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=8ba5534d1599a87045c09bee2aa663f0f518d7cc;p=rocksndiamonds.git moved function call for getting door state to variable declaration --- diff --git a/src/tools.c b/src/tools.c index 8ec91e5f..e12d441b 100644 --- a/src/tools.c +++ b/src/tools.c @@ -4813,7 +4813,7 @@ static int RequestHandleEvents(unsigned int req_state, int draw_buffer_game) static boolean RequestDoor(char *text, unsigned int req_state) { int draw_buffer_last = GetDrawtoField(); - unsigned int old_door_state; + unsigned int old_door_state = GetDoorState(); int max_request_line_len = MAX_REQUEST_LINE_FONT1_LEN; int font_nr = FONT_TEXT_2; char *text_ptr; @@ -4842,8 +4842,6 @@ static boolean RequestDoor(char *text, unsigned int req_state) req_state & REQUEST_WAIT_FOR_INPUT) SendToServer_PausePlaying(); - old_door_state = GetDoorState(); - // simulate releasing mouse button over last gadget, if still pressed if (button_status) HandleGadgets(-1, -1, 0);