SpaceConfigs is a plugin that allows you to create your own Custom config files, easily, with just one line, instead of it being complicated and hard!
Creating a config:
Config c = new Config("test.yml", "Test Plugin"); //This creates a new Config variable, "test.yml" is the name of your config, you can make it anything!
//"Test Plugin" is the name of your plugin, it will be the folder name in your plugins, make this whatever you want, if you want it in the same folder as your main config file, name it exactly what your plugin name is
Now, how to set a variable!
public void onEnable() { // When the plugin is started
//c.getConfig() gets the config as a YamlConfiguartion, so you can change and get variables inside!
c.getConfig().setString("WelcomeMessage", "Hello player!"); // Sets the string "WelcomeMessage" to "Hello player!" in the config<br />c.saveConfig(); // Saves the configuration settings to the file
}
Deleting the configuration, say you want to delete the file off the server at some point in time, heres how!
if (cmd.getName().equalsIgnoreCase("confReset") { //Checks if the user typed "/confreset"
c.delete(); // Deletes the configuration, its that easy!
}
SpaceConfigs has been approved! Heres the link for SpaceConfigs!
SpaceConfigs is a plugin that allows you to create your own Custom config files, easily, with just one line, instead of it being complicated and hard!
Creating a config:
Now, how to set a variable!
Deleting the configuration, say you want to delete the file off the server at some point in time, heres how!