src/gameplayer/menu/LevelSelector.java
public void createLevelMenu() {
		int numOfLevels = GameManager.getNumOfLevels();
		levelCount = 1;
		for (int i = 1; i<=numOfLevels; i++) {
			MenuItem currentMenu = new MenuItem("Level " + levelCount);
			currentMenu.setOnAction(e->{
			    		int level = obtainLevelInteger(currentMenu.getText());
			    		changeGameLevel.accept(level);
			});
			this.getItems().add(currentMenu);
			levelCount++;
		}
	}
/**
	 * Method that creates each MenuItem for a given file;
	 * @param
	 */
Method that creates each MenuItem for a given file;
@param
Method that creates each MenuItem for a given file ; @param
public void createLevelMenu() {
		int numOfLevels = GameManager.getNumOfLevels();
		levelCount = 1;
		for (int i = 1; i<=numOfLevels; i++) {
			MenuItem currentMenu = new MenuItem("Level " + levelCount);
			currentMenu.setOnAction(e->{
			    		int level = obtainLevelInteger(currentMenu.getText());
			    		changeGameLevel.accept(level);
			});
			this.getItems().add(currentMenu);
			levelCount++;
		}
	}
public void createLevelMenu ( ) { int numOfLevels = GameManager . getNumOfLevels ( ) ; levelCount = 1 ; for ( int i = 1 ; i <= numOfLevels ; i ++ ) { MenuItem currentMenu = new MenuItem ( "Level " + levelCount ) ; currentMenu . setOnAction ( e -> { int level = obtainLevelInteger ( currentMenu . getText ( ) ) ; changeGameLevel . accept ( level ) ; } ) ; this . getItems ( ) . add ( currentMenu ) ; levelCount ++ ; } }
Method that creates each MenuItem for a given file;
 @param
Method that creates each MenuItem for a given file ; @param