diff --git a/Essentials/src/com/earth2me/essentials/Warps.java b/Essentials/src/com/earth2me/essentials/Warps.java index a78393598..4aed8213a 100644 --- a/Essentials/src/com/earth2me/essentials/Warps.java +++ b/Essentials/src/com/earth2me/essentials/Warps.java @@ -6,6 +6,7 @@ import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.logging.Level; import java.util.logging.Logger; import org.bukkit.Location; import org.bukkit.Server; @@ -99,12 +100,19 @@ public class Warps implements IConf String filename = listOfFiles[i].getName(); if (listOfFiles[i].isFile() && filename.endsWith(".yml")) { - EssentialsConf conf = new EssentialsConf(listOfFiles[i]); - conf.load(); - String name = conf.getString("name"); - if (name != null) + try { - warpPoints.put(new StringIgnoreCase(name), conf); + EssentialsConf conf = new EssentialsConf(listOfFiles[i]); + conf.load(); + String name = conf.getString("name"); + if (name != null) + { + warpPoints.put(new StringIgnoreCase(name), conf); + } + } + catch (Exception ex) + { + logger.log(Level.WARNING, Util.format("loadWarpError", filename), ex); } } } diff --git a/Essentials/src/messages.properties b/Essentials/src/messages.properties index 5cb4a4639..ce1542f5f 100644 --- a/Essentials/src/messages.properties +++ b/Essentials/src/messages.properties @@ -303,4 +303,5 @@ ignorePlayer = You ignore player {0} from now on. illegalDate = Illegal date format. timePattern = (?:([0-9]+)\\s*y[a-z]*[,\\s]*)?(?:([0-9]+)\\s*mo[a-z]*[,\\s]*)?(?:([0-9]+)\\s*w[a-z]*[,\\s]*)?(?:([0-9]+)\\s*d[a-z]*[,\\s]*)?(?:([0-9]+)\\s*h[a-z]*[,\\s]*)?(?:([0-9]+)\\s*m[a-z]*[,\\s]*)?(?:([0-9]+)\\s*(?:s[a-z]*)?)? msgFormat = \u00a77[{0}\u00a77 -> {1}\u00a77] \u00a7f{2} -kits = \u00a77Kits: {0} \ No newline at end of file +kits = \u00a77Kits: {0} +loadWarpError = Failed to load warp {0} \ No newline at end of file diff --git a/Essentials/src/messages_de.properties b/Essentials/src/messages_de.properties index 9399a7398..9e0c12048 100644 --- a/Essentials/src/messages_de.properties +++ b/Essentials/src/messages_de.properties @@ -303,4 +303,5 @@ ignorePlayer = Du ignorierst ab jetzt Spieler {0}. illegalDate = Ung\u00fcltiges Datumsformat. timePattern = (?:([0-9]+)\\s*[yj][a-z]*[,\\s]*)?(?:([0-9]+)\\s*mo[a-z]*[,\\s]*)?(?:([0-9]+)\\s*w[a-z]*[,\\s]*)?(?:([0-9]+)\\s*[dt][a-z]*[,\\s]*)?(?:([0-9]+)\\s*(?:h|st)[a-z]*[,\\s]*)?(?:([0-9]+)\\s*m[a-z]*[,\\s]*)?(?:([0-9]+)\\s*(?:s[a-z]*)?)? msgFormat = \u00a77[{0}\u00a77 -> {1}\u00a77] \u00a7f{2} -kits = \u00a77Ausr\u00fcstungen: {0} \ No newline at end of file +kits = \u00a77Ausr\u00fcstungen: {0} +loadWarpError = Fehler beim Laden von Warp-Punkt {0} \ No newline at end of file diff --git a/Essentials/src/messages_en.properties b/Essentials/src/messages_en.properties index 5cb4a4639..ce1542f5f 100644 --- a/Essentials/src/messages_en.properties +++ b/Essentials/src/messages_en.properties @@ -303,4 +303,5 @@ ignorePlayer = You ignore player {0} from now on. illegalDate = Illegal date format. timePattern = (?:([0-9]+)\\s*y[a-z]*[,\\s]*)?(?:([0-9]+)\\s*mo[a-z]*[,\\s]*)?(?:([0-9]+)\\s*w[a-z]*[,\\s]*)?(?:([0-9]+)\\s*d[a-z]*[,\\s]*)?(?:([0-9]+)\\s*h[a-z]*[,\\s]*)?(?:([0-9]+)\\s*m[a-z]*[,\\s]*)?(?:([0-9]+)\\s*(?:s[a-z]*)?)? msgFormat = \u00a77[{0}\u00a77 -> {1}\u00a77] \u00a7f{2} -kits = \u00a77Kits: {0} \ No newline at end of file +kits = \u00a77Kits: {0} +loadWarpError = Failed to load warp {0} \ No newline at end of file