Add UltraPermission warning to mcMMO

This commit is contained in:
nossr50 2021-03-18 13:18:30 -07:00
parent 13a2d03444
commit 4f08c69557
2 changed files with 16 additions and 1 deletions

View File

@ -4,7 +4,8 @@ Version 2.1.182
Fixed several errors in de locale (Thanks TheBusyBiscuit & w1tcherrr) Fixed several errors in de locale (Thanks TheBusyBiscuit & w1tcherrr)
Fixed a bug where double smelt never succeeded if the furnace was empty Fixed a bug where double smelt never succeeded if the furnace was empty
Added some safety so that mcMMO automatic save interval is never more frequent than 1 minute Added some safety so that mcMMO automatic save interval is never more frequent than 1 minute
Removed a few "silent" exceptions for scoreboards & mcMMO Removed a few silent exceptions for scoreboards & mcMMO
Added warning about UltraPermissions to mcMMO
Version 2.1.181 Version 2.1.181
mcMMO no longer pointlessly tries to check for missing UUIDs for FlatFile database mcMMO no longer pointlessly tries to check for missing UUIDs for FlatFile database

View File

@ -74,6 +74,10 @@ import java.util.ArrayList;
import java.util.List; import java.util.List;
public class mcMMO extends JavaPlugin { public class mcMMO extends JavaPlugin {
public static final String ULTRA_PERMISSONS = "UltraPermissons";
public static final String UP_WARNING_2 = "Stop using " + ULTRA_PERMISSONS + " with mcMMO immediately!";
public static final String UP_WARNING_1 = "mcMMO has detected " + ULTRA_PERMISSONS + " on your server, users have reported a severe plugin conflict between these two plugins which severely degrades server performance";
public static final String UP_WARNING_3 = "The author of UltraPermissions has passed away and its unlikely this issue will ever be solved";
/* Managers */ /* Managers */
private static PlatformManager platformManager; private static PlatformManager platformManager;
private static ChunkManager placeStore; private static ChunkManager placeStore;
@ -273,7 +277,17 @@ public class mcMMO extends JavaPlugin {
// getLogger().severe("mcMMO has detected ChatControlRed on your server, users have reported a severe plugin conflict between these two plugins which degrades server performance and wastes many server resources."); // getLogger().severe("mcMMO has detected ChatControlRed on your server, users have reported a severe plugin conflict between these two plugins which degrades server performance and wastes many server resources.");
// getLogger().severe("It is HIGHLY RECOMMENDED that you do --NOT-- use ChatControlRed until this issue is resolved!"); // getLogger().severe("It is HIGHLY RECOMMENDED that you do --NOT-- use ChatControlRed until this issue is resolved!");
// } // }
if(pluginManager.getPlugin(ULTRA_PERMISSONS) != null) {
Bukkit.getScheduler().runTaskTimer(this, () -> {
getLogger().severe(UP_WARNING_1);
getLogger().severe(UP_WARNING_2);
getLogger().severe(UP_WARNING_3);
Bukkit.broadcastMessage(UP_WARNING_1);
Bukkit.broadcastMessage(UP_WARNING_2);
Bukkit.broadcastMessage(UP_WARNING_3);
}, 0L, 1200L);
}
} }
catch (Throwable t) { catch (Throwable t) {
getLogger().severe("There was an error while enabling mcMMO!"); getLogger().severe("There was an error while enabling mcMMO!");