|
|
@ -105,6 +105,7 @@ public class WorldController { |
|
|
|
} |
|
|
|
|
|
|
|
public void copyWorld(World world) { |
|
|
|
world.save(); |
|
|
|
copyFileStructure(world.getWorldFolder(), new File(plugin.getDataFolder() + "/maps/" + world.getName())); |
|
|
|
} |
|
|
|
|
|
|
@ -121,7 +122,7 @@ public class WorldController { |
|
|
|
world.setAnimalSpawnLimit(0); |
|
|
|
world.setAmbientSpawnLimit(0); |
|
|
|
world.setGameRuleValue("doDaylightCycle", "false"); |
|
|
|
Bukkit.getServer().getConsoleSender().sendMessage(ChatColor.GREEN + "Se ha reiniciado el mapa " + ChatColor.YELLOW + newWorldName + ChatColor.GREEN + "."); |
|
|
|
Bukkit.getServer().getConsoleSender().sendMessage(ChatColor.GREEN + "Restarting map " + ChatColor.YELLOW + newWorldName + ChatColor.GREEN + "."); |
|
|
|
} |
|
|
|
|
|
|
|
protected void copyFileStructure(File source, File target) { |
|
|
|