projects
/
supertux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6f34bbb
)
No more segfaults when trying to spawn bullets of unknown type
author
Christoph Sommer
<mail@christoph-sommer.de>
Fri, 27 Jun 2008 15:45:33 +0000
(15:45 +0000)
committer
Christoph Sommer
<mail@christoph-sommer.de>
Fri, 27 Jun 2008 15:45:33 +0000
(15:45 +0000)
SVN-Revision: 5635
src/object/bullet.cpp
patch
|
blob
|
history
diff --git
a/src/object/bullet.cpp
b/src/object/bullet.cpp
index
c761735
..
30e6dfa
100644
(file)
--- a/
src/object/bullet.cpp
+++ b/
src/object/bullet.cpp
@@
-44,6
+44,10
@@
Bullet::Bullet(const Vector& pos, float xm, int dir, BonusType type)
} else if(type == ICE_BONUS) {
life_count = 10;
sprite.reset(sprite_manager->create("images/objects/bullets/icebullet.sprite"));
+ } else {
+ log_warning << "Bullet::Bullet called with unknown BonusType" << std::endl;
+ life_count = 10;
+ sprite.reset(sprite_manager->create("images/objects/bullets/firebullet.sprite"));
}
bbox.set_pos(pos);