public static int getRegimeOfGame(){
        Scanner scanner = new Scanner(System.in);
        int regimeOfGame = 0;
        System.out.println("Please choose regime of game:");
        System.out.println("1 - Two players on one computer");
        System.out.println("2 - Player vs computer");
        System.out.println("3 - Two players using internet");
        while (true){
            if(scanner.hasNextInt()) {
                regimeOfGame = scanner.nextInt();
                if(regimeOfGame == Game.getOnePlayerGameRegime() || regimeOfGame == Game.getTwoPlayersGameRegime() || regimeOfGame == Game.getTwoPlayersOnlineGameRegime()){
                    return regimeOfGame;
                } else {
                    System.out.println("Wrong data, please try again");
                }

        }
    }
    }