Example #1
0
    public void UI_SelectTile(Tile id)
    {
        Board.DeselectTiles(true, true);            //reset the tiles on the board
        if (id.State != Tile.TileStates.Border)     //make sure selected tile is not a border
        {
            id.TouchedTile();                       //activate the select hex layer
            cam.selectedTile = id.ID;

            GameObject e = AI.EnemyOnTile(id.ID);
            if (e != null)
                UIManager.setEnemyUI(e.GetComponent<Enemy>());
            else
                UIManager.hideEnemyUI();
        }
    }