endstone::Position
Represents a 3-dimensional position in a dimension within a level.
Bases: endstone::Vector< float >
Functions:
| Name | Description |
|---|---|
Position | |
Position | |
getBlockX | Gets the floored value of the X component, indicating the block that this location is contained with. |
getBlockY | Gets the floored value of the Y component, indicating the block that this location is contained with. |
getBlockZ | Gets the floored value of the Z component, indicating the block that this location is contained with. |
getDimension | |
setDimension |
Position
template <typename T, typename> Position(T x, T y, T z)template <typename T, typename> Position(T x, T y, T z, Dimension &dimension) getBlockX
int getBlockX() constGets the floored value of the X component, indicating the block that this location is contained with.
Returns:
block X
getBlockY
int getBlockY() constGets the floored value of the Y component, indicating the block that this location is contained with.
Returns:
block Y
getBlockZ
int getBlockZ() constGets the floored value of the Z component, indicating the block that this location is contained with.
Returns:
block Z
getDimension
Dimension *getDimension() constGets the dimension that this position resides in
Returns:
Dimension that contains this position, or nullptr if the dimension is not set.
setDimension
void setDimension(Dimension &dimension)Sets the dimension that this position resides in
Parameters:
dimensionNew dimension that this position resides in
Last updated on