This commit is contained in:
HaHaWTH 2023-12-31 17:34:42 +08:00
parent 01f4a8f205
commit 222bd879d1
2 changed files with 4 additions and 2 deletions

View File

@ -360,8 +360,10 @@ public class AuthMe extends JavaPlugin {
if (settings.getProperty(SecuritySettings.ANTI_GHOST_PLAYERS)) {
pluginManager.registerEvents(injector.getSingleton(DoubleLoginFixListener.class), this);
}
if (settings.getProperty(SecuritySettings.ADVANCED_SHULKER_FIX)) {
if (settings.getProperty(SecuritySettings.ADVANCED_SHULKER_FIX) && !isClassLoaded("org.bukkit.event.player.PlayerCommandSendEvent")) {
pluginManager.registerEvents(injector.getSingleton(AdvancedShulkerFixListener.class), this);
} else if (settings.getProperty(SecuritySettings.ADVANCED_SHULKER_FIX) && isClassLoaded("org.bukkit.event.player.PlayerCommandSendEvent")) {
logger.warning("You are running an 1.13+ minecraft server, advancedShulkerFix won't enable.");
}
}

View File

@ -38,7 +38,7 @@ public final class SecuritySettings implements SettingsHolder {
@Comment({"(MC1.13- only)",
"Should we fix the shulker crash bug with advanced method?"})
public static final Property<Boolean> ADVANCED_SHULKER_FIX =
newProperty("3rdPartyFeature.fixes.advancedShulkerFix", false);
newProperty("3rdPartyFeature.fixes.advancedShulkerFix", true);
@Comment({"Choose the best teleport method by server brand?",
"(Enable this if you are using Paper)"})