This commit is contained in:
libraryaddict 2020-02-03 20:32:21 +13:00
parent 5410e8dd04
commit 1874544721
No known key found for this signature in database
GPG Key ID: 052E4FBCD257AEA4
2 changed files with 6 additions and 3 deletions

View File

@ -14,13 +14,13 @@ import me.libraryaddict.disguise.disguisetypes.PlayerDisguise;
import me.libraryaddict.disguise.disguisetypes.TargetedDisguise; import me.libraryaddict.disguise.disguisetypes.TargetedDisguise;
import me.libraryaddict.disguise.disguisetypes.watchers.LivingWatcher; import me.libraryaddict.disguise.disguisetypes.watchers.LivingWatcher;
import me.libraryaddict.disguise.utilities.DisguiseUtilities; import me.libraryaddict.disguise.utilities.DisguiseUtilities;
import me.libraryaddict.disguise.utilities.LibsPremium;
import me.libraryaddict.disguise.utilities.UpdateChecker; import me.libraryaddict.disguise.utilities.UpdateChecker;
import me.libraryaddict.disguise.utilities.parser.DisguiseParseException; import me.libraryaddict.disguise.utilities.parser.DisguiseParseException;
import me.libraryaddict.disguise.utilities.parser.DisguiseParser; import me.libraryaddict.disguise.utilities.parser.DisguiseParser;
import me.libraryaddict.disguise.utilities.parser.DisguisePerm; import me.libraryaddict.disguise.utilities.parser.DisguisePerm;
import me.libraryaddict.disguise.utilities.parser.DisguisePermissions; import me.libraryaddict.disguise.utilities.parser.DisguisePermissions;
import me.libraryaddict.disguise.utilities.translations.LibsMsg; import me.libraryaddict.disguise.utilities.translations.LibsMsg;
import net.md_5.bungee.api.ChatMessageType;
import org.bukkit.Bukkit; import org.bukkit.Bukkit;
import org.bukkit.Location; import org.bukkit.Location;
import org.bukkit.World; import org.bukkit.World;
@ -66,6 +66,11 @@ public class DisguiseListener implements Listener {
runUpdateScheduler(); runUpdateScheduler();
if (!LibsPremium.getPluginInformation().isPremium() ||
LibsPremium.getPluginInformation().getUserID().matches("[0-9]")) {
Bukkit.getPluginManager().registerEvents(this, plugin);
}
if (!DisguiseConfig.isSaveEntityDisguises()) if (!DisguiseConfig.isSaveEntityDisguises())
return; return;

View File

@ -90,8 +90,6 @@ public class LibsDisguises extends JavaPlugin {
listener = new DisguiseListener(this); listener = new DisguiseListener(this);
Bukkit.getPluginManager().registerEvents(listener, this);
if (!DisguiseConfig.isDisableCommands()) { if (!DisguiseConfig.isDisableCommands()) {
registerCommand("disguise", new DisguiseCommand()); registerCommand("disguise", new DisguiseCommand());
registerCommand("undisguise", new UndisguiseCommand()); registerCommand("undisguise", new UndisguiseCommand());