mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-10-17 04:06:54 +00:00
More anti-leak measures for double chest inventory issues
This commit is contained in:
@@ -63,6 +63,10 @@ class Chest extends Spawnable implements InventoryHolder, Container, Nameable{
|
|||||||
foreach($this->getInventory()->getViewers() as $player){
|
foreach($this->getInventory()->getViewers() as $player){
|
||||||
$player->removeWindow($this->getRealInventory());
|
$player->removeWindow($this->getRealInventory());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$this->inventory = null;
|
||||||
|
$this->doubleInventory = null;
|
||||||
|
|
||||||
parent::close();
|
parent::close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -92,6 +92,9 @@ class Furnace extends Spawnable implements InventoryHolder, Container, Nameable{
|
|||||||
foreach($this->getInventory()->getViewers() as $player){
|
foreach($this->getInventory()->getViewers() as $player){
|
||||||
$player->removeWindow($this->getInventory());
|
$player->removeWindow($this->getInventory());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$this->inventory = null;
|
||||||
|
|
||||||
parent::close();
|
parent::close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user