private void playerDeath(BoardAction a)
        {
            BombermanVisualObj player = currentGameObjects.Find(x => x.ID == a.targetID);

            (player as VisualPlayer).death();
            currentGameObjects.Remove(player);
        }
        private void explodeBomb(BoardAction a)
        {
            BombermanVisualObj bomb = currentGameObjects.Find(x => x.ID == a.targetID);

            (bomb as VisualBomb).explodeBomb();
            currentGameObjects.Remove(bomb);
        }
        private void spawnBomb(BoardAction a)
        {
            GameObject temp = Instantiate(bombPrefab, Vector3.zero, Quaternion.identity, mapObjectsParent);

            temp.transform.localPosition = BombermanOverlord.FArrayToVec(a.pos);
            VisualBomb bomb = temp.GetComponent <VisualBomb> ();

            bomb.initBomb(a.targetID, 0, 0, explosionPrefab);
            currentGameObjects.Add(bomb as BombermanVisualObj);
        }
        public void placeBomb()
        {
            if (GameBoard.validCoord(currentCoord [0], currentCoord [1]) == false)
            {
                return;
            }
            if (bombsLeft == 0)
            {
                return;
            }

            Bomb temp = Instantiate(bombPrefab, GameBoard.getGridPos(currentCoord [0], currentCoord [1]), Quaternion.identity, transform.parent).GetComponent <Bomb> ();

            temp.init(3, 3, currentCoord, this);

            BoardAction dropAction = new BoardAction(ActionType.BombSpawn, temp.ID, BombermanOverlord.vecToFlArray(temp.transform.localPosition));

            BombermanGameStateUpdater.addNewAction(dropAction);
            bombsLeft--;
        }
 public static void addNewAction(BoardAction newAction)
 {
     singleton.roundActions.Add(newAction);
 }