mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-05 17:36:12 +00:00
some improvements to the horrendous mess that is the handling of joining and quitting, fixed some crashes, probably caused some other crashes
I can't fix this completely because it's just too much of a fucking mess. NEED to separate network stuff from Player.
This commit is contained in:
@ -1661,7 +1661,10 @@ abstract class Entity extends Location implements Metadatable{
|
||||
if(!$this->closed){
|
||||
$this->server->getPluginManager()->callEvent(new EntityDespawnEvent($this));
|
||||
$this->closed = true;
|
||||
|
||||
$this->despawnFromAll();
|
||||
$this->hasSpawned = [];
|
||||
|
||||
if($this->chunk !== null){
|
||||
$this->chunk->removeEntity($this);
|
||||
$this->chunk = null;
|
||||
|
Reference in New Issue
Block a user