projects
/
supertux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2b45f15
)
[Issue 3] Fix for jittering when there are slopes that end in a wall
author
Tobias Markus
<tobbi@mozilla-uk.org>
Thu, 30 Jan 2014 13:32:13 +0000
(14:32 +0100)
committer
Tobias Markus
<tobbi@mozilla-uk.org>
Thu, 30 Jan 2014 13:32:13 +0000
(14:32 +0100)
src/object/player.cpp
patch
|
blob
|
history
diff --git
a/src/object/player.cpp
b/src/object/player.cpp
index
6c193d7
..
a408975
100644
(file)
--- 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) {