import java.net.SocketPermission;
import java.util.Scanner;

/**
 * Created by Panayiotis on 03/01/2016.
 */
public class PawnRace {
    public static void main(String[] args) {

        boolean isHumanPlayer1 = args[0].equals("H");
        boolean isHumanPlayer2 = args[1].equals("H");

        char whiteGap = args[2].charAt(0);
        char blackGap = args[3].charAt(0);

        Board board = new Board(whiteGap, blackGap);
        Game game = new Game(board);
        Player p1 = new Player(board, game, Color.WHITE, isHumanPlayer1);
        Player p2 = new Player(board, game, Color.BLACK, isHumanPlayer2);
        int playerTurn = 1;
        Scanner input = new Scanner(System.in);
        String moveSAN;
        Move move;
        board.display();
        while(!game.isFinished()) {

            if(playerTurn == 1) {
                if(isHumanPlayer1) {
                    
                    do {
                        System.out.println("Play your move! ");
                        moveSAN = input.next();
                    }while(!NotationUtil.validStringMove(moveSAN.toLowerCase(), Color.WHITE, board));
                    moveSAN = NotationUtil.toStandardNotation(moveSAN, Color.WHITE, board);
                    move = game.parseMove(moveSAN);
                    game.applyMove(move);

                } else {
                    //AI
                    p1.makeMove();
                }
                playerTurn = 2;

            } else {

                if(isHumanPlayer2) {

                    do {
                        System.out.println("Play your move! ");
                        moveSAN = input.next();
                    } while(!NotationUtil.validStringMove(moveSAN.toLowerCase(), Color.BLACK, board));
                    moveSAN = NotationUtil.toStandardNotation(moveSAN, Color.BLACK, board);

                    move = game.parseMove(moveSAN);
                    game.applyMove(move);

                } else {
                    //AI
                    p2.makeMove();
                }
                playerTurn = 1;

            }
            board.display();
        }
        Color winner = game.getGameResult();
        System.out.println(GameUtil.gameResults(winner));
    }
}

@@ -167,25 +167,24 @@
 g%5B%5D args) %7B%0A
-%0A
         bool
@@ -178,32 +178,245 @@
 %0A        boolean
+ isHumanPlayer1;%0A        boolean isHumanPlayer2;%0A        char whiteGap;%0A        char blackGap;%0A%0A        Scanner input = new Scanner(System.in);%0A%0A        //Game Parameters%0A        if(args.length == 4) %7B%0A           
  isHumanPlayer1 
@@ -438,39 +438,35 @@
 s(%22H%22);%0A        
-boolean
+   
  isHumanPlayer2 
@@ -489,36 +489,35 @@
 (%22H%22);%0A%0A        
-char
+   
  whiteGap = args
@@ -531,36 +531,35 @@
 rAt(0);%0A        
-char
+   
  blackGap = args
@@ -572,16 +572,488 @@
 arAt(0);
+%0A        %7D else %7B%0A            System.out.println(%22Please give the 2 player types (C - Computer, H - human) %22);%0A            isHumanPlayer1 = input.next().charAt(0) == 'H';%0A            isHumanPlayer2 = input.next().charAt(0) == 'H';%0A%0A            System.out.println(%22Please give the columns where white and black miss a pawn (A - H)%22);%0A            whiteGap = input.next().charAt(0);%0A            blackGap = input.next().charAt(0);%0A            //TO ADD validity check%0A        %7D
 %0A%0A      
@@ -1316,56 +1316,8 @@
  1;%0A
-        Scanner input = new Scanner(System.in);%0A
     

Add command line arguments within the program