mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-16 01:45:36 +02:00
handleCommand_Breath mustn't update breath is player is dead. A dead player doesn't breath.
Add Player::isDead function to check player is dead
This commit is contained in:
@@ -238,6 +238,9 @@ public:
|
||||
inventory.setModified(x);
|
||||
}
|
||||
|
||||
// Use a function, if isDead can be defined by other conditions
|
||||
bool isDead() { return hp == 0; }
|
||||
|
||||
bool touching_ground;
|
||||
// This oscillates so that the player jumps a bit above the surface
|
||||
bool in_liquid;
|
||||
|
Reference in New Issue
Block a user