mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 12:09:43 +00:00
# Conflicts: # src/API/AchievementAPI.php # src/API/BanAPI.php # src/API/BlockAPI.php # src/API/EntityAPI.php # src/API/PlayerAPI.php # src/Player.php # src/PocketMinecraftServer.php # src/config.php # src/entity/Animal.php # src/entity/Breedable.php # src/entity/Creature.php # src/entity/Entity.php # src/entity/animal/Sheep.php # src/entity/monster/Creeper.php # src/entity/monster/Zombie.php # src/entity/object/Arrow.php # src/entity/object/FallingSand.php # src/entity/object/ItemEntity.php # src/entity/object/Minecart.php # src/entity/object/Painting.php # src/entity/object/PrimedTNT.php # src/material/Block.php # src/material/Item.php # src/material/Material.php # src/material/StaticBlock.php # src/material/block/DoorBlock.php # src/material/block/GenericBlock.php # src/material/block/attachable/WallSignBlock.php # src/material/block/liquid/LiquidBlockDynamic.php # src/material/block/misc/AirBlock.php # src/material/block/misc/BedBlock.php # src/material/block/misc/TNTBlock.php # src/material/block/nonfull/CarpetBlock.php # src/material/block/nonfull/FenceBlock.php # src/material/block/nonfull/PoweredRailBlock.php # src/material/block/nonfull/RailBlock.php # src/material/block/nonfull/SnowLayerBlock.php # src/material/block/nonfull/WoodSlabBlock.php # src/material/block/plant/BrownMushroomBlock.php # src/material/block/plant/DandelionBlock.php # src/material/block/plant/MelonStemBlock.php # src/material/block/plant/PumpkinStemBlock.php # src/material/block/plant/RedMushroomBlock.php # src/material/block/plant/SugarcaneBlock.php # src/material/block/solid/GrassBlock.php # src/material/block/solid/IceBlock.php # src/material/block/solid/LeavesBlock.php # src/material/block/solid/ObsidianBlock.php # src/material/block/solid/PumpkinBlock.php # src/material/block/solid/WoolBlock.php # src/material/item/base/ItemHoe.php # src/material/item/base/ItemTool.php # src/material/item/generic/DyeItem.php # src/material/item/generic/SpawnEggItem.php # src/material/item/tool/FlintSteelItem.php # src/material/item/tool/ShearsItem.php # src/math/AxisAlignedBB.php # src/network/MinecraftInterface.php # src/network/UDPSocket.php # src/network/protocol/packet/AddItemEntityPacket.php # src/network/protocol/packet/ContainerSetContentPacket.php # src/network/raknet/RakNetDataPacket.php # src/network/raknet/RakNetParser.php # src/pmf/PMFLevel.php # src/utils/Utils.php # src/world/Explosion.php # src/world/Level.php # src/world/MobSpawner.php
27 lines
No EOL
672 B
PHP
27 lines
No EOL
672 B
PHP
<?php
|
|
|
|
class GlowstoneBlock extends TransparentBlock implements LightingBlock{
|
|
public static $blockID;
|
|
public function __construct(){
|
|
parent::__construct(GLOWSTONE_BLOCK, 0, "Glowstone");
|
|
$this->hardness = 1.5;
|
|
$this->breakTime = 0.3;
|
|
$this->material = Material::$glass;
|
|
$this->lightBlock = 255;
|
|
$this->lightEmission = 15;
|
|
}
|
|
|
|
public function getMaxLightValue(){
|
|
return 15;
|
|
}
|
|
|
|
public function getDrops(Item $item, Player $player){
|
|
return [
|
|
[GLOWSTONE_DUST, 0, mt_rand(2, 4)],
|
|
];
|
|
}
|
|
|
|
public static function getCollisionBoundingBoxes(Level $level, $x, $y, $z, Entity $entity){
|
|
return [new AxisAlignedBB($x, $y, $z, $x + 1, $y + 1, $z + 1)];
|
|
}
|
|
} |