1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-17 10:25:21 +02:00

Don't call on_dieplayer callback two times (#11874)

This commit is contained in:
savilli
2022-01-15 17:44:55 +01:00
committed by GitHub
parent 76e97e85a0
commit 72b14bd994
5 changed files with 41 additions and 60 deletions

View File

@@ -114,9 +114,9 @@ public:
void rightClick(ServerActiveObject *clicker);
void setHP(s32 hp, const PlayerHPChangeReason &reason) override
{
return setHP(hp, reason, true);
return setHP(hp, reason, false);
}
void setHP(s32 hp, const PlayerHPChangeReason &reason, bool send);
void setHP(s32 hp, const PlayerHPChangeReason &reason, bool from_client);
void setHPRaw(u16 hp) { m_hp = hp; }
u16 getBreath() const { return m_breath; }
void setBreath(const u16 breath, bool send = true);