public class BlockFalling extends BlockType
ItemType.Context
ADJACENT, drops, placeSound, SIDES
Constructor and Description |
---|
BlockFalling(org.bukkit.Material drop) |
Modifier and Type | Method and Description |
---|---|
void |
afterPlace(GlowPlayer player,
GlowBlock block,
org.bukkit.inventory.ItemStack holding,
GlowBlockState oldState)
Called after a block has been placed by a player.
|
void |
onNearBlockChanged(GlowBlock me,
org.bukkit.block.BlockFace face,
GlowBlock other,
org.bukkit.Material oldType,
byte oldData,
org.bukkit.Material newType,
byte newData)
Called when a neighboring block (within a 3x3x3 cube) has changed its type or data and
physics checks should occur.
|
protected void |
transformToFallingEntity(GlowBlock me) |
void |
updatePhysicsAfterEvent(GlowBlock me) |
afterDestroy, blockDestroy, blockInteract, canAbsorb, canOverride, canPlaceAt, canTickRandomly, createBlockEntity, getDrops, getMinedDrops, getOppositeBlockFace, getPlaceAs, getPlaceSound, getPulseTickSpeed, isPulseOnce, leftClickBlock, onBlockChanged, onEntityStep, onRedstoneUpdate, placeBlock, receivePulse, requestPulse, rightClickBlock, setDrops, setPlaceSound, updateBlock, updatePhysics, warnMaterialData
getContext, getId, getMaterial, getMaxStackSize, rightClickAir, setId, setMaterial, setMaxStackSize, setPlaceAs, setPlaceAs, toString
public void afterPlace(GlowPlayer player, GlowBlock block, org.bukkit.inventory.ItemStack holding, GlowBlockState oldState)
BlockType
afterPlace
in class BlockType
player
- the player who placed the blockblock
- the block that was placedholding
- the the ItemStack that was being heldoldState
- The old block state before the block was placed.public void onNearBlockChanged(GlowBlock me, org.bukkit.block.BlockFace face, GlowBlock other, org.bukkit.Material oldType, byte oldData, org.bukkit.Material newType, byte newData)
BlockType
onNearBlockChanged
in class BlockType
me
- The block to perform physics checks forface
- The BlockFace to the changed block, or null if unavailableother
- The neighboring block that has changedoldType
- The old type of the changed blockoldData
- The old data of the changed blocknewType
- The new type of the changed blocknewData
- The new data of the changed blockpublic void updatePhysicsAfterEvent(GlowBlock me)
updatePhysicsAfterEvent
in class BlockType
protected void transformToFallingEntity(GlowBlock me)
Copyright © 2021. All rights reserved.