Esempio n. 1
0
    public static void SetHexagonColor(int hexagonID, ColorID colorID)
    {
        ActorHexagon target = GetHexagonActor(hexagonID);

        if (target != null)
        {
            target.SetColor(0, colorID);
        }
    }
Esempio n. 2
0
 public static void ResetGrid()
 {
     Debug.Log("Resetting grid...");
     GameObject[] hexagons = GameObject.FindGameObjectsWithTag(HexagonTag);
     foreach (GameObject h in hexagons)
     {
         ActorHexagon ah = h.GetComponentInChildren <ActorHexagon>();
         if (ah != null)
         {
             ah.SetColor(0, ColorID.white);
             ah.SetGoalColor(ColorID.white);
             ah.SetHoverColor(ColorID.white);
         }
     }
 }
Esempio n. 3
0
 public static void EnterEditMode()
 {
     State.gameActivity = GameActivity.edit;
     GameObject[] hexagons = GameObject.FindGameObjectsWithTag(HexagonTag);
     foreach (GameObject h in hexagons)
     {
         ActorHexagon ah = h.GetComponentInChildren <ActorHexagon>();
         if (ah != null)
         {
             ColorID currentGoalColor = ah.goalColor;
             ah.SetGoalColor(ColorID.white);
             ah.SetColor(0, currentGoalColor);
         }
     }
 }