Interface for types that define the geometry of one chunk in the world. A chunk is a cubic region of blocks, with the world made up of a regular grid of chunks.
More...
|
bool | Raycast (Ray ray, float maxDist, out WorldRaycastHit hitInfo) |
| Projects a point along a line, testing to see if it hits any blocks inside the chunk. Returns true if it hits a block, outputting information about the collision. More...
|
|
bool | Sweep (SweptAABB toSweep, float maxDist, out WorldSweepHit hitInfo) |
| Projects an axis aligned bounding box, testing to see if it hits any blocks inside the chunk. Returns true if it hits a block, outputting information about the collision. More...
|
|
bool | GetNonEmptyBounds (out IntVector min, out IntVector max) |
|
bool | Set (IntVector min, IntVector max, [NotNull] Block value, bool replace) |
| Sets an axis aligned box of blocks within this chunk to the given value, using a minimum and maximum position in local block space to define the region to set. More...
|
|
Block | Get (IntVector pos) |
| Gets the value of a single block inside this chunk from a given position in local block space. More...
|
|
Interface for types that define the geometry of one chunk in the world. A chunk is a cubic region of blocks, with the world made up of a regular grid of chunks.
Gets the value of a single block inside this chunk from a given position in local block space.
- Parameters
-
pos | Position in local block space |
bool Chunks.Geometry.IChunk.Raycast |
( |
Ray |
ray, |
|
|
float |
maxDist, |
|
|
out WorldRaycastHit |
hitInfo |
|
) |
| |
Projects a point along a line, testing to see if it hits any blocks inside the chunk. Returns true if it hits a block, outputting information about the collision.
- Parameters
-
ray | A ray describing the starting point relative to the chunk position, and direction to cast |
maxDist | Maximum distance to cast |
hitInfo | If true is returned, contains hit information |
Sets an axis aligned box of blocks within this chunk to the given value, using a minimum and maximum position in local block space to define the region to set.
- Parameters
-
min | Minimum bounds position within the chunk |
max | Maximum bounds position wihtin the chunk |
value | Block value to set |
Projects an axis aligned bounding box, testing to see if it hits any blocks inside the chunk. Returns true if it hits a block, outputting information about the collision.
- Parameters
-
toSweep | Axis aligned bounding box to sweep, and the direction to sweep it in |
maxDist | Maximum distance to sweep the bounding box |
hitInfo | If true is returned, contains hit information |
int Chunks.Geometry.IChunk.Size |
|
get |
The number of blocks along each side of this chunk.
The documentation for this interface was generated from the following file: