Exemple #1
0
        public void OnPostionChanged(Vector3 newPostion)
        {
            Vector2  boardPostion = positonConverter.ConvertScenePositionToBoard(newPostion);
            GameCell gameCell     = board.GetGameCell(boardPostion);

            if (gameCell.Equals(currentCell))
            {
                return;
            }
            if (currentCell != null)
            {
                currentCell.RemovePlayer(player);
            }
            currentCell = gameCell;
            gameCell.AddPlayer(player);
        }