mirror of
https://github.com/Steffo99/octogem.git
synced 2024-11-22 13:04:19 +00:00
23 lines
No EOL
649 B
C#
23 lines
No EOL
649 B
C#
using UnityEngine;
|
|
|
|
public class TilePosition : GenericPosition
|
|
{
|
|
public override MapPosition Position
|
|
{
|
|
get { return position; }
|
|
|
|
set
|
|
{
|
|
position = value;
|
|
if (Debug.isDebugBuild)
|
|
{
|
|
//Check if the tile is in the expected position
|
|
Vector3 expectedPosition = new Vector3(position.x, position.y);
|
|
if (transform.position != expectedPosition)
|
|
{
|
|
Debug.LogWarningFormat("{0}'s TilePosition is mismatched with its transform position.", gameObject.name);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} |