This commit is contained in:
GameHerobrine 2023-12-19 22:34:04 +03:00
parent 6d430c3440
commit b84093e4ce
25 changed files with 48 additions and 163 deletions

View file

@ -68,7 +68,7 @@ class PaintingItem extends Item{
$validMotives[] = $motive;
}
}
$motive = $validMotives[array_rand($validMotives)]; //TODO simplify if possible
$motive = $validMotives[array_rand($validMotives)];
$data = array(
"x" => $target->x,
"y" => $target->y,

View file

@ -9,7 +9,7 @@ class FlintSteelItem extends ItemTool{
public function onActivate(Level $level, Player $player, Block $block, Block $target, $face, $fx, $fy, $fz){
if(($player->gamemode & 0x01) === 0 and $this->useOn($block) and $this->getMetadata() >= $this->getMaxDurability()){
$player->setSlot($player->slot, new Item(AIR, 0, 0), false); //TODO check
$player->setSlot($player->slot, new Item(AIR, 0, 0), false);
}
if($block->getID() === AIR and ($target instanceof SolidBlock)){
$level->setBlock($block, new FireBlock(), true, false, true);