mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-21 04:54:41 +00:00
Fixes bug #3071
This commit is contained in:
parent
51062940c5
commit
8a41512194
@ -617,7 +617,6 @@ abstract class Entity extends Location implements Metadatable{
|
||||
|
||||
if($amount <= 0){
|
||||
if($this->isAlive()){
|
||||
$this->health = 0;
|
||||
$this->kill();
|
||||
}
|
||||
}elseif($amount <= $this->getMaxHealth() or $amount < $this->health){
|
||||
@ -1424,7 +1423,7 @@ abstract class Entity extends Location implements Metadatable{
|
||||
}
|
||||
|
||||
public function kill(){
|
||||
$this->setHealth(0);
|
||||
$this->health = 0;
|
||||
$this->scheduleUpdate();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user