public void actionPerformed(FunctionActionEvent e) {
Point position = e.getPosition();
if (position != null) {
Field field = quadMap.getFieldAtPosition(position);
if (field != null) {
GameDataAccessor gameData = quadMap.getGameData();
CityReader cityReader = gameData.getCityReader();
if (cityReader.isCityIDAvailable(field.getPosition())
&& cityReader.getCityID(field.getPosition()) != null) {
Messages messages = Messages.getMessages();
messages.info("ConstructTestCityAction", "CityAR",
"You can't build more than one city on a field!");
} else {
Nation activeNation = Game.getGame().getActiveNation();
if (activeNation != null) {
ConstructCity newCityChange
= new ConstructCity(field.getPosition(),
Game.getGame().getActiveNation());
newCityChange.execute();
SetPopulation setPopulation
= new SetPopulation(field.getPosition(), 1000);
setPopulation.execute();
SetFieldRuledByCity change
= new SetFieldRuledByCity(field.getPosition(),
newCityChange.getCity(),
false);
change.execute();
} else {
Messages.getMessages().info("ConstructTestCity", "QMapWarn",