public void copyFromJar(String name) { File configFile = new File(sdl.getStoragePath(), name + ".yml"); if (!configFile.exists()) { configFile.getParentFile().mkdirs(); sdl.getFileTools() .copyFileFromJar(name + ".yml", sdl.getStoragePath() + File.separator + name + ".yml"); } }
public void registerFileConfiguration(String file) { File configFile = new File(sdl.getStoragePath(), file + ".yml"); checkFile(configFile); FileConfiguration fileConfiguration = new FileConfiguration(sdl, configFile); fileConfiguration.load(); configs.put(file, fileConfiguration); }