projects
/
supertux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
2d883ab
)
Fixes dying animation issue where it is stuck at frame 0.
author
Ryan Flegel
<rflegel@gmail.com>
Mon, 16 Jun 2008 04:01:21 +0000
(
04:01
+0000)
committer
Ryan Flegel
<rflegel@gmail.com>
Mon, 16 Jun 2008 04:01:21 +0000
(
04:01
+0000)
SVN-Revision: 5576
src/object/player.cpp
patch
|
blob
|
history
diff --git
a/src/object/player.cpp
b/src/object/player.cpp
index
63770ef
..
085ca7d
100644
(file)
--- a/
src/object/player.cpp
+++ b/
src/object/player.cpp
@@
-943,7
+943,10
@@
Player::draw(DrawingContext& context)
sa_prefix = "small";
/* Set Tux sprite action */
sa_prefix = "small";
/* Set Tux sprite action */
- if (growing) {
+ if(dying) {
+ sprite->set_action("gameover");
+ }
+ else if (growing) {
sprite->set_action_continued((dir == LEFT)?"grow-left":"grow-right");
// while growing, do not change action
// do_duck() will take care of cancelling growing manually
sprite->set_action_continued((dir == LEFT)?"grow-left":"grow-right");
// while growing, do not change action
// do_duck() will take care of cancelling growing manually
@@
-994,10
+997,6
@@
Player::draw(DrawingContext& context)
}
*/
}
*/
- if(dying) {
- sprite->set_action("gameover");
- }
-
/* Draw Tux */
if (safe_timer.started() && size_t(game_time*40)%2)
; // don't draw Tux
/* Draw Tux */
if (safe_timer.started() && size_t(game_time*40)%2)
; // don't draw Tux