private int randomNumber(){
		Random r = new Random();
		int ret = 0;
		int max = 0;
		if (gameValue == PLUSMINUS){
			max = 3 * (maxNumber-1);
		}
		if (gameValue == MULITDIV || gameValue == PLUSMINUSMULTDIV){
			max = (maxNumber-1) * (maxNumber-1) * (maxNumber-1);
		}
		for (int i=0; i < 10;  i++){
			ret = r.nextInt(max);
			log.finest("Created the new random number " + ret);
			if (controllRandomNumber(ret)){
				actualSearchedNumber = ret;
				log.finer("New randomnumber is: " + ret);
				return ret;
			}
		}
		JDialog dialog = new JDialog();
		dialog.add(new JLabel("Time for a new Game!"));
		dialog.setSize(200,200);
		dialog.setVisible(true);
		
		return ret;
	}