From 4852f3c3c32c6019b11e4832a24ce974dc551515 Mon Sep 17 00:00:00 2001 From: Marek Moeckel Date: Sat, 18 Sep 2004 16:39:41 +0000 Subject: [PATCH] fixed "flapping key not responding"-problem SVN-Revision: 1947 --- src/player.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/player.cpp b/src/player.cpp index 8e4290634..a5ff92ae2 100644 --- a/src/player.cpp +++ b/src/player.cpp @@ -563,7 +563,10 @@ Player::handle_vertical_input() // Flapping if (input.up == DOWN && can_flap) { - if (!flapping_timer.started()) {flapping_timer.start(TUX_FLAPPING_TIME);} + if (!flapping_timer.started()) + { + flapping_timer.start(TUX_FLAPPING_TIME); + } if (!flapping_timer.check()) { can_flap = false; @@ -651,6 +654,7 @@ Player::handle_vertical_input() jumping = false; flapping = false; falling_from_flap = false; + if (flapping_timer.started()) {flapping_timer.stop();} } input.old_up = input.up; -- 2.11.0