Package net.glowstone.generator.objects
Interface TerrainObject
- All Known Implementing Classes:
AcaciaTree
,BigOakTree
,BigTree
,BirchTree
,BlockPatch
,BrownMushroomTree
,Cactus
,CocoaTree
,DarkOakTree
,DoubleTallPlant
,Flower
,GenericTree
,GlowStructure
,GlowTemple
,IceSpike
,JungleBush
,JungleTree
,Lake
,MegaJungleTree
,MegaPineTree
,MegaRedwoodTree
,MegaSpruceTree
,ObsidianPillar
,OreVein
,RedMushroomTree
,RedwoodTree
,StoneBoulder
,SugarCane
,SwampTree
,TallBirchTree
,TallGrass
,TallRedwoodTree
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A terrain feature that can randomly generate itself at specified locations, replacing blocks.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionboolean
Generates this feature.static boolean
killPlantAbove
(org.bukkit.block.Block block) Removes the grass, shrub, flower or mushroom directly above the given block, if present.
-
Field Details
-
PLANT_TYPES
Plant block types.
-
-
Method Details
-
killPlantAbove
static boolean killPlantAbove(org.bukkit.block.Block block) Removes the grass, shrub, flower or mushroom directly above the given block, if present. Does not drop an item.- Parameters:
block
- the block to update- Returns:
- true if a plant was removed; false if none was present
-
generate
Generates this feature.- Parameters:
world
- the world to generate inrandom
- the PRNG that will choose the size and a few details of the shapesourceX
- the base X coordinatesourceY
- the base Y coordinatesourceZ
- the base Z coordinate- Returns:
- true if successfully generated
-