mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 09:56:06 +00:00
null and void typehints
This commit is contained in:
@ -62,7 +62,7 @@ class ChestInventory extends ContainerInventory{
|
||||
return $this->holder;
|
||||
}
|
||||
|
||||
public function onOpen(Player $who){
|
||||
public function onOpen(Player $who) : void{
|
||||
parent::onOpen($who);
|
||||
|
||||
if(count($this->getViewers()) === 1 and ($level = $this->getHolder()->getLevel()) instanceof Level){
|
||||
@ -71,7 +71,7 @@ class ChestInventory extends ContainerInventory{
|
||||
}
|
||||
}
|
||||
|
||||
public function onClose(Player $who){
|
||||
public function onClose(Player $who) : void{
|
||||
if(count($this->getViewers()) === 1 and ($level = $this->getHolder()->getLevel()) instanceof Level){
|
||||
$this->broadcastBlockEventPacket(1, 0); //chest close
|
||||
$level->broadcastLevelSoundEvent($this->getHolder()->add(0.5, 0.5, 0.5), LevelSoundEventPacket::SOUND_CHEST_CLOSED);
|
||||
|
Reference in New Issue
Block a user