Base class of TileCollider
More...
|
virtual void | GetPolygons (Vector2 cellPos, List< List< Vector2 >> polygons) |
| Get polygons. More...
|
|
virtual bool | IsUpdateCollider (Collider2D collider, Vector2 cellPos) |
| Determines whether the need to update the collider In the inherited class, to determine the change of property to each other as needed. More...
|
|
Collider2D | UpdateCollider (Collider2D collider, GameObject colliderObject, Vector2 pos, bool isCellObject, out bool changed) |
| To update the Collider More...
|
|
Base class of TileCollider
If you want to inheritance be done from TileCollider class that corresponds to the generic.
virtual void GetPolygons |
( |
Vector2 |
cellPos, |
|
|
List< List< Vector2 >> |
polygons |
|
) |
| |
|
virtual |
Get polygons.
For inherited classes, store polygons in the list if necessary.
- Parameters
-
cellPos | Cell position |
polygons | List containing polygons |
abstract System.Type GetRequireColliderType |
( |
| ) |
|
|
protectedpure virtual |
Get the type of request to Collider2D.
- Returns
- Type of Collider2D
Implemented in TileCollider< T >.
virtual bool IsUpdateCollider |
( |
Collider2D |
collider, |
|
|
Vector2 |
cellPos |
|
) |
| |
|
virtual |
Determines whether the need to update the collider In the inherited class, to determine the change of property to each other as needed.
- Parameters
-
collider | Collider |
cellPos | Cell position |
- Returns
- If you need update true
Collider2D UpdateCollider |
( |
Collider2D |
collider, |
|
|
GameObject |
colliderObject, |
|
|
Vector2 |
pos, |
|
|
bool |
isCellObject, |
|
|
out bool |
changed |
|
) |
| |
To update the Collider
- Parameters
-
collider | Current Collider |
colliderObject | GameObject to attach a Collider |
pos | Position |
isCellObject | Whether CellObject |
changed | Whether changed |
- Returns
- Updated Collider
virtual bool UpdateColliderProperty |
( |
Collider2D |
collider | ) |
|
|
protectedvirtual |
Method to update the property of Collider2D.
Thing in the inherited class to describe the process of updating the property as needed here.
- Parameters
-
- Returns
- Whether the update
Whether to combine Collider
bool isSplitMapCollider = true |
Is Trigger be set to Collider.
Vector2 offset = Vector2.zero |
Offset in the case where the center of the tile is set to 0
PhysicsMaterial2D physicsMaterial |
PhysicsMaterial2D be set to Collider.
It is associated with tile