public void PlacePiece(Piece piece) { Debug.Log(board); board.PlacePiece(piece); StrategyGame.Instance.Pieces.Add(piece); MoveGeneration.GenerateMoves(StrategyGame.Instance.Pieces); }
public void MovePiece(Move move) { // Check if this is going to trigger a capture if (move.Capture) { // A capture event occurs and we switch over to the Action phase MasterGame.Instance.CaptureAttempted.Invoke(move); } else { board.MovePiece(move); MoveGeneration.GenerateMoves(StrategyGame.Instance.Pieces); Debug.Log("================== Moves Generated =================="); Debug.Log("Moves:"); foreach (var m in StrategyGame.Instance.Pieces[2].Moves) { Debug.Log("Move: " + m.From + " - " + m.To); } } }