From 3eceff921c9d4ee06fb61797fa82a4f160c75694 Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Thu, 3 Jan 2019 19:59:10 +0100 Subject: [PATCH] racing:: fix a bug with race_start_tick --- shmup.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/shmup.cpp b/shmup.cpp index 63be6bdf..47c80a02 100644 --- a/shmup.cpp +++ b/shmup.cpp @@ -2976,6 +2976,16 @@ void turn(int delta) { if(callhandlers(false, hooks_turn, delta)) return; if(!shmup::on) return; + + if(!(cmode & sm::NORMAL)) { + #if CAP_RACING + if(racing::on) { + if(racing::race_start_tick) racing::race_start_tick += delta; + for(int& i: racing::race_finish_tick) if(i) i += delta; + } + #endif + return; + } timetowait = 0;