1
0
mirror of https://github.com/pmmp/PocketMine-MP.git synced 2025-05-29 08:37:13 +00:00

Merge pull request from alejandroliu/Kill-entity-bug

Fixes bug 
This commit is contained in:
Shoghi Cervantes 2015-05-28 17:34:38 +02:00
commit ce59703dd0

@ -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();
}