From 5e075c3344911176421be3ae08e2bdc432a83b8f Mon Sep 17 00:00:00 2001 From: gregorycu Date: Tue, 3 Feb 2015 01:26:03 +1100 Subject: [PATCH] Fix dying of lava causes repeated death This is a bugfix for issue #81 --- src/environment.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/environment.cpp b/src/environment.cpp index ee4488476..e1f79803b 100644 --- a/src/environment.cpp +++ b/src/environment.cpp @@ -2567,6 +2567,8 @@ void ClientEnvironment::damageLocalPlayer(u8 damage, bool handle_hp) assert(lplayer); if(handle_hp){ + if (lplayer->hp == 0) // Don't damage a dead player + return; if(lplayer->hp > damage) lplayer->hp -= damage; else -- 2.25.1