From: Holger Schemel Date: Fri, 11 May 2018 10:32:05 +0000 (+0200) Subject: fixed bug with not updating screen during request door post delay X-Git-Tag: 4.1.1.0~162 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=f56d8f7d479ffe32afaa258a86425d7a4e166751;p=rocksndiamonds.git fixed bug with not updating screen during request door post delay --- diff --git a/src/tools.c b/src/tools.c index 903818a4..76b40a29 100644 --- a/src/tools.c +++ b/src/tools.c @@ -5150,11 +5150,14 @@ unsigned int MoveDoor(unsigned int door_state) { /* wait for specified door action post delay */ if (door_state & DOOR_ACTION_1 && door_state & DOOR_ACTION_2) - Delay(MAX(door_1.post_delay, door_2.post_delay)); + door_delay_value = MAX(door_1.post_delay, door_2.post_delay); else if (door_state & DOOR_ACTION_1) - Delay(door_1.post_delay); + door_delay_value = door_1.post_delay; else if (door_state & DOOR_ACTION_2) - Delay(door_2.post_delay); + door_delay_value = door_2.post_delay; + + while (!DelayReached(&door_delay, door_delay_value)) + BackToFront(); } }