If player is dead, don't spawn it

This commit is contained in:
Phew
2026-03-15 22:30:39 +01:00
parent a11da1b3d8
commit 9bf87677a4

View File

@@ -93,9 +93,14 @@ void Player::Kill(){
}
void Player::Spawn(int pos){
if (_lives <= 0) {
// Serial.printf("Player %d has no life. Not Spawning\n", _id);
captured = true;
} else {
captured = false;
moveto(pos);
}
}
int Player::Lives() const{
return _lives;