public OpenPatricianSlider(int width) { values = new SimpleListProperty<>(this, "options", FXCollections.observableList(new ArrayList<String>())); initialWidth = new SimpleIntegerProperty(this,"initialWidth", width); selectedIndex = new SimpleIntegerProperty(this, "selectedIndex", -1); this.getStyleClass().add(this.getClass().getSimpleName()); }
speed.getStyleClass().add("defaultTextSize24"); speed.setValues(gameOptions.getGameSpeedList()); int index = 0;
difficulty.getStyleClass().addAll("defaultTextSize24"); difficulty.setValues(getDificutlyList()); difficulty.selectedIndexProperty().setValue(0); speed.getStyleClass().addAll("defaultTextSize24"); speed.setValues(gameOptions.getGameSpeedList()); speed.selectedIndexProperty().setValue(1);