String vegName = this.scenarioEditor.getSelectedVegetation();
VegetationData vegetation = new VegetationData(
this.registry, vegName);
if (paintSize.equals(SMALL_PAINT_SIZE)) {
//mode for painting one field
VegetationChange fieldChange = new VegetationChange(
field, height, vegetation, this.map);
fieldChange.execute();
} else if (paintSize.equals(BIG_PAINT_SIZE)) {
//mode for painting nine fields
Field[] neighbours = Game.getMapData().getNeighborFields(field);
for (int i = 0; i < neighbours.length; i++) {
if (neighbours[i] != null) {
VegetationChange fieldChange =
new VegetationChange(neighbours[i], height,
vegetation, this.map);
fieldChange.execute();
}
}
VegetationChange fieldChange = new VegetationChange(
field, height, vegetation, this.map);
fieldChange.execute();
}
} catch (RulesetException rse) {
CivQuest.showErrorQuitDialog("There was an error related to "
+ "ruleset-loading: ", rse);
}