abstract class ToolOperation implements TriIntObjPredicate
Class ToolOperation. Provides tooloperation functionality for the Hytale server.
java.lang.Object > ToolOperation
Field Summary
world
Field world.
playerComponent
Field playerComponent.
playerRefComponent
Field playerRefComponent.
uuidComponent
Field uuidComponent.
uuid
Field uuid.
targetBlockAvoidingPaint
Field targetBlockAvoidingPaint.
builderTool
Field builderTool.
itemArgData
Field itemArgData.
args
Field args.
shapeOrigin
Field shapeOrigin.
originRotation
Field originRotation.
offsets
Field offsets.
brushMin
Field brushMin.
brushMax
Field brushMax.
positions
Field positions.
dx
Field dx.
dy
Field dy.
dz
Field dz.
distance
Field distance.
maxBrushDimension
Field maxBrushDimension.
spacingThreshold
Field spacingThreshold.
t
Field t.
interpX
Field interpX.
interpY
Field interpY.
interpZ
Field interpZ.
spacingValue
Field spacingValue.
densityValue
Field densityValue.
prototypePlayerBuilderToolSettings
Field prototypePlayerBuilderToolSettings.
radiusXZ
Field radiusXZ.
halfHeight
Field halfHeight.
minorRadius
Field minorRadius.
outerRadius
Field outerRadius.
offsetY
Field offsetY.
offsetXZ
Field offsetXZ.
rotate
Field rotate.
mirror
Field mirror.
headRotationComponent
Field headRotationComponent.
toolType
Field toolType.
factory
Field factory.
mask
Field mask.
brushMaskAbove
Field brushMaskAbove.
brushMaskNot
Field brushMaskNot.
brushMaskBelow
Field brushMaskBelow.
brushMaskAdjacent
Field brushMaskAdjacent.
brushMaskNeighbor
Field brushMaskNeighbor.
combinedMask
Field combinedMask.
Method Detail
ToolOperation
public
ToolOperation
(@Nonnull final Ref ref, @Nonnull final BuilderToolOnUseInteraction packet, @Nonnull final ComponentAccessor componentAccessor)
Method ToolOperation.
- Parameters:
@Nonnull final Refref@Nonnull final BuilderToolOnUseInteractionpacket@Nonnull final ComponentAccessorcomponentAccessor
getOrCreatePrototypeSettings
Method getOrCreatePrototypeSettings.
- Parameters:
final UUIDplayerUuid
calculateInterpolatedPositions
List
calculateInterpolatedPositions
(@Nullable final Vector3i lastPosition, @Nonnull final Vector3i currentPosition, final int brushWidth, final int brushHeight, final int brushSpacing)
Method calculateInterpolatedPositions.
- Parameters:
@Nullable final Vector3ilastPosition@Nonnull final Vector3icurrentPositionfinal intbrushWidthfinal intbrushHeightfinal intbrushSpacing
if
else
if
(distance >= brushSpacing)
Method if.
- Parameters:
distance >=brushSpacing
getBrushWidth
int
getBrushWidth
()
Method getBrushWidth.
getBrushHeight
int
getBrushHeight
()
Method getBrushHeight.
getBrushSpacing
int
getBrushSpacing
()
Method getBrushSpacing.
getBrushDensity
int
getBrushDensity
()
Method getBrushDensity.
executeAsBrushConfig
void
executeAsBrushConfig
(@Nonnull final PrototypePlayerBuilderToolSettings prototypePlayerBuilderToolSettings, @Nonnull final BuilderToolOnUseInteraction packet, final ComponentAccessor componentAccessor)
Method executeAsBrushConfig.
- Parameters:
@Nonnull final PrototypePlayerBuilderToolSettingsprototypePlayerBuilderToolSettings@Nonnull final BuilderToolOnUseInteractionpacketfinal ComponentAccessorcomponentAccessor
getPattern
BlockPattern
getPattern
(@Nonnull final BuilderToolOnUseInteraction packet, @Nonnull final BrushData.Values brush)
Method getPattern.
- Parameters:
@Nonnull final BuilderToolOnUseInteractionpacket@Nonnull final BrushData.Valuesbrush
getTargetBlockAvoidingPaint
Vector3i
getTargetBlockAvoidingPaint
(@Nonnull final Ref ref, final double maxDistance, @Nonnull final ComponentAccessor componentAccessor, final float raycastOriginX, final float raycastOriginY, final float raycastOriginZ, final float raycastDirectionX, final float raycastDirectionY, final float raycastDirectionZ)
Method getTargetBlockAvoidingPaint.
- Parameters:
@Nonnull final Refreffinal doublemaxDistance@Nonnull final ComponentAccessorcomponentAccessorfinal floatraycastOriginXfinal floatraycastOriginYfinal floatraycastOriginZfinal floatraycastDirectionXfinal floatraycastDirectionYfinal floatraycastDirectionZ
test
boolean
test
(int x, int y, int z, final Void aVoid)
Method test.
- Parameters:
intxintyintzfinal VoidaVoid
executeAt
void
executeAt
(final int posX, final int posY, final int posZ, final ComponentAccessor componentAccessor)
Method executeAt.
- Parameters:
final intposXfinal intposYfinal intposZfinal ComponentAccessorcomponentAccessor
executeShapeOperation
void
executeShapeOperation
(final int x, final int y, final int z, @Nonnull final TriIntObjPredicate operation, @Nonnull final BrushShape shape, final int shapeRange, final int shapeHeight, final int shapeThickness, final boolean capped)
Method executeShapeOperation.
- Parameters:
final intxfinal intyfinal intz@Nonnull final TriIntObjPredicateoperation@Nonnull final BrushShapeshapefinal intshapeRangefinal intshapeHeightfinal intshapeThicknessfinal booleancapped
getOffsets
Vector3i
getOffsets
(final int width, final int height, final boolean originRotation, final BrushOrigin origin, @Nonnull final Transform transform, @Nonnull final Vector3i vector, final boolean applyBottomOriginFix)
Method getOffsets.
- Parameters:
final intwidthfinal intheightfinal booleanoriginRotationfinal BrushOriginorigin@Nonnull final Transformtransform@Nonnull final Vector3ivectorfinal booleanapplyBottomOriginFix
getTransform
Transform
getTransform
(@Nonnull final Ref ref, @Nonnull final BrushData.Values brushData, @Nonnull final Vector3i vector, @Nonnull final ComponentAccessor componentAccessor)
Method getTransform.
- Parameters:
@Nonnull final Refref@Nonnull final BrushData.ValuesbrushData@Nonnull final Vector3ivector@Nonnull final ComponentAccessorcomponentAccessor
getRotation
Transform
getRotation
(@Nonnull final Ref ref, @Nonnull final BrushData.Values brushData, @Nonnull final Vector3i vector, @Nonnull final ComponentAccessor componentAccessor)
Method getRotation.
- Parameters:
@Nonnull final Refref@Nonnull final BrushData.ValuesbrushData@Nonnull final Vector3ivector@Nonnull final ComponentAccessorcomponentAccessor
getMirror
Transform
getMirror
(@Nonnull final Ref ref, @Nonnull final BrushData.Values brushData, @Nonnull final Vector3i vector, @Nonnull final ComponentAccessor componentAccessor)
Method getMirror.
- Parameters:
@Nonnull final Refref@Nonnull final BrushData.ValuesbrushData@Nonnull final Vector3ivector@Nonnull final ComponentAccessorcomponentAccessor
fromPacket
ToolOperation
fromPacket
(@Nonnull final Ref ref, @Nonnull final Player player, @Nonnull final BuilderToolOnUseInteraction packet, @Nonnull final ComponentAccessor componentAccessor)
Method fromPacket.
- Parameters:
@Nonnull final Refref@Nonnull final Playerplayer@Nonnull final BuilderToolOnUseInteractionpacket@Nonnull final ComponentAccessorcomponentAccessor
combineMasks
BlockMask
combineMasks
(@Nullable final BrushData.Values brush, @Nullable final BlockMask globalMask)
Method combineMasks.
- Parameters:
@Nullable final BrushData.Valuesbrush@Nullable final BlockMaskglobalMask
SmoothOperation
new
SmoothOperation
(ref, packet, componentAccessor)
Method SmoothOperation.
- Parameters:
refrefpacketpacketcomponentAccessorcomponentAccessor