mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-11 05:55:33 +00:00
Possible fix for entities not closing correctly
This commit is contained in:
parent
8f7dfe0b71
commit
580ade9092
@ -1175,7 +1175,7 @@ abstract class Entity extends Location implements Metadatable{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public function close(){
|
public function close(){
|
||||||
if($this->closed === false){
|
if(!$this->closed){
|
||||||
$this->server->getPluginManager()->callEvent(new EntityDespawnEvent($this));
|
$this->server->getPluginManager()->callEvent(new EntityDespawnEvent($this));
|
||||||
$this->closed = true;
|
$this->closed = true;
|
||||||
unset($this->level->updateEntities[$this->id]);
|
unset($this->level->updateEntities[$this->id]);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user