Interface IChunkGrid
Interface for all Chunk Grid implementations (both on server side and client-side). Chunk Grid is 3D grid of IChunk objects.
Assembly: Eco.Shared.dll
Syntax
public interface IChunkGrid
Properties
MaxChunkPos
Declaration
Vector3i MaxChunkPos { get; }
Property Value
MinChunkPos
Declaration
Vector3i MinChunkPos { get; }
Property Value
WrappedChunkSize
Declaration
Vector3i WrappedChunkSize { get; }
Property Value
WrappedVoxelSize
Declaration
Vector3i WrappedVoxelSize { get; }
Property Value
Methods
Clear(Guid)
Removes all chunks from grid.
Declaration
Parameters
Type |
Name |
Description |
System.Guid |
newGuid |
|
ClosestWrappedLocation(Vector3, Vector3)
Declaration
Vector3 ClosestWrappedLocation(Vector3 viewPosition, Vector3 position)
Parameters
Type |
Name |
Description |
System.Numerics.Vector3 |
viewPosition |
|
System.Numerics.Vector3 |
position |
|
Returns
Type |
Description |
System.Numerics.Vector3 |
|
GetChunks(WorldRange)
Declaration
IEnumerable<IChunk> GetChunks(WorldRange range)
Parameters
Returns
Type |
Description |
System.Collections.Generic.IEnumerable<IChunk> |
|
GetVisibleChunks(Vector3, Single)
Declaration
IEnumerable<IChunk> GetVisibleChunks(Vector3 observerPosition, float viewDistance)
Parameters
Type |
Name |
Description |
System.Numerics.Vector3 |
observerPosition |
|
System.Single |
viewDistance |
|
Returns
Type |
Description |
System.Collections.Generic.IEnumerable<IChunk> |
|
Events
SizeChangedEvent
Declaration
event Action<Vector3i> SizeChangedEvent
Event Type
Type |
Description |
System.Action<Vector3i> |
|
Extension Methods