mirror of
https://github.com/PlayPro/CoreProtect.git
synced 2024-11-28 12:55:34 +01:00
Added hidden "enable-awe" option for AWE logging (default: false)
This commit is contained in:
parent
2fa5af64ca
commit
7bc95931d2
@ -41,6 +41,7 @@ public class Config extends Language {
|
||||
public String MYSQL_USERNAME;
|
||||
public String MYSQL_PASSWORD;
|
||||
public String LANGUAGE;
|
||||
public boolean ENABLE_AWE;
|
||||
public boolean HOVER_EVENTS;
|
||||
public boolean DATABASE_LOCK;
|
||||
public boolean LOG_CANCELLED_CHAT;
|
||||
@ -179,6 +180,7 @@ public class Config extends Language {
|
||||
}
|
||||
|
||||
private void readValues() {
|
||||
this.ENABLE_AWE = this.getBoolean("enable-awe", false);
|
||||
this.HOVER_EVENTS = this.getBoolean("hover-events", true);
|
||||
this.DATABASE_LOCK = this.getBoolean("database-lock", true);
|
||||
this.LOG_CANCELLED_CHAT = this.getBoolean("log-cancelled-chat", true);
|
||||
|
@ -10,6 +10,7 @@ import com.sk89q.worldedit.util.eventbus.Subscribe;
|
||||
import com.sk89q.worldedit.world.World;
|
||||
|
||||
import net.coreprotect.CoreProtect;
|
||||
import net.coreprotect.config.Config;
|
||||
import net.coreprotect.config.ConfigHandler;
|
||||
import net.coreprotect.language.Phrase;
|
||||
import net.coreprotect.language.Selector;
|
||||
@ -31,7 +32,7 @@ public class CoreProtectEditSessionEvent {
|
||||
}
|
||||
|
||||
try {
|
||||
if (Bukkit.getServer().getPluginManager().getPlugin("AsyncWorldEdit") == null) {
|
||||
if (Bukkit.getServer().getPluginManager().getPlugin("AsyncWorldEdit") == null || Config.getGlobal().ENABLE_AWE) {
|
||||
WorldEdit.getInstance().getEventBus().register(event);
|
||||
initialized = true;
|
||||
ConfigHandler.worldeditEnabled = true;
|
||||
|
Loading…
Reference in New Issue
Block a user