CylinderCaveNodeShape

public class CylinderCaveNodeShape extends AbstractCaveNodeShape implements IWorldBounds

Class CylinderCaveNodeShape. Provides cylindercavenodeshape functionality for the Hytale server.

java.lang.Object > AbstractCaveNodeShape > CylinderCaveNodeShape

Field Summary

x

final double x

Field x.

y

final double y

Field y.

z

final double z

Field z.

radius

final double radius

Field radius.

t

final double t

Field t.

r

final double r

Field r.

l

final double l

Field l.

direction

final Vector3d direction

Field direction.

radius2

final double radius2

Field radius2.

offset

final Vector3d offset

Field offset.

Method Detail

CylinderCaveNodeShape

public public CylinderCaveNodeShape (final CaveType caveType, @Nonnull final Vector3d o, @Nonnull final Vector3d v, final double radius1, final double radius2, final double middleRadius)

Method CylinderCaveNodeShape.

Parameters:
final CaveType caveType
@Nonnull final Vector3d o
@Nonnull final Vector3d v
final double radius1
final double radius2
final double middleRadius

getStart

public Vector3d getStart ()

Method getStart.

getEnd

public Vector3d getEnd ()

Method getEnd.

getAnchor

public Vector3d getAnchor (@Nonnull final Vector3d vector, final double t, final double tv, final double th)

Method getAnchor.

Parameters:
@Nonnull final Vector3d vector
final double t
final double tv
final double th

getBounds

public IWorldBounds getBounds ()

Method getBounds.

getLowBoundX

public int getLowBoundX ()

Method getLowBoundX.

getLowBoundZ

public int getLowBoundZ ()

Method getLowBoundZ.

getHighBoundX

public int getHighBoundX ()

Method getHighBoundX.

getHighBoundZ

public int getHighBoundZ ()

Method getHighBoundZ.

getLowBoundY

public int getLowBoundY ()

Method getLowBoundY.

getHighBoundY

public int getHighBoundY ()

Method getHighBoundY.

getRadius1

public double getRadius1 ()

Method getRadius1.

getRadius2

public double getRadius2 ()

Method getRadius2.

shouldReplace

public boolean shouldReplace (final int seed, final double x, final double z, final int y)

Method shouldReplace.

Parameters:
final int seed
final double x
final double z
final int y

projectPointOnNode

private double projectPointOnNode (final double px, final double py, final double pz)

Method projectPointOnNode.

Parameters:
final double px
final double py
final double pz

getRadiusAt

private double getRadiusAt (final double t)

Method getRadiusAt.

Parameters:
final double t

getFloorPosition

public double getFloorPosition (final int seed, final double x, final double z)

Method getFloorPosition.

Parameters:
final int seed
final double x
final double z

getCeilingPosition

public double getCeilingPosition (final int seed, final double x, final double z)

Method getCeilingPosition.

Parameters:
final int seed
final double x
final double z

toString

public String toString ()

Method toString.

CylinderCaveNodeShapeGenerator

public public CylinderCaveNodeShapeGenerator (final IDoubleRange radius, final IDoubleRange middleRadius, final IDoubleRange length, final boolean inheritParentRadius)

Method CylinderCaveNodeShapeGenerator.

Parameters:
final IDoubleRange radius
final IDoubleRange middleRadius
final IDoubleRange length
final boolean inheritParentRadius

generateCaveNodeShape

public CaveNodeShape generateCaveNodeShape (@Nonnull final Random random, final CaveType caveType, final CaveNode parentNode, @Nonnull final CaveNodeType.CaveNodeChildEntry childEntry, @Nonnull final Vector3d origin, final float yaw, final float pitch)

Method generateCaveNodeShape.

Parameters:
@Nonnull final Random random
final CaveType caveType
final CaveNode parentNode
@Nonnull final CaveNodeType.CaveNodeChildEntry childEntry
@Nonnull final Vector3d origin
final float yaw
final float pitch