45 lines
937 B
C#

using UnityEngine;
using System.Collections.Generic;
[System.Serializable]
public class PlayerPlacementData
{
public PlayerPawn pawn;
}
[System.Serializable]
public class PlayerTileData
{
public int playerCount;
public Transform commonPlacementTransform;
public Dictionary<int, PlayerPawn> playerPawns;
}
public class Tile : MonoBehaviour
{
[SerializeField] protected bool isSafeZone = false;
[SerializeField] protected Transform centeredPoint;
public bool IsSafeZone => isSafeZone;
public Vector3 CenterPlacementPosition => centeredPoint.position;
protected int lastOccupiedIndex = 0;
public PlayerPawn PlayerPawn // Change implementation
{
get; private set;
}
public virtual void InitPlayerPawn(PlayerPawn playerPawn, PlayerType playerType)
{
PlayerPawn = playerPawn;
}
public void ResetPlayerPawn()
{
PlayerPawn = null;
}
}