mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-15 17:35:37 +02:00
Reset the old HP method on PlayerSAO::setHP
This commit is contained in:
@@ -1072,6 +1072,10 @@ void PlayerSAO::setHP(s16 hp)
|
||||
else if (hp > PLAYER_MAX_HP)
|
||||
hp = PLAYER_MAX_HP;
|
||||
|
||||
if(hp < oldhp && g_settings->getBool("enable_damage") == false) {
|
||||
return;
|
||||
}
|
||||
|
||||
m_player->hp = hp;
|
||||
|
||||
if (oldhp > hp)
|
||||
|
Reference in New Issue
Block a user