Depcrecate the regions plugins (add warnings, disable when replacement plugins are active). Remove example configuration.txt entries.
This commit is contained in:
parent
0a790b6014
commit
54589cd358
3 changed files with 27 additions and 128 deletions
|
|
@ -9,17 +9,23 @@ import java.util.Map;
|
|||
import org.json.simple.JSONArray;
|
||||
import org.json.simple.JSONObject;
|
||||
public class ClientComponent extends Component {
|
||||
|
||||
private boolean disabled;
|
||||
|
||||
public ClientComponent(final DynmapPlugin plugin, final ConfigurationNode configuration) {
|
||||
super(plugin, configuration);
|
||||
plugin.events.addListener("buildclientconfiguration", new Event.Listener<JSONObject>() {
|
||||
@Override
|
||||
public void triggered(JSONObject root) {
|
||||
buildClientConfiguration(root);
|
||||
if(!disabled)
|
||||
buildClientConfiguration(root);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
protected void disableComponent() {
|
||||
disabled = true;
|
||||
}
|
||||
|
||||
protected void buildClientConfiguration(JSONObject root) {
|
||||
JSONObject o = createClientConfiguration();
|
||||
a(root, "components", o);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue