Changed data-yml format

master
Ruakij 4 years ago
parent b8ed619b1c
commit 1168b8859a

@ -44,16 +44,15 @@ public class LinkedBeaconTeleporterManager {
// New list for this id
List<LinkedBeaconTeleporter> linkedBeaconTeleporters = new ArrayList();
for(String blockId : teleportersData.getKeys(false)) {
ConfigurationSection teleporterData = teleportersData.getConfigurationSection(blockId);
for(String serializedLoc : teleportersData.getKeys(false)) {
ConfigurationSection teleporterData = teleportersData.getConfigurationSection(serializedLoc);
// Load location
String serializedLoc = teleporterData.getString("loc");
Location loc;
try {
loc = Function.deserializeBlockLocation(teleporterData.getString("loc"));
} catch (InvalidPropertiesFormatException e) {
Main.log.severe("Could not load location='"+ serializedLoc +"' from "+ teleporterId +" > "+ blockId);
Main.log.severe("Could not load location='"+ serializedLoc +"' from "+ teleporterId);
continue;
}
@ -61,7 +60,7 @@ public class LinkedBeaconTeleporterManager {
Block block = loc.getBlock();
if(block.getType() != Material.BEACON){
// Data out of sync! Skipping
Main.log.warning(teleporterId +" > "+ blockId +" at location "+ serializedLoc +" changed and is no longer LinkedBlockTeleporter! (Changed without the plugin running?)");
Main.log.warning(teleporterId +" at location "+ serializedLoc +" changed and is no longer LinkedBlockTeleporter! (Changed without the plugin running?)");
continue;
}

Loading…
Cancel
Save