mirror of
https://github.com/trainerlord/WorldSystem.git
synced 2024-09-29 04:27:32 +02:00
Copy the files correctly
This commit is contained in:
parent
68b69e2548
commit
d303be4f82
@ -37,7 +37,7 @@ public class WorldSystem extends JavaPlugin {
|
|||||||
private CreatorAdapter creator;
|
private CreatorAdapter creator;
|
||||||
|
|
||||||
public static void createConfigs() {
|
public static void createConfigs() {
|
||||||
File folder = JavaPlugin.getPlugin(WorldSystem.class).getDataFolder();
|
File folder = getInstance().getDataFolder();
|
||||||
File dir = new File(folder + "/worldsources");
|
File dir = new File(folder + "/worldsources");
|
||||||
File config = new File(folder, "config.yml");
|
File config = new File(folder, "config.yml");
|
||||||
File dconfig = new File(folder, "dependence.yml");
|
File dconfig = new File(folder, "dependence.yml");
|
||||||
|
@ -45,8 +45,8 @@ public class MessageConfig {
|
|||||||
|
|
||||||
if (in == null) {
|
if (in == null) {
|
||||||
in = JavaPlugin.getPlugin(WorldSystem.class).getResource("custom.yml");
|
in = JavaPlugin.getPlugin(WorldSystem.class).getResource("custom.yml");
|
||||||
Files.copy(in, file.toPath());
|
|
||||||
}
|
}
|
||||||
|
Files.copy(in, file.toPath());
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
System.err.println("Wasn't able to create Message file");
|
System.err.println("Wasn't able to create Message file");
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
|
Loading…
Reference in New Issue
Block a user