public class BlockPhysicsUtil
Class BlockPhysicsUtil. Provides blockphysicsutil functionality for the Hytale server.
java.lang.Object > BlockPhysicsUtil
Field Summary
boundingBoxes
Field boundingBoxes.
rotatedBox
Field rotatedBox.
boundingBox
Field boundingBox.
blockWidth
Field blockWidth.
blockHeight
Field blockHeight.
blockDepth
Field blockDepth.
fillerX
Field fillerX.
fillerY
Field fillerY.
fillerZ
Field fillerZ.
nx
Field nx.
ny
Field ny.
nz
Field nz.
neighbourFiller
Field neighbourFiller.
neighbourRotation
Field neighbourRotation.
fillerSupportDistance
Field fillerSupportDistance.
world
Field world.
chunkStore
Field chunkStore.
currentSupport
Field currentSupport.
blockFillerOffset
Field blockFillerOffset.
neighbourFillerOffset
Field neighbourFillerOffset.
fluid
Field fluid.
hitbox
Field hitbox.
origin
Field origin.
requiredSupportDistance
Field requiredSupportDistance.
requiredBlockFaceSupports
Field requiredBlockFaceSupports.
connectingFaces
Field connectingFaces.
connectingFaceOffsets
Field connectingFaceOffsets.
neighbourBlockFace
Field neighbourBlockFace.
neighbourDirection
Field neighbourDirection.
neighbourX
Field neighbourX.
neighbourY
Field neighbourY.
neighbourZ
Field neighbourZ.
neighbourFluidId
Field neighbourFluidId.
neighbourBlockId
Field neighbourBlockId.
neighbourBlockType
Field neighbourBlockType.
neighbourFluid
Field neighbourFluid.
doesSatisfyRequirements
Field doesSatisfyRequirements.
supportDistance
Field supportDistance.
supportDistance2
Field supportDistance2.
neighbourBlockTypeKey
Field neighbourBlockTypeKey.
blockSetId
Field blockSetId.
requiredBlockTypeId
Field requiredBlockTypeId.
fluidId
Field fluidId.
tagIndex
Field tagIndex.
blockFaceSupports
Field blockFaceSupports.
Method Detail
applyBlockPhysics
Result
applyBlockPhysics
(@Nullable final ComponentAccessor commandBuffer, @Nonnull final Ref chunkReference, @Nonnull final BlockPhysicsSystems.CachedAccessor chunkAccessor, final BlockSection blockSection, @Nonnull final BlockPhysics blockPhysics, @Nonnull final FluidSection fluidSection, final int blockX, final int blockY, final int blockZ, @Nonnull final BlockType blockType, final int rotation, final int filler)
Method applyBlockPhysics.
- Parameters:
@Nullable final ComponentAccessorcommandBuffer@Nonnull final RefchunkReference@Nonnull final BlockPhysicsSystems.CachedAccessorchunkAccessorfinal BlockSectionblockSection@Nonnull final BlockPhysicsblockPhysics@Nonnull final FluidSectionfluidSectionfinal intblockXfinal intblockYfinal intblockZ@Nonnull final BlockTypeblockTypefinal introtationfinal intfiller
Vector3i
new
Vector3i
(blockX, blockY, blockZ)
Method Vector3i.
- Parameters:
blockXblockXblockYblockYblockZblockZ
testBlockPhysics
int
testBlockPhysics
(@Nonnull final BlockPhysicsSystems.CachedAccessor chunkAccessor, final BlockSection blockSection, @Nullable final BlockPhysics blockPhysics, @Nonnull final FluidSection fluidSection, final int blockX, final int blockY, final int blockZ, @Nonnull final BlockType blockType, final int rotation, final int filler)
Method testBlockPhysics.
- Parameters:
@Nonnull final BlockPhysicsSystems.CachedAccessorchunkAccessorfinal BlockSectionblockSection@Nullable final BlockPhysicsblockPhysics@Nonnull final FluidSectionfluidSectionfinal intblockXfinal intblockYfinal intblockZ@Nonnull final BlockTypeblockTypefinal introtationfinal intfiller
if
else
if
(supportDistance < lowestSupportDistance)
Method if.
- Parameters:
supportDistance <lowestSupportDistance
IllegalArgumentException
new
IllegalArgumentException
("Unknown Support Match type: " + String.valueOf(requiredBlockFaceSupport.getMatchSelf()
Method IllegalArgumentException.
- Parameters:
"Unknown Support Match type: " +String.valueOf(requiredBlockFaceSupport.getMatchSelf(
doesSatisfyRequirements
boolean
doesSatisfyRequirements
(@Nonnull final BlockType blockType, final Fluid fluid, final Vector3i blockFillerOffset, final Vector3i neighbourFillerOffset, final BlockFace blockFace, final BlockFace neighbourBlockFace, final int neighbourBlockId, @Nonnull final BlockType neighbourBlockType, final int neighbourRotation, final int neighbourFluidId, @Nonnull final Fluid neighbourFluid, @Nonnull final RequiredBlockFaceSupport requiredBlockFaceSupport)
Method doesSatisfyRequirements.
- Parameters:
@Nonnull final BlockTypeblockTypefinal Fluidfluidfinal Vector3iblockFillerOffsetfinal Vector3ineighbourFillerOffsetfinal BlockFaceblockFacefinal BlockFaceneighbourBlockFacefinal intneighbourBlockId@Nonnull final BlockTypeneighbourBlockTypefinal intneighbourRotationfinal intneighbourFluidId@Nonnull final FluidneighbourFluid@Nonnull final RequiredBlockFaceSupportrequiredBlockFaceSupport
doesMatchFaceType
boolean
doesMatchFaceType
(final Vector3i fillerOffset, @Nonnull final String faceType, final BlockFace blockFace, @Nonnull final Map supporting)
Method doesMatchFaceType.
- Parameters:
final Vector3ifillerOffset@Nonnull final StringfaceTypefinal BlockFaceblockFace@Nonnull final Mapsupporting