From: Tobias Markus Date: Thu, 30 Jan 2014 13:32:13 +0000 (+0100) Subject: [Issue 3] Fix for jittering when there are slopes that end in a wall X-Git-Url: https://git.octo.it/?p=supertux.git;a=commitdiff_plain;h=de8c2e6fde4e326e3833e38ba71c87620fc51b28 [Issue 3] Fix for jittering when there are slopes that end in a wall --- diff --git a/src/object/player.cpp b/src/object/player.cpp index 6c193d705..a40897536 100644 --- a/src/object/player.cpp +++ b/src/object/player.cpp @@ -1105,8 +1105,10 @@ Player::draw(DrawingContext& context) else if ((wants_buttjump || does_buttjump) && is_big()) { sprite->set_action(sa_prefix+"-buttjump"+sa_postfix); } - else if (!on_ground()) { - sprite->set_action(sa_prefix+"-jump"+sa_postfix); + else if (!on_ground() || fall_mode != ON_GROUND) { + if(physic.get_velocity_x() != 0 || fall_mode != ON_GROUND) { + sprite->set_action(sa_prefix+"-jump"+sa_postfix); + } } else { if (fabsf(physic.get_velocity_x()) < 1.0f) {