mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-13 09:19:42 +00:00
Fixed Chest and Furnace placing, Furnace open
This commit is contained in:
parent
e1c0976927
commit
a371890962
@ -55,7 +55,7 @@ class BurningFurnace extends Solid{
|
|||||||
new Int("z", $this->z)
|
new Int("z", $this->z)
|
||||||
));
|
));
|
||||||
$nbt->Items->setTagType(NBT::TAG_Compound);
|
$nbt->Items->setTagType(NBT::TAG_Compound);
|
||||||
new Furnace($this->getLevel(), $nbt);
|
new Furnace($this->getLevel()->getChunkAt($this->x >> 4, $this->z >> 4), $nbt);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@ -81,14 +81,14 @@ class BurningFurnace extends Solid{
|
|||||||
new Int("z", $this->z)
|
new Int("z", $this->z)
|
||||||
));
|
));
|
||||||
$nbt->Items->setTagType(NBT::TAG_Compound);
|
$nbt->Items->setTagType(NBT::TAG_Compound);
|
||||||
$furnace = new Furnace($this->getLevel(), $nbt);
|
$furnace = new Furnace($this->getLevel()->getChunkAt($this->x >> 4, $this->z >> 4), $nbt);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(($player->getGamemode() & 0x01) === 0x01){
|
if(($player->getGamemode() & 0x01) === 0x01){
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
$furnace->openInventory($player);
|
$player->addWindow($furnace->getInventory());
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -77,7 +77,7 @@ class Chest extends Transparent{
|
|||||||
new Int("z", $this->z)
|
new Int("z", $this->z)
|
||||||
));
|
));
|
||||||
$nbt->Items->setTagType(NBT::TAG_Compound);
|
$nbt->Items->setTagType(NBT::TAG_Compound);
|
||||||
$tile = new TileChest($this->getLevel(), $nbt);
|
$tile = new TileChest($this->getLevel()->getChunkAt($this->x >> 4, $this->z >> 4), $nbt);
|
||||||
|
|
||||||
if($chest instanceof TileChest){
|
if($chest instanceof TileChest){
|
||||||
$chest->pairWith($tile);
|
$chest->pairWith($tile);
|
||||||
@ -117,7 +117,7 @@ class Chest extends Transparent{
|
|||||||
new Int("z", $this->z)
|
new Int("z", $this->z)
|
||||||
));
|
));
|
||||||
$nbt->Items->setTagType(NBT::TAG_Compound);
|
$nbt->Items->setTagType(NBT::TAG_Compound);
|
||||||
$chest = new TileChest($this->getLevel(), $nbt);
|
$chest = new TileChest($this->getLevel()->getChunkAt($this->x >> 4, $this->z >> 4), $nbt);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user