From: Christoph Sommer Date: Thu, 31 Jan 2008 23:21:22 +0000 (+0000) Subject: HurtingPlatform won't kill invincible player X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=03cd52377e1f38345493a9c71bab6acd1b6342de;p=supertux.git HurtingPlatform won't kill invincible player SVN-Revision: 5306 --- diff --git a/src/object/hurting_platform.cpp b/src/object/hurting_platform.cpp index 59cbfdf80..2c0a010c3 100644 --- a/src/object/hurting_platform.cpp +++ b/src/object/hurting_platform.cpp @@ -38,6 +38,9 @@ HurtingPlatform::collision(GameObject& other, const CollisionHit& ) { Player* player = dynamic_cast(&other); if (player) { + if(player->is_invincible()) { + return ABORT_MOVE; + } player->kill(false); } BadGuy* badguy = dynamic_cast(&other);