110111112113114115116117118
if (data.players.get(i).getName() == name) { System.out.println("Player with that name already exists"); return; } } data.players.add((new SettlerPlayerData(name))); System.out.println("Player " + name + " added."); } }