Struct TilemapDataStruct
Struct containing Tilemap information for use in jobs to get Tile data
Inherited Members
Namespace: Unity.Tilemaps.Experimental
Assembly: Unity.2D.Tilemap.Experimental.dll
Syntax
public struct TilemapDataStruct
Constructors
TilemapDataStruct(Tilemap)
Create a a TilemapDataStruct for the input Tilemap
Declaration
public TilemapDataStruct(Tilemap tilemap)
Parameters
| Type | Name | Description |
|---|---|---|
| Tilemap | tilemap | Tilemap to create TilemapDataStruct for |
Properties
gridData
Gets Grid data for Tilemap
Declaration
public GridData gridData { get; }
Property Value
| Type | Description |
|---|---|
| GridData |
transformHandle
Gets TransformHandle for Tilemap
Declaration
public TransformHandle transformHandle { get; }
Property Value
| Type | Description |
|---|---|
| TransformHandle |
Methods
GetTileAnimationFrameRate()
Gets Tile Animation Frame Rate for Tilemap
Declaration
public float GetTileAnimationFrameRate()
Returns
| Type | Description |
|---|---|
| float | Tile Animation Frame Rate for Tilemap. |
GetTileId(int3)
Gets the Entity Id of the Tile at the position on the Tilemap
Declaration
public EntityId GetTileId(int3 position)
Parameters
| Type | Name | Description |
|---|---|---|
| int3 | position | Position on Tilemap. |
Returns
| Type | Description |
|---|---|
| EntityId | Entity Id of the Tile at the position on the Tilemap. |
GetTilesFromBlockOffset(int3, BoundsInt, NativeArray<EntityId>)
Gets the Entity Ids of Tiles at the position on the Tilemap within the given bounds
Declaration
public void GetTilesFromBlockOffset(int3 position, BoundsInt bounds, NativeArray<EntityId> entityIds)
Parameters
| Type | Name | Description |
|---|---|---|
| int3 | position | Position on Tilemap. |
| BoundsInt | bounds | Bounds surrounding the position. |
| NativeArray<EntityId> | entityIds | Array storing the Entity Ids of Tiles. |