mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-22 00:33:59 +00:00
Spawnable: change visibility of addAdditionalSpawnData()
This commit is contained in:
parent
4c1d29cdf7
commit
fe21f0e916
@ -118,7 +118,7 @@ class Banner extends Spawnable implements Nameable{
|
||||
$this->saveName($nbt);
|
||||
}
|
||||
|
||||
public function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
protected function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
$nbt->setInt(self::TAG_BASE, $this->baseColor);
|
||||
$nbt->setTag($this->patterns);
|
||||
$this->addNameSpawnData($nbt);
|
||||
|
@ -51,7 +51,7 @@ class Bed extends Spawnable{
|
||||
$nbt->setByte(self::TAG_COLOR, $this->color);
|
||||
}
|
||||
|
||||
public function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
protected function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
$nbt->setByte(self::TAG_COLOR, $this->color);
|
||||
}
|
||||
|
||||
|
@ -192,7 +192,7 @@ class Chest extends Spawnable implements InventoryHolder, Container, Nameable{
|
||||
return true;
|
||||
}
|
||||
|
||||
public function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
protected function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
if($this->isPaired()){
|
||||
$nbt->setInt(self::TAG_PAIRX, $this->pairX);
|
||||
$nbt->setInt(self::TAG_PAIRZ, $this->pairZ);
|
||||
|
@ -35,7 +35,7 @@ class EnderChest extends Spawnable{
|
||||
|
||||
}
|
||||
|
||||
public function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
protected function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
|
||||
}
|
||||
|
||||
|
@ -83,7 +83,7 @@ class FlowerPot extends Spawnable{
|
||||
return $this->getItem()->isNull();
|
||||
}
|
||||
|
||||
public function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
protected function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
$nbt->setShort(self::TAG_ITEM, $this->item->getId());
|
||||
$nbt->setInt(self::TAG_ITEM_DATA, $this->item->getDamage());
|
||||
}
|
||||
|
@ -230,7 +230,7 @@ class Furnace extends Spawnable implements InventoryHolder, Container, Nameable{
|
||||
return $ret;
|
||||
}
|
||||
|
||||
public function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
protected function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
$nbt->setShort(self::TAG_BURN_TIME, $this->burnTime);
|
||||
$nbt->setShort(self::TAG_COOK_TIME, $this->cookTime);
|
||||
|
||||
|
@ -90,7 +90,7 @@ class ItemFrame extends Spawnable{
|
||||
$this->onChanged();
|
||||
}
|
||||
|
||||
public function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
protected function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
$nbt->setFloat(self::TAG_ITEM_DROP_CHANCE, $this->itemDropChance);
|
||||
$nbt->setByte(self::TAG_ITEM_ROTATION, $this->itemRotation);
|
||||
$nbt->setTag($this->item->nbtSerialize(-1, self::TAG_ITEM));
|
||||
|
@ -120,7 +120,7 @@ class Sign extends Spawnable{
|
||||
return $this->text;
|
||||
}
|
||||
|
||||
public function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
protected function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
$nbt->setString(self::TAG_TEXT_BLOB, implode("\n", $this->text));
|
||||
}
|
||||
|
||||
|
@ -65,7 +65,7 @@ class Skull extends Spawnable{
|
||||
return $this->skullType;
|
||||
}
|
||||
|
||||
public function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
protected function addAdditionalSpawnData(CompoundTag $nbt) : void{
|
||||
$nbt->setByte(self::TAG_SKULL_TYPE, $this->skullType);
|
||||
$nbt->setByte(self::TAG_ROT, $this->skullRotation);
|
||||
}
|
||||
|
@ -120,7 +120,7 @@ abstract class Spawnable extends Tile{
|
||||
*
|
||||
* @param CompoundTag $nbt
|
||||
*/
|
||||
abstract public function addAdditionalSpawnData(CompoundTag $nbt) : void;
|
||||
abstract protected function addAdditionalSpawnData(CompoundTag $nbt) : void;
|
||||
|
||||
/**
|
||||
* Called when a player updates a block entity's NBT data
|
||||
|
Loading…
x
Reference in New Issue
Block a user