/// <summary>
        /// Checks if at least one piece can block the path or eliminate the piece checking the king - if in check
        /// Or
        /// Checks to see if the opponent can play a move - for stalemate condition
        /// </summary>
        /// <returns> True if checkmate/stalemate </returns>
        static bool CheckmateStalemate(int colour, BoardInformation boardInfo)
        {
            foreach (GameObject pieceOnBoard in boardInfo.GetPieceAvailable())
            {
                PieceInformation pieceOnBoardInfo = pieceOnBoard.GetComponent <PieceInformation>();

                // skip if not opponent's piece
                if ((int)pieceOnBoardInfo.colour == colour)
                {
                    continue;
                }

                pieceOnBoardInfo.GetMoves();
                List <string> allowedPositions = pieceOnBoardInfo.GetPossibleMoves();

                // Break out early if at least one piece can be moved
                if (allowedPositions.Count != 0)
                {
                    string spots = "";
                    for (int i = 0; i < allowedPositions.Count; i++)
                    {
                        spots += allowedPositions[i] + " ";
                    }
                    return(false);
                }
            }

            return(true);
        }
        /// <summary>
        /// Highlights tiles that this piece can move to
        /// Used by Interactable script events
        /// </summary>
        public void TilesOn()
        {
            //Look for possible moves
            pi.GetMoves();
            possibleMoves = pi.GetPossibleMoves();

            if (possibleMoves == null || bi.GetTurn() != (int)pi.colour)
            {
                return;
            }

            //Swap the corresponding tiles with highlighted version
            foreach (string item in possibleMoves)
            {
                int        x    = (int)char.GetNumericValue(item[0]);
                int        z    = (int)char.GetNumericValue(item[2]);
                GameObject tile = chessboard.transform.GetChild(z).gameObject.transform.GetChild(x).gameObject;
                activeTiles.Add(tile);

                tile.GetComponent <ActivateHighlight>().HighlightOn();
            }
        }