@Override
	public void run(){
		while(true){
			try {
				Thread.sleep(100);
			} catch (InterruptedException e) {
				e.printStackTrace();
			}
			if(!ConnectFourGui.frame.playerRed && ran){
				try {
					Thread.sleep(100);
				} catch (InterruptedException e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
				ran = false;

				Board startingBoard = ConnectFourGui.frame.getBoard();

				int columnToPlay = -1;
				double highest = -2.0;
				double score;
				for(int column:startingBoard.getPossibleMoves()){
					System.out.println(column);
					//System.out.println(startingBoard.monteCarlo(column, "B", 1000));
					score = startingBoard.monteCarlo(column, "B", 100);
					if(score>highest){
						highest = score;
						columnToPlay = column;
					}

				}
				frame.makeMove(columnToPlay, "B");
				try {
					rt.exec("cmd.exe /C echo " + new Character((char) 11));
				} catch (IOException e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
				




			}
			else if(ConnectFourGui.frame.playerRed){
				ran = true;
			}
		}
	}