Made configuration structure of worlds like templates (looks nicer :D).
This commit is contained in:
parent
38dd39d75f
commit
cee491f610
2 changed files with 9 additions and 11 deletions
|
|
@ -406,12 +406,10 @@ public class DynmapPlugin extends JavaPlugin {
|
|||
}
|
||||
|
||||
private ConfigurationNode getWorldConfigurationNode(String worldName) {
|
||||
for(ConfigurationNode worldNode : configuration.getNodes("worlds")) {
|
||||
if (worldName.equals(worldNode.getString("name"))) {
|
||||
return worldNode;
|
||||
}
|
||||
}
|
||||
return new ConfigurationNode();
|
||||
ConfigurationNode result = configuration.getNode("worlds").getNode(worldName);
|
||||
if (result == null)
|
||||
return new ConfigurationNode();
|
||||
return result;
|
||||
}
|
||||
|
||||
private ConfigurationNode getTemplateConfigurationNode(String templateName) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue