Ejemplo n.º 1
0
 public void BrickDestroyed(GridCellCoords c)
 {
     try
     {
         this.grid[c.x, c.y].HasBrick = false;
     }
     catch (KeyNotFoundException e)
     {
     #if UNITY_EDITOR
         Debug.LogError("No such index.");
         Debug.LogError(e.Message);
         return;
     #else
         GameObject.Find("MainHelper").GetComponent<MainHelper>().GetCurrentGame().PauseGame();
         InterfaceUpdateEventArgs ev = new InterfaceUpdateEventArgs(InterfaceUpdateReasons.ExceptionThrown, "No such index.", e);
         EventSystem.FireInterfaceUpdate(this, ev);
     #endif
     }
     finally
     {
         --this.totalBricks;
     }
 }
Ejemplo n.º 2
0
    public void BrickDestroyed(GridCellCoords c)
    {
        try
        {
            this.grid[c.x, c.y].HasBrick = false;
        }
        catch (KeyNotFoundException e)
        {
#if UNITY_EDITOR
            Debug.LogError("No such index.");
            Debug.LogError(e.Message);
            return;
#else
            GameObject.Find("MainHelper").GetComponent <MainHelper>().GetCurrentGame().PauseGame();
            InterfaceUpdateEventArgs ev = new InterfaceUpdateEventArgs(InterfaceUpdateReasons.ExceptionThrown, "No such index.", e);
            EventSystem.FireInterfaceUpdate(this, ev);
#endif
        }
        finally
        {
            --this.totalBricks;
        }
    }
Ejemplo n.º 3
0
 public void SetCoordinates(GridCellCoords c)
 {
     this.coordinates.x = c.x;
     this.coordinates.y = c.y;
 }
Ejemplo n.º 4
0
 public void SetCoordinates(GridCellCoords c)
 {
     this.coordinates.x = c.x;
     this.coordinates.y = c.y;
 }