mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 11:39:43 +00:00
fix of small error in drop
This commit is contained in:
parent
3892d697f8
commit
6ee84717f8
2 changed files with 4 additions and 5 deletions
|
|
@ -287,7 +287,7 @@ class Entity extends Position
|
|||
public function getDrops()
|
||||
{
|
||||
if($this->class === ENTITY_PLAYER and $this->player instanceof Player and ($this->player->gamemode & 0x01) === 0){
|
||||
$inv = array();
|
||||
$inv = [];
|
||||
for($i = 0; $i < PLAYER_SURVIVAL_SLOTS; ++ $i){
|
||||
$slot = $this->player->getSlot($i);
|
||||
$this->player->setSlot($i, BlockAPI::getItem(AIR, 0, 0));
|
||||
|
|
@ -312,7 +312,7 @@ class Entity extends Position
|
|||
}
|
||||
return $inv;
|
||||
}
|
||||
return array();
|
||||
return [];
|
||||
}
|
||||
|
||||
private function spawnDrops()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue