Save vanilla from jar

This commit is contained in:
NuclearW 2012-05-21 23:07:32 -04:00
parent 20b169e8eb
commit e89b3795f8

View File

@ -14,6 +14,12 @@ public class RepairConfigManager {
public RepairConfigManager(mcMMO plugin) { public RepairConfigManager(mcMMO plugin) {
Pattern pattern = Pattern.compile("repair\\.(?:.+)\\.yml"); Pattern pattern = Pattern.compile("repair\\.(?:.+)\\.yml");
File dataFolder = plugin.getDataFolder(); File dataFolder = plugin.getDataFolder();
File vanilla = new File(dataFolder, "repair.vanilla.yml");
if(!vanilla.exists()) {
plugin.saveResource("repair.vanilla.yml", false);
}
for(String location : dataFolder.list()) { for(String location : dataFolder.list()) {
if(!pattern.matcher(location).matches()) continue; if(!pattern.matcher(location).matches()) continue;