Fixed some items not keeping meta when constructed, close #968

This commit is contained in:
Dylan K. Taylor 2017-07-30 19:46:24 +01:00
parent 1f4e6535bb
commit 8a3b31077e
28 changed files with 28 additions and 28 deletions

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class Apple extends Food{ class Apple extends Food{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::APPLE, 0, $count, "Apple"); parent::__construct(self::APPLE, $meta, $count, "Apple");
} }
public function getFoodRestore() : int{ public function getFoodRestore() : int{

View File

@ -28,7 +28,7 @@ use pocketmine\block\Block;
class Bed extends Item{ class Bed extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::BED_BLOCK); $this->block = Block::get(Item::BED_BLOCK);
parent::__construct(self::BED, 0, $count, "Bed"); parent::__construct(self::BED, $meta, $count, "Bed");
} }
public function getMaxStackSize(){ public function getMaxStackSize(){

View File

@ -28,6 +28,6 @@ use pocketmine\block\Block;
class BeetrootSeeds extends Item{ class BeetrootSeeds extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::BEETROOT_BLOCK); $this->block = Block::get(Item::BEETROOT_BLOCK);
parent::__construct(self::BEETROOT_SEEDS, 0, $count, "Beetroot Seeds"); parent::__construct(self::BEETROOT_SEEDS, $meta, $count, "Beetroot Seeds");
} }
} }

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class BeetrootSoup extends Food{ class BeetrootSoup extends Food{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::BEETROOT_SOUP, 0, $count, "Beetroot Soup"); parent::__construct(self::BEETROOT_SOUP, $meta, $count, "Beetroot Soup");
} }
public function getMaxStackSize(){ public function getMaxStackSize(){

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class Bowl extends Item{ class Bowl extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::BOWL, 0, $count, "Bowl"); parent::__construct(self::BOWL, $meta, $count, "Bowl");
} }
} }

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class Brick extends Item{ class Brick extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::BRICK, 0, $count, "Brick"); parent::__construct(self::BRICK, $meta, $count, "Brick");
} }
} }

View File

@ -28,7 +28,7 @@ use pocketmine\block\Block;
class Cake extends Item{ class Cake extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::CAKE_BLOCK); $this->block = Block::get(Item::CAKE_BLOCK);
parent::__construct(self::CAKE, 0, $count, "Cake"); parent::__construct(self::CAKE, $meta, $count, "Cake");
} }
public function getMaxStackSize(){ public function getMaxStackSize(){

View File

@ -28,7 +28,7 @@ use pocketmine\block\Block;
class Carrot extends Food{ class Carrot extends Food{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::CARROT_BLOCK); $this->block = Block::get(Item::CARROT_BLOCK);
parent::__construct(self::CARROT, 0, $count, "Carrot"); parent::__construct(self::CARROT, $meta, $count, "Carrot");
} }
public function getFoodRestore() : int{ public function getFoodRestore() : int{

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class Diamond extends Item{ class Diamond extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::DIAMOND, 0, $count, "Diamond"); parent::__construct(self::DIAMOND, $meta, $count, "Diamond");
} }
} }

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class Feather extends Item{ class Feather extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::FEATHER, 0, $count, "Feather"); parent::__construct(self::FEATHER, $meta, $count, "Feather");
} }
} }

View File

@ -25,6 +25,6 @@ namespace pocketmine\item;
class FishingRod extends Item{ class FishingRod extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::FISHING_ROD, 0, $count, "Fishing Rod"); parent::__construct(self::FISHING_ROD, $meta, $count, "Fishing Rod");
} }
} }

View File

@ -28,6 +28,6 @@ use pocketmine\block\Block;
class FlowerPot extends Item{ class FlowerPot extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::FLOWER_POT_BLOCK); $this->block = Block::get(Item::FLOWER_POT_BLOCK);
parent::__construct(self::FLOWER_POT, 0, $count, "Flower Pot"); parent::__construct(self::FLOWER_POT, $meta, $count, "Flower Pot");
} }
} }

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class GoldIngot extends Item{ class GoldIngot extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::GOLD_INGOT, 0, $count, "Gold Ingot"); parent::__construct(self::GOLD_INGOT, $meta, $count, "Gold Ingot");
} }
} }

View File

@ -28,7 +28,7 @@ use pocketmine\block\Block;
class IronDoor extends Item{ class IronDoor extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::IRON_DOOR_BLOCK); $this->block = Block::get(Item::IRON_DOOR_BLOCK);
parent::__construct(self::IRON_DOOR, 0, $count, "Iron Door"); parent::__construct(self::IRON_DOOR, $meta, $count, "Iron Door");
} }
public function getMaxStackSize(){ public function getMaxStackSize(){

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class IronIngot extends Item{ class IronIngot extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::IRON_INGOT, 0, $count, "Iron Ingot"); parent::__construct(self::IRON_INGOT, $meta, $count, "Iron Ingot");
} }
} }

View File

@ -28,6 +28,6 @@ use pocketmine\block\Block;
class ItemFrame extends Item{ class ItemFrame extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Block::ITEM_FRAME_BLOCK); $this->block = Block::get(Block::ITEM_FRAME_BLOCK);
parent::__construct(self::ITEM_FRAME, 0, $count, "Item Frame"); parent::__construct(self::ITEM_FRAME, $meta, $count, "Item Frame");
} }
} }

View File

@ -28,6 +28,6 @@ use pocketmine\block\Block;
class MelonSeeds extends Item{ class MelonSeeds extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::MELON_STEM); $this->block = Block::get(Item::MELON_STEM);
parent::__construct(self::MELON_SEEDS, 0, $count, "Melon Seeds"); parent::__construct(self::MELON_SEEDS, $meta, $count, "Melon Seeds");
} }
} }

View File

@ -25,7 +25,7 @@ namespace pocketmine\item;
class MushroomStew extends Food{ class MushroomStew extends Food{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::MUSHROOM_STEW, 0, $count, "Mushroom Stew"); parent::__construct(self::MUSHROOM_STEW, $meta, $count, "Mushroom Stew");
} }
public function getMaxStackSize(){ public function getMaxStackSize(){

View File

@ -25,7 +25,7 @@ namespace pocketmine\item;
class NetherQuartz extends Item{ class NetherQuartz extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::NETHER_QUARTZ, 0, $count, "Nether Quartz"); parent::__construct(self::NETHER_QUARTZ, $meta, $count, "Nether Quartz");
} }
} }

View File

@ -29,7 +29,7 @@ use pocketmine\Player;
class Painting extends Item{ class Painting extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::PAINTING, 0, $count, "Painting"); parent::__construct(self::PAINTING, $meta, $count, "Painting");
} }
public function onActivate(Level $level, Player $player, Block $block, Block $target, $face, $fx, $fy, $fz){ public function onActivate(Level $level, Player $player, Block $block, Block $target, $face, $fx, $fy, $fz){

View File

@ -28,7 +28,7 @@ use pocketmine\block\Block;
class Potato extends Food{ class Potato extends Food{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::POTATO_BLOCK); $this->block = Block::get(Item::POTATO_BLOCK);
parent::__construct(self::POTATO, 0, $count, "Potato"); parent::__construct(self::POTATO, $meta, $count, "Potato");
} }
public function getFoodRestore() : int{ public function getFoodRestore() : int{

View File

@ -28,6 +28,6 @@ use pocketmine\block\Block;
class PumpkinSeeds extends Item{ class PumpkinSeeds extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::PUMPKIN_STEM); $this->block = Block::get(Item::PUMPKIN_STEM);
parent::__construct(self::PUMPKIN_SEEDS, 0, $count, "Pumpkin Seeds"); parent::__construct(self::PUMPKIN_SEEDS, $meta, $count, "Pumpkin Seeds");
} }
} }

View File

@ -28,7 +28,7 @@ use pocketmine\block\Block;
class Sign extends Item{ class Sign extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::SIGN_POST); $this->block = Block::get(Item::SIGN_POST);
parent::__construct(self::SIGN, 0, $count, "Sign"); parent::__construct(self::SIGN, $meta, $count, "Sign");
} }
public function getMaxStackSize(){ public function getMaxStackSize(){

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class Snowball extends Item{ class Snowball extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::SNOWBALL, 0, $count, "Snowball"); parent::__construct(self::SNOWBALL, $meta, $count, "Snowball");
} }
public function getMaxStackSize(){ public function getMaxStackSize(){

View File

@ -26,7 +26,7 @@ namespace pocketmine\item;
class Stick extends Item{ class Stick extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
parent::__construct(self::STICK, 0, $count, "Stick"); parent::__construct(self::STICK, $meta, $count, "Stick");
} }
} }

View File

@ -28,6 +28,6 @@ use pocketmine\block\Block;
class Sugarcane extends Item{ class Sugarcane extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::SUGARCANE_BLOCK); $this->block = Block::get(Item::SUGARCANE_BLOCK);
parent::__construct(self::SUGARCANE, 0, $count, "Sugar Cane"); parent::__construct(self::SUGARCANE, $meta, $count, "Sugar Cane");
} }
} }

View File

@ -28,6 +28,6 @@ use pocketmine\block\Block;
class WheatSeeds extends Item{ class WheatSeeds extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::WHEAT_BLOCK); $this->block = Block::get(Item::WHEAT_BLOCK);
parent::__construct(self::WHEAT_SEEDS, 0, $count, "Wheat Seeds"); parent::__construct(self::WHEAT_SEEDS, $meta, $count, "Wheat Seeds");
} }
} }

View File

@ -28,7 +28,7 @@ use pocketmine\block\Block;
class WoodenDoor extends Item{ class WoodenDoor extends Item{
public function __construct($meta = 0, $count = 1){ public function __construct($meta = 0, $count = 1){
$this->block = Block::get(Item::WOODEN_DOOR_BLOCK); $this->block = Block::get(Item::WOODEN_DOOR_BLOCK);
parent::__construct(self::WOODEN_DOOR, 0, $count, "Wooden Door"); parent::__construct(self::WOODEN_DOOR, $meta, $count, "Wooden Door");
} }
public function getMaxStackSize(){ public function getMaxStackSize(){