Exemplo n.º 1
0
    public override void PerformCommand()
    {
        base.PerformCommand();
        GameObject currentRoad = GetRoadFromAngle(transform.rotation.eulerAngles.y);

        GetComponent <GoCommand>().Roads.Remove(currentRoad);
        if (Roads.Contains(currentRoad))
        {
            return;
        }
        Roads.Add(currentRoad);

        if (GetComponent <GoCommand> ())
        {
            GetComponent <GoCommand> ().ResetCommand();
        }
        this.TransformCommand();
    }
Exemplo n.º 2
0
 public Boolean HasRoad(HexDirection direction)
 {
     return(Roads != null && Roads.Contains(direction));
 }