From ac3b7e1c0b02b009da677145a556d7a128a9cb70 Mon Sep 17 00:00:00 2001 From: DrBot7 <46543473+DrBot7@users.noreply.github.com> Date: Sun, 10 Jan 2021 13:05:37 -0600 Subject: [PATCH 01/10] Timings - LagAssist description --- cogs/timings.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cogs/timings.py b/cogs/timings.py index 4f0c426..2d148ea 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -175,7 +175,7 @@ class Timings(commands.Cog): if "LagAssist" in plugins: embed_var.add_field(name="❌ LagAssist", value="Plugins that claim to remove lag actually cause more lag. " - "Remove LagAssist.", + "LagAssist should only be used for analytics and preventative measures. All other features should be disabled.", inline=True) if "NoChunkLag" in plugins: embed_var.add_field(name="❌ NoChunkLag", From 1916b7c44d8e2609fc43b87b4cdb50c8a04080ea Mon Sep 17 00:00:00 2001 From: DrBot7 <46543473+DrBot7@users.noreply.github.com> Date: Sun, 10 Jan 2021 13:22:00 -0600 Subject: [PATCH 02/10] Timings - Replies --- cogs/timings.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/cogs/timings.py b/cogs/timings.py index 2d148ea..80dd65e 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -24,7 +24,7 @@ class Timings(commands.Cog): embed_var.add_field(name="❌ Spigot", value="Upgrade to [Purpur](https://ci.pl3x.net/job/Purpur/).", inline=True) - await message.channel.send(embed=embed_var) + await message.reply(embed=embed_var) return if timings_url == "": return @@ -41,7 +41,7 @@ class Timings(commands.Cog): embed_var.add_field(name="❌ Invalid report", value="Create a new timings report.", inline=True) - await message.channel.send(embed=embed_var) + await message.reply(embed=embed_var) return embed_var = discord.Embed(title="Timings Analysis", color=0x55ffff) @@ -1050,13 +1050,13 @@ class Timings(commands.Cog): embed_var.add_field(name="❌ Invalid Configuration", value="At least one of your configuration files had an invalid data type.", inline=True) - await message.channel.send(embed=embed_var) + await message.reply(embed=embed_var) return if len(embed_var.fields) == 0: embed_var.add_field(name="✅ All good", value="Analyzed with no issues") - await message.channel.send(embed=embed_var) + await message.reply(embed=embed_var) return issue_count = len(embed_var.fields) @@ -1066,7 +1066,7 @@ class Timings(commands.Cog): embed_var.description = "Showing " + str(issue_count) + " of " + str(issue_count) + " recommendations." if issue_count > 0: embed_var.description = embed_var.description + "\n||" + str(unchecked) + " missing configuration optimizations due to server version.||" - await message.channel.send(embed=embed_var) + await message.reply(embed=embed_var) def setup(bot): From 6cb686ab6052a75b39c6596162dd022ed8c0ab6f Mon Sep 17 00:00:00 2001 From: DrBot7 <46543473+DrBot7@users.noreply.github.com> Date: Mon, 11 Jan 2021 00:55:22 -0600 Subject: [PATCH 03/10] Update timings.py --- cogs/timings.py | 35 +++++++++++++++++++++++++---------- 1 file changed, 25 insertions(+), 10 deletions(-) diff --git a/cogs/timings.py b/cogs/timings.py index 80dd65e..c533781 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -2,7 +2,6 @@ import discord from discord.ext import commands import requests - class Timings(commands.Cog): def __init__(self, bot): @@ -292,11 +291,29 @@ class Timings(commands.Cog): value="bPermissions is an outdated permission plugin. " "Consider replacing it with [LuckPerms](https://ci.lucko.me/job/LuckPerms/1243/artifact/bukkit/build/libs/LuckPerms-Bukkit-5.2.77.jar).", inline=True) + if "DisableJoinMessage" in plugins and "Essentials" in plugins: + embed_var.add_field(name="❌ DisableJoinMessage", + value="You probably don't need DisableJoinMessage because Essentials already has its features. ", + inline=True) for plugin in plugins: - if "Songoda" in r["timingsMaster"]["plugins"][plugin]["authors"]: - embed_var.add_field(name="❌ " + plugin, - value="This plugin was made by Songoda. You should find an alternative.", - inline=True) + if "songoda" in r["timingsMaster"]["plugins"][plugin]["authors"].casefold(): + if plugin == "EpicHeads": + embed_var.add_field(name="❌ EpicHeads", + value="This plugin was made by Songoda. Songoda resources are poorly developed and often cause problems. You should find an alternative such as [HeadsPlus](spigotmc.org/resources/headsplus-»-1-8-1-16-4.40265/) or [HeadDatabase](https://www.spigotmc.org/resources/head-database.14280/).", + inline=True) + if plugin == "EpicHeads": + embed_var.add_field(name="❌ EpicHeads", + value="This plugin was made by Songoda. Songoda resources are poorly developed and often cause problems. You should find an alternative such as [HeadsPlus](spigotmc.org/resources/headsplus-»-1-8-1-16-4.40265/) or [HeadDatabase](https://www.spigotmc.org/resources/head-database.14280/).", + inline=True) + elif plugin == "UltimateStacker": + embed_var.add_field(name="❌ UltimateStacker", + value="Stacking plugins actually cause more lag. " + "Remove UltimateStacker.", + inline=True) + else: + embed_var.add_field(name="❌ " + plugin, + value="This plugin was made by Songoda. Songoda resources are poorly developed and often cause problems. You should find an alternative.", + inline=True) except KeyError: unchecked = unchecked + 1 @@ -1060,12 +1077,10 @@ class Timings(commands.Cog): return issue_count = len(embed_var.fields) - if issue_count > 25: - embed_var.description = "Showing 25 of " + str(issue_count) + " recommendations." - else: - embed_var.description = "Showing " + str(issue_count) + " of " + str(issue_count) + " recommendations." + if issue_count >= 25: + embed_var.insert_field_at(index=24, name="Plus " + str(issue_count - 24) + " more recommendations", value="Create a new timings report after resolving some of the above issues to see more,", inline=True) if issue_count > 0: - embed_var.description = embed_var.description + "\n||" + str(unchecked) + " missing configuration optimizations due to server version.||" + embed_var.description = "||" + str(unchecked) + " missing configuration optimizations due to your server version.||" await message.reply(embed=embed_var) From 4116e4f060a078cf7e1904c796d6e2ab9801e666 Mon Sep 17 00:00:00 2001 From: DrBot7 <46543473+DrBot7@users.noreply.github.com> Date: Mon, 11 Jan 2021 03:15:41 -0600 Subject: [PATCH 04/10] Update timings.py --- cogs/timings.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cogs/timings.py b/cogs/timings.py index c533781..f9943d5 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -143,7 +143,7 @@ class Timings(commands.Cog): min_mem = min_mem.replace("m", "") if min_mem != max_mem: embed_var.add_field(name="❌ Aikar's Flags", - value="Your Xmx and Xms values must be equal with Aikar's flags.", + value="Your Xmx and Xms values should be equivalent when using Aikar's flags.", inline=True) elif "-Dusing.aikars.flags=mcflags.emc.gs" in flags: embed_var.add_field(name="❌ Outdated Flags", @@ -1079,7 +1079,7 @@ class Timings(commands.Cog): issue_count = len(embed_var.fields) if issue_count >= 25: embed_var.insert_field_at(index=24, name="Plus " + str(issue_count - 24) + " more recommendations", value="Create a new timings report after resolving some of the above issues to see more,", inline=True) - if issue_count > 0: + if unchecked > 0: embed_var.description = "||" + str(unchecked) + " missing configuration optimizations due to your server version.||" await message.reply(embed=embed_var) From 275ffaff7300ee49d11d5b9ab6884f8e8fcb5da7 Mon Sep 17 00:00:00 2001 From: DrBot7 <46543473+DrBot7@users.noreply.github.com> Date: Mon, 11 Jan 2021 12:06:52 -0600 Subject: [PATCH 05/10] Timings - Remove double epic heads warning --- cogs/timings.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/cogs/timings.py b/cogs/timings.py index f9943d5..29d4b23 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -297,10 +297,6 @@ class Timings(commands.Cog): inline=True) for plugin in plugins: if "songoda" in r["timingsMaster"]["plugins"][plugin]["authors"].casefold(): - if plugin == "EpicHeads": - embed_var.add_field(name="❌ EpicHeads", - value="This plugin was made by Songoda. Songoda resources are poorly developed and often cause problems. You should find an alternative such as [HeadsPlus](spigotmc.org/resources/headsplus-»-1-8-1-16-4.40265/) or [HeadDatabase](https://www.spigotmc.org/resources/head-database.14280/).", - inline=True) if plugin == "EpicHeads": embed_var.add_field(name="❌ EpicHeads", value="This plugin was made by Songoda. Songoda resources are poorly developed and often cause problems. You should find an alternative such as [HeadsPlus](spigotmc.org/resources/headsplus-»-1-8-1-16-4.40265/) or [HeadDatabase](https://www.spigotmc.org/resources/head-database.14280/).", From e01dffe14e4d24c151fba5704e2ec39059536ba9 Mon Sep 17 00:00:00 2001 From: DrBot7 <46543473+DrBot7@users.noreply.github.com> Date: Mon, 11 Jan 2021 15:43:33 -0600 Subject: [PATCH 06/10] Update timings.py --- cogs/timings.py | 424 ++++++++++++++++++------------------------------ 1 file changed, 157 insertions(+), 267 deletions(-) diff --git a/cogs/timings.py b/cogs/timings.py index 29d4b23..fb85308 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -21,8 +21,9 @@ class Timings(commands.Cog): "https://timings.spigotmc.org/?url="): embed_var = discord.Embed(title="Timings Analysis", color=0x55ffff) embed_var.add_field(name="❌ Spigot", - value="Upgrade to [Purpur](https://ci.pl3x.net/job/Purpur/).", - inline=True) + value="Upgrade to [Purpur](https://ci.pl3x.net/job/Purpur/).") + embed_var.set_footer(text="Requested by " + message.author.name, icon_url=message.author.avatar_url) + embed_var.url = timings_url await message.reply(embed=embed_var) return if timings_url == "": @@ -38,8 +39,9 @@ class Timings(commands.Cog): if r is None: embed_var = discord.Embed(title="Timings Analysis", color=0x55ffff) embed_var.add_field(name="❌ Invalid report", - value="Create a new timings report.", - inline=True) + value="Create a new timings report.") + embed_var.set_footer(text="Requested by " + message.author.name, icon_url=message.author.avatar_url) + embed_var.url = timings_url await message.reply(embed=embed_var) return @@ -52,19 +54,16 @@ class Timings(commands.Cog): version = r["timingsMaster"]["version"] if "1.16.4" not in version: embed_var.add_field(name="❌ Legacy Build", - value="Update to 1.16.4.", - inline=True) + value="Update to 1.16.4.") using_yatopia = "yatopia" in r["timingsMaster"]["config"] if using_yatopia: embed_var.add_field(name="❌ Yatopia", value="Yatopia is prone to bugs. " - "Consider using [Purpur](https://ci.pl3x.net/job/Purpur/).", - inline=True) + "Consider using [Purpur](https://ci.pl3x.net/job/Purpur/).") elif "Paper" in version: embed_var.add_field(name="||❌ Paper||", value="||Purpur has more optimizations but is generally less supported. " - "Consider using [Purpur](https://ci.pl3x.net/job/Purpur/).||", - inline=True) + "Consider using [Purpur](https://ci.pl3x.net/job/Purpur/).||") except KeyError: unchecked = unchecked + 1 @@ -76,17 +75,15 @@ class Timings(commands.Cog): if not online_mode and bungeecord == "false" and (velocity_online_mode == "false" or velocity_enabled == "false"): embed_var.add_field(name="❌ online-mode", - value="Enable this in server.properties for security.", - inline=True) + value="Enable this in server.properties for security.") except KeyError: unchecked = unchecked + 1 try: timing_cost = int(r["timingsMaster"]["system"]["timingcost"]) - if timing_cost > 400: + if timing_cost > 300: embed_var.add_field(name="❌ Timingcost", - value="Your timingcost is " + str(timing_cost) + ". Find a [better host](https://www.birdflop.com).", - inline=True) + value="Your timingcost is " + str(timing_cost) + ". Find a [better host](https://www.birdflop.com).") except KeyError: unchecked = unchecked + 1 @@ -94,8 +91,7 @@ class Timings(commands.Cog): jvm_version = r["timingsMaster"]["system"]["jvmversion"] if jvm_version.startswith("1.8.") or jvm_version.startswith("9.") or jvm_version.startswith("10."): embed_var.add_field(name="❌ Java Version", - value="Use Java 11.", - inline=True) + value="You are using Java " + jvm_version + ". Update to [Java 11](https://adoptopenjdk.net/installation.html).") except KeyError: unchecked = unchecked + 1 @@ -106,17 +102,14 @@ class Timings(commands.Cog): java_version = jvm_version.split(".")[0] if int(java_version) < 14: embed_var.add_field(name="❌ Java " + java_version, - value="If you are going to use ZGC, you should also use Java 14 or 15.", - inline=True) + value="If you are going to use ZGC, you should also use Java 14+.") elif "-Daikars.new.flags=true" in flags: if "-XX:+PerfDisableSharedMem" not in flags: embed_var.add_field(name="❌ Outdated Flags", - value="Add `-XX:+PerfDisableSharedMem` to flags", - inline=True) + value="Add `-XX:+PerfDisableSharedMem` to flags") if "XX:G1MixedGCCountTarget=4" not in flags: embed_var.add_field(name="❌ Outdated Flags", - value="Add `-XX:G1MixedGCCountTarget=4` to flags", - inline=True) + value="Add `-XX:G1MixedGCCountTarget=4` to flags") if "-Xmx" in flags: max_mem = 0 flaglist = flags.split(" ") @@ -129,8 +122,7 @@ class Timings(commands.Cog): max_mem = max_mem.replace("m", "") if int(max_mem) < 5400: embed_var.add_field(name="❌ Low Memory", - value="Allocate at least 6-10GB of ram to your server if you can afford it.", - inline=True) + value="Allocate at least 6-10GB of ram to your server if you can afford it.") if "-Xms" in flags: min_mem = 0 flaglist = flags.split(" ") @@ -143,24 +135,23 @@ class Timings(commands.Cog): min_mem = min_mem.replace("m", "") if min_mem != max_mem: embed_var.add_field(name="❌ Aikar's Flags", - value="Your Xmx and Xms values should be equivalent when using Aikar's flags.", - inline=True) + value="Your Xmx and Xms values should be equivalent when using Aikar's flags.") elif "-Dusing.aikars.flags=mcflags.emc.gs" in flags: embed_var.add_field(name="❌ Outdated Flags", - value="Update [Aikar's flags](https://aikar.co/2018/07/02/tuning-the-jvm-g1gc-garbage-collector-flags-for-minecraft/).", - inline=True) + value="Update [Aikar's flags](https://aikar.co/2018/07/02/tuning-the-jvm-g1gc-garbage-collector-flags-for-minecraft/).") else: embed_var.add_field(name="❌ Aikar's Flags", - value="Use [Aikar's flags](https://aikar.co/2018/07/02/tuning-the-jvm-g1gc-garbage-collector-flags-for-minecraft/).", - inline=True) + value="Use [Aikar's flags](https://aikar.co/2018/07/02/tuning-the-jvm-g1gc-garbage-collector-flags-for-minecraft/).") except KeyError: unchecked = unchecked + 1 try: cpu = int(r["timingsMaster"]["system"]["cpu"]) - if cpu <= 2: + if cpu == 1: embed_var.add_field(name="❌ Threads", - value="You have only " + str(cpu) + " thread(s). Find a [better host](https://www.birdflop.com).", - inline=True) + value="You have only " + str(cpu) + " thread. Find a [better host](https://www.birdflop.com).") + if cpu == 2: + embed_var.add_field(name="❌ Threads", + value="You have only " + str(cpu) + " threads. Find a [better host](https://www.birdflop.com).") except KeyError: unchecked = unchecked + 1 @@ -169,147 +160,118 @@ class Timings(commands.Cog): if "ClearLag" in plugins: embed_var.add_field(name="❌ ClearLag", value="Plugins that claim to remove lag actually cause more lag. " - "Remove ClearLag.", - inline=True) + "Remove ClearLag.") if "LagAssist" in plugins: embed_var.add_field(name="❌ LagAssist", - value="Plugins that claim to remove lag actually cause more lag. " - "LagAssist should only be used for analytics and preventative measures. All other features should be disabled.", - inline=True) + value="LagAssist should only be used for analytics and preventative measures." + "All other features of the plugin should be disabled.") if "NoChunkLag" in plugins: embed_var.add_field(name="❌ NoChunkLag", value="Plugins that claim to remove lag actually cause more lag. " - "Remove NoChunkLag.", - inline=True) + "Remove NoChunkLag.") if "ServerBooster" in plugins: embed_var.add_field(name="❌ ServerBooster", value="Plugins that claim to remove lag actually cause more lag. " - "Remove ServerBooster.", - inline=True) + "Remove ServerBooster.") if "MobLimiter" in plugins: embed_var.add_field(name="❌ MobLimiter", value="You probably don't need MobLimiter as Bukkit already has its features. " - "Remove MobLimiter.", - inline=True) + "Remove MobLimiter.") if "BookLimiter" in plugins: embed_var.add_field(name="❌ BookLimiter", value="You probably don't need BookLimiter as Paper already has its features. " - "Remove BookLimiter.", - inline=True) + "Remove BookLimiter.") if "LimitPillagers" in plugins: embed_var.add_field(name="❌ LimitPillagers", value="You probably don't need LimitPillagers as Paper already adds its features. " - "Remove LimitPillagers.", - inline=True) + "Remove LimitPillagers.") if "VillagerOptimiser" in plugins: embed_var.add_field(name="❌ VillagerOptimiser", value="You probably don't need VillagerOptimiser as Paper already adds its features. " - "See entity-activation-range in spigot.yml.", - inline=True) + "See entity-activation-range in spigot.yml.") if "StackMob" in plugins: embed_var.add_field(name="❌ StackMob", value="Stacking plugins actually cause more lag. " - "Remove StackMob.", - inline=True) + "Remove StackMob.") if "Stacker" in plugins: embed_var.add_field(name="❌ Stacker", value="Stacking plugins actually cause more lag. " - "Remove Stacker.", - inline=True) + "Remove Stacker.") if "MobStacker" in plugins: embed_var.add_field(name="❌ MobStacker", value="Stacking plugins actually cause more lag. " - "Remove MobStacker.", - inline=True) + "Remove MobStacker.") if "WildStacker" in plugins: embed_var.add_field(name="❌ WildStacker", value="Stacking plugins actually cause more lag. " - "Remove WildStacker.", - inline=True) + "Remove WildStacker.") if "SuggestionBlocker" in plugins: embed_var.add_field(name="❌ SuggestionBlocker", value="You probably don't need SuggestionBlocker as Spigot already adds its features. " - "Set tab-complete to -1 in spigot.yml.", - inline=True) + "Set tab-complete to -1 in spigot.yml.") if "FastAsyncWorldEdit" in plugins: embed_var.add_field(name="❌ FastAsyncWorldEdit", value="FAWE can corrupt your world. " - "Consider replacing FAWE with [Worldedit](https://enginehub.org/worldedit/#downloads).", - inline=True) + "Consider replacing FAWE with [Worldedit](https://enginehub.org/worldedit/#downloads).") if "CMI" in plugins: embed_var.add_field(name="❌ CMI", value="CMI is a buggy plugin. " - "Consider replacing CMI with [EssentialsX](https://essentialsx.net/downloads.html).", - inline=True) + "Consider replacing CMI with [EssentialsX](https://essentialsx.net/downloads.html).") if "Spartan" in plugins: embed_var.add_field(name="❌ Spartan", value="Spartan is a laggy anticheat. " - "Consider replacing it with [Matrix](https://matrix.rip/), [NCP](https://ci.codemc.io/job/Updated-NoCheatPlus/job/Updated-NoCheatPlus/), or [AAC](https://www.spigotmc.org/resources/aac-advanced-anti-cheat-hack-kill-aura-blocker.6442/).", - inline=True) + "Consider replacing it with [Matrix](https://matrix.rip/), [NCP](https://ci.codemc.io/job/Updated-NoCheatPlus/job/Updated-NoCheatPlus/), or [AAC](https://www.spigotmc.org/resources/aac-advanced-anti-cheat-hack-kill-aura-blocker.6442/).") if "IllegalStack" in plugins: embed_var.add_field(name="❌ IllegalStack", value="You probably don't need IllegalStack as Paper already has its features. " - "Remove IllegalStack.", - inline=True) + "Remove IllegalStack.") if "ExploitFixer" in plugins: embed_var.add_field(name="❌ ExploitFixer", value="You probably don't need ExploitFixer as Paper already has its features. " - "Remove ExploitFixer.", - inline=True) + "Remove ExploitFixer.") if "EntityTrackerFixer" in plugins: embed_var.add_field(name="❌ EntityTrackerFixer", value="You probably don't need EntityTrackerFixer as Paper already has its features. " - "Remove EntityTrackerFixer.", - inline=True) + "Remove EntityTrackerFixer.") if "Orebfuscator" in plugins: embed_var.add_field(name="❌ Orebfuscator", value="You probably don't need Orebfuscator as Paper already has its features. " - "Remove Orebfuscator.", - inline=True) + "Remove Orebfuscator.") if "ImageOnMap" in plugins: embed_var.add_field(name="❌ ImageOnMap", value="This plugin has a [memory leak](https://github.com/zDevelopers/ImageOnMap/issues/104). If it is not essential, you should remove it. " - "Consider replacing it with [an alternative](https://www.spigotmc.org/resources/drmap.87368/).", - inline=True) + "Consider replacing it with [an alternative](https://www.spigotmc.org/resources/drmap.87368/).") if "CrazyActions" in plugins: embed_var.add_field(name="❌ CrazyAuctions", value="CrazyAuctions is a laggy plugin, even according to the developer. " - "Consider replacing it with [AuctionHouse](https://www.spigotmc.org/resources/auctionhouse.61836/).", - inline=True) + "Consider replacing it with [AuctionHouse](https://www.spigotmc.org/resources/auctionhouse.61836/).") if "GroupManager" in plugins: embed_var.add_field(name="❌ GroupManager", value="GroupManager is an outdated permission plugin. " - "Consider replacing it with [LuckPerms](https://ci.lucko.me/job/LuckPerms/1243/artifact/bukkit/build/libs/LuckPerms-Bukkit-5.2.77.jar).", - inline=True) + "Consider replacing it with [LuckPerms](https://ci.lucko.me/job/LuckPerms/1243/artifact/bukkit/build/libs/LuckPerms-Bukkit-5.2.77.jar).") if "PermissionsEx" in plugins: embed_var.add_field(name="❌ PermissionsEx", value="PermissionsEx is an outdated permission plugin. " - "Consider replacing it with [LuckPerms](https://ci.lucko.me/job/LuckPerms/1243/artifact/bukkit/build/libs/LuckPerms-Bukkit-5.2.77.jar).", - inline=True) + "Consider replacing it with [LuckPerms](https://ci.lucko.me/job/LuckPerms/1243/artifact/bukkit/build/libs/LuckPerms-Bukkit-5.2.77.jar).") if "bPermissions" in plugins: embed_var.add_field(name="❌ bPermissions", value="bPermissions is an outdated permission plugin. " - "Consider replacing it with [LuckPerms](https://ci.lucko.me/job/LuckPerms/1243/artifact/bukkit/build/libs/LuckPerms-Bukkit-5.2.77.jar).", - inline=True) + "Consider replacing it with [LuckPerms](https://ci.lucko.me/job/LuckPerms/1243/artifact/bukkit/build/libs/LuckPerms-Bukkit-5.2.77.jar).") if "DisableJoinMessage" in plugins and "Essentials" in plugins: embed_var.add_field(name="❌ DisableJoinMessage", - value="You probably don't need DisableJoinMessage because Essentials already has its features. ", - inline=True) + value="You probably don't need DisableJoinMessage because Essentials already has its features. ") for plugin in plugins: if "songoda" in r["timingsMaster"]["plugins"][plugin]["authors"].casefold(): if plugin == "EpicHeads": embed_var.add_field(name="❌ EpicHeads", - value="This plugin was made by Songoda. Songoda resources are poorly developed and often cause problems. You should find an alternative such as [HeadsPlus](spigotmc.org/resources/headsplus-»-1-8-1-16-4.40265/) or [HeadDatabase](https://www.spigotmc.org/resources/head-database.14280/).", - inline=True) + value="This plugin was made by Songoda. Songoda resources are poorly developed and often cause problems. You should find an alternative such as [HeadsPlus](spigotmc.org/resources/headsplus-»-1-8-1-16-4.40265/) or [HeadDatabase](https://www.spigotmc.org/resources/head-database.14280/).") elif plugin == "UltimateStacker": embed_var.add_field(name="❌ UltimateStacker", value="Stacking plugins actually cause more lag. " - "Remove UltimateStacker.", - inline=True) + "Remove UltimateStacker.") else: embed_var.add_field(name="❌ " + plugin, - value="This plugin was made by Songoda. Songoda resources are poorly developed and often cause problems. You should find an alternative.", - inline=True) + value="This plugin was made by Songoda. Songoda resources are poorly developed and often cause problems. You should find an alternative.") except KeyError: unchecked = unchecked + 1 @@ -320,18 +282,15 @@ class Timings(commands.Cog): if "SilkSpawners" in plugins: embed_var.add_field(name="❌ SilkSpawners", value="You probably don't need SilkSpawners as Purpur already has its features. " - "Remove SilkSpawners.", - inline=True) + "Remove SilkSpawners.") if "MineableSpawners" in plugins: embed_var.add_field(name="❌ MineableSpawners", value="You probably don't need MineableSpawners as Purpur already has its features. " - "Remove MineableSpawners.", - inline=True) + "Remove MineableSpawners.") if "VillagerLobotomizatornator" in plugins: embed_var.add_field(name="❌ LimitPillagers", value="You probably don't need VillagerLobotomizatornator as Purpur already adds its features. " - "Enable villager.lobotomize.enabled in purpur.yml.", - inline=True) + "Enable villager.lobotomize.enabled in purpur.yml.") except KeyError: unchecked = unchecked + 1 @@ -343,13 +302,11 @@ class Timings(commands.Cog): if phantoms_only_insomniacs == "false": embed_var.add_field(name="❌ PhantomSMP", value="You probably don't need PhantomSMP as Paper already has its features. " - "Remove PhantomSMP.", - inline=True) + "Remove PhantomSMP.") else: embed_var.add_field(name="❌ PhantomSMP", value="You probably don't need PhantomSMP as Paper already has its features. " - "Enable phantoms-only-attack-insomniacs in paper.yml.", - inline=True) + "Enable phantoms-only-attack-insomniacs in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -357,34 +314,30 @@ class Timings(commands.Cog): network_compression_threshold = int( r["timingsMaster"]["config"]["server.properties"]["network-compression-threshold"]) bungeecord = r["timingsMaster"]["config"]["spigot"]["settings"]["bungeecord"] - if network_compression_threshold == 256 and bungeecord == "false": + if network_compression_threshold <= 256 and bungeecord == "false": embed_var.add_field(name="❌ network-compression-threshold", - value="Increase this in server.properties. Recommended: 512.", - inline=True) + value="Increase this in server.properties. Recommended: 512.") if network_compression_threshold != -1 and bungeecord == "true": embed_var.add_field(name="❌ network-compression-threshold", - value="Set this to -1 in server.properties for a bungee server like yours.", - inline=True) + value="Set this to -1 in server.properties for a bungee server like yours.") except KeyError: unchecked = unchecked + 1 try: spigot_view_distance = r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["view-distance"] view_distance = int(r["timingsMaster"]["config"]["server.properties"]["view-distance"]) - if view_distance == 10 and spigot_view_distance == "default": + if view_distance >= 10 and spigot_view_distance == "default": embed_var.add_field(name="❌ view-distance", value="Decrease this from default (10) in spigot.yml. " - "Recommended: 3.", - inline=True) + "Recommended: 3.") except KeyError: unchecked = unchecked + 1 try: chunk_gc_period = int(r["timingsMaster"]["config"]["bukkit"]["chunk-gc"]["period-in-ticks"]) - if chunk_gc_period == 600: + if chunk_gc_period >= 600: embed_var.add_field(name="❌ chunk-gc.period-in-ticks", - value="Decrease this in bukkit.yml.\nRecommended: 400.", - inline=True) + value="Decrease this in bukkit.yml.\nRecommended: 400.") except KeyError: unchecked = unchecked + 1 @@ -392,53 +345,47 @@ class Timings(commands.Cog): ticks_per_monster_spawns = int(r["timingsMaster"]["config"]["bukkit"]["ticks-per"]["monster-spawns"]) if ticks_per_monster_spawns == 1: embed_var.add_field(name="❌ ticks-per.monster-spawns", - value="Increase this in bukkit.yml.\nRecommended: 4.", - inline=True) + value="Increase this in bukkit.yml.\nRecommended: 4.") except KeyError: unchecked = unchecked + 1 try: monsters_spawn_limit = int(r["timingsMaster"]["config"]["bukkit"]["spawn-limits"]["monsters"]) - if monsters_spawn_limit == 70: + if monsters_spawn_limit >= 70: embed_var.add_field(name="❌ spawn-limits.monsters", - value="Decrease this in bukkit.yml.\nRecommended: 15.", - inline=True) + value="Decrease this in bukkit.yml.\nRecommended: 15.") except KeyError: unchecked = unchecked + 1 try: water_ambient_spawn_limit = int(r["timingsMaster"]["config"]["bukkit"]["spawn-limits"]["water-ambient"]) - if water_ambient_spawn_limit == 20: + if water_ambient_spawn_limit >= 20: embed_var.add_field(name="❌ spawn-limits.water-ambient", - value="Decrease this in bukkit.yml.\nRecommended: 2.", - inline=True) + value="Decrease this in bukkit.yml.\nRecommended: 2.") except KeyError: unchecked = unchecked + 1 try: ambient_spawn_limit = int(r["timingsMaster"]["config"]["bukkit"]["spawn-limits"]["ambient"]) - if ambient_spawn_limit == 15: + if ambient_spawn_limit >= 15: embed_var.add_field(name="❌ spawn-limits.ambient", - value="Decrease this in bukkit.yml.\nRecommended: 1.", - inline=True) + value="Decrease this in bukkit.yml.\nRecommended: 1.") except KeyError: unchecked = unchecked + 1 try: animals_spawn_limit = int(r["timingsMaster"]["config"]["bukkit"]["spawn-limits"]["animals"]) - if animals_spawn_limit == 10: + if animals_spawn_limit >= 10: embed_var.add_field(name="❌ spawn-limits.animals", - value="Decrease this in bukkit.yml.\nRecommended: 3.", - inline=True) + value="Decrease this in bukkit.yml.\nRecommended: 3.") except KeyError: unchecked = unchecked + 1 try: water_animals_spawn_limit = int(r["timingsMaster"]["config"]["bukkit"]["spawn-limits"]["water-animals"]) - if water_animals_spawn_limit == 15: + if water_animals_spawn_limit >= 15: embed_var.add_field(name="❌ spawn-limits.water-animals", - value="Decrease this in bukkit.yml.\nRecommended: 2.", - inline=True) + value="Decrease this in bukkit.yml.\nRecommended: 2.") except KeyError: unchecked = unchecked + 1 @@ -447,16 +394,14 @@ class Timings(commands.Cog): spigot_view_distance = r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["view-distance"] if spigot_view_distance == "default": view_distance = int(r["timingsMaster"]["config"]["server.properties"]["view-distance"]) - if mob_spawn_range == 8 and view_distance <= 6: + if mob_spawn_range >= 8 and view_distance <= 6: embed_var.add_field(name="❌ mob-spawn-range", value="Decrease this in spigot.yml. " - "Recommended: " + str(view_distance - 1) + ".", - inline=True) - elif mob_spawn_range == 8 and int(spigot_view_distance) <= 6: + "Recommended: " + str(view_distance - 1) + ".") + elif mob_spawn_range >= 8 and int(spigot_view_distance) <= 6: embed_var.add_field(name="❌ mob-spawn-range", value="Decrease this in spigot.yml. " - "Recommended: " + str(int(spigot_view_distance) - 1) + ".", - inline=True) + "Recommended: " + str(int(spigot_view_distance) - 1) + ".") except KeyError: unchecked = unchecked + 1 @@ -464,11 +409,10 @@ class Timings(commands.Cog): animals_entity_activation_range = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "animals"]) - if animals_entity_activation_range == 32: + if animals_entity_activation_range >= 32: embed_var.add_field(name="❌ entity-activation-range.animals", value="Decrease this in spigot.yml. " - "Recommended: 6.", - inline=True) + "Recommended: 6.") except KeyError: unchecked = unchecked + 1 @@ -476,11 +420,10 @@ class Timings(commands.Cog): monsters_entity_activation_range = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "monsters"]) - if monsters_entity_activation_range == 32: + if monsters_entity_activation_range >= 32: embed_var.add_field(name="❌ entity-activation-range.monsters", value="Decrease this in spigot.yml. " - "Recommended: 16.", - inline=True) + "Recommended: 16.") except KeyError: unchecked = unchecked + 1 @@ -494,22 +437,20 @@ class Timings(commands.Cog): try: misc_entity_activation_range = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"]["misc"]) - if misc_entity_activation_range == 16: + if misc_entity_activation_range >= 16: embed_var.add_field(name="❌ entity-activation-range.misc", value="Decrease this in spigot.yml. " - "Recommended: 4.", - inline=True) + "Recommended: 4.") except KeyError: unchecked = unchecked + 1 try: water_entity_activation_range = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"]["water"]) - if water_entity_activation_range == 16: + if water_entity_activation_range >= 16: embed_var.add_field(name="❌ entity-activation-range.water", value="Decrease this in spigot.yml. " - "Recommended: 12.", - inline=True) + "Recommended: 12.") except KeyError: unchecked = unchecked + 1 @@ -517,11 +458,10 @@ class Timings(commands.Cog): villagers_entity_activation_range = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "villagers"]) - if villagers_entity_activation_range == 32: + if villagers_entity_activation_range >= 32: embed_var.add_field(name="❌ entity-activation-range.villagers", value="Decrease this in spigot.yml. " - "Recommended: 16.", - inline=True) + "Recommended: 16.") except KeyError: unchecked = unchecked + 1 @@ -538,8 +478,7 @@ class Timings(commands.Cog): "tick-inactive-villagers"] if tick_inactive_villagers == "true": embed_var.add_field(name="❌ tick-inactive-villagers", - value="Disable this in spigot.yml.", - inline=True) + value="Disable this in spigot.yml.") except KeyError: unchecked = unchecked + 1 @@ -547,8 +486,7 @@ class Timings(commands.Cog): nerf_spawner_mobs = r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["nerf-spawner-mobs"] if nerf_spawner_mobs == "false": embed_var.add_field(name="❌ nerf-spawner-mobs", - value="Enable this in spigot.yml.", - inline=True) + value="Enable this in spigot.yml.") except KeyError: unchecked = unchecked + 1 @@ -562,11 +500,10 @@ class Timings(commands.Cog): wake_up_inactive_villagers_for = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "wake-up-inactive"]["villagers-every"]) - if wake_up_inactive_villagers_for == 100: + if wake_up_inactive_villagers_for >= 100: embed_var.add_field(name="❌ wake-up-inactive.villagers-for", value="Decrease this in spigot.yml. " - "Recommended: 20.", - inline=True) + "Recommended: 20.") except KeyError: unchecked = unchecked + 1 @@ -574,11 +511,10 @@ class Timings(commands.Cog): wake_up_inactive_flying_monsters_for = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "wake-up-inactive"]["villagers-every"]) - if wake_up_inactive_flying_monsters_for == 100: + if wake_up_inactive_flying_monsters_for >= 100: embed_var.add_field(name="❌ wake-up-inactive.flying-monsters-for", value="Decrease this in spigot.yml. " - "Recommended: 60.", - inline=True) + "Recommended: 60.") except KeyError: unchecked = unchecked + 1 @@ -594,11 +530,10 @@ class Timings(commands.Cog): wake_up_inactive_villagers_max_per_tick = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "wake-up-inactive"]["villagers-every"]) - if wake_up_inactive_villagers_max_per_tick == 4: + if wake_up_inactive_villagers_max_per_tick >= 4: embed_var.add_field(name="❌ wake-up-inactive.villagers-max-per-tick", value="Decrease this in spigot.yml. " - "Recommended: 1.", - inline=True) + "Recommended: 1.") except KeyError: unchecked = unchecked + 1 @@ -606,11 +541,10 @@ class Timings(commands.Cog): wake_up_inactive_animals_for = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "wake-up-inactive"]["villagers-every"]) - if wake_up_inactive_animals_for == 100: + if wake_up_inactive_animals_for >= 100: embed_var.add_field(name="❌ wake-up-inactive.animals-for", value="Decrease this in spigot.yml. " - "Recommended: 40.", - inline=True) + "Recommended: 40.") except KeyError: unchecked = unchecked + 1 @@ -618,11 +552,10 @@ class Timings(commands.Cog): wake_up_inactive_monsters_max_per_tick = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "wake-up-inactive"]["villagers-every"]) - if wake_up_inactive_monsters_max_per_tick == 8: + if wake_up_inactive_monsters_max_per_tick >= 8: embed_var.add_field(name="❌ wake-up-inactive.monsters-max-per-tick", value="Decrease this in spigot.yml. " - "Recommended: 4.", - inline=True) + "Recommended: 4.") except KeyError: unchecked = unchecked + 1 @@ -630,11 +563,10 @@ class Timings(commands.Cog): wake_up_inactive_flying_monsters_max_per_tick = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "wake-up-inactive"]["villagers-every"]) - if wake_up_inactive_flying_monsters_max_per_tick == 8: + if wake_up_inactive_flying_monsters_max_per_tick >= 8: embed_var.add_field(name="❌ wake-up-inactive.flying-monsters-max-per-tick", value="Decrease this in spigot.yml. " - "Recommended: 1.", - inline=True) + "Recommended: 1.") except KeyError: unchecked = unchecked + 1 @@ -656,11 +588,10 @@ class Timings(commands.Cog): wake_up_inactive_animals_max_per_tick = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "wake-up-inactive"]["villagers-every"]) - if wake_up_inactive_animals_max_per_tick == 4: + if wake_up_inactive_animals_max_per_tick >= 4: embed_var.add_field(name="❌ wake-up-inactive.animals-max-per-tick", value="Decrease this in spigot.yml. " - "Recommended: 2.", - inline=True) + "Recommended: 2.") except KeyError: unchecked = unchecked + 1 @@ -668,66 +599,60 @@ class Timings(commands.Cog): wake_up_inactive_monsters_for = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ "wake-up-inactive"]["villagers-every"]) - if wake_up_inactive_monsters_for == 100: + if wake_up_inactive_monsters_for >= 100: embed_var.add_field(name="❌ wake-up-inactive.monsters-for", value="Decrease this in spigot.yml. " - "Recommended: 60.", - inline=True) + "Recommended: 60.") except KeyError: unchecked = unchecked + 1 try: arrow_despawn_rate = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["arrow-despawn-rate"]) - if arrow_despawn_rate == 1200: + if arrow_despawn_rate >= 1200: embed_var.add_field(name="❌ arrow-despawn-rate", value="Decrease this in spigot.yml. " - "Recommended: 300.", - inline=True) + "Recommended: 300.") except KeyError: unchecked = unchecked + 1 try: item_merge_radius = float( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["merge-radius"]["item"]) - if item_merge_radius == 2.5: + if item_merge_radius <= 2.5: embed_var.add_field(name="❌ merge-radius.item", value="Increase this in spigot.yml. " - "Recommended: 4.0.", - inline=True) + "Recommended: 4.0.") except KeyError: unchecked = unchecked + 1 try: exp_merge_radius = float( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["merge-radius"]["exp"]) - if exp_merge_radius == 3.0: + if exp_merge_radius <= 3.0: embed_var.add_field(name="❌ merge-radius.exp", value="Increase this in spigot.yml. " - "Recommended: 6.0.", - inline=True) + "Recommended: 6.0.") except KeyError: unchecked = unchecked + 1 try: max_entity_collisions = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["max-entity-collisions"]) - if max_entity_collisions == 8: + if max_entity_collisions >= 8: embed_var.add_field(name="❌ max-entity-collisions", value="Decrease this in spigot.yml. " - "Recommended: 2.", - inline=True) + "Recommended: 2.") except KeyError: unchecked = unchecked + 1 try: max_auto_save_chunks_per_tick = int( r["timingsMaster"]["config"]["paper"]["world-settings"]["default"]["max-auto-save-chunks-per-tick"]) - if max_auto_save_chunks_per_tick == 24: + if max_auto_save_chunks_per_tick >= 24: embed_var.add_field(name="❌ max-auto-save-chunks-per-tick", value="Decrease this in paper.yml. " - "Recommended: 6.", - inline=True) + "Recommended: 6.") except KeyError: unchecked = unchecked + 1 @@ -736,8 +661,7 @@ class Timings(commands.Cog): "optimize-explosions"] if optimize_explosions == "false": embed_var.add_field(name="❌ optimize-explosions", - value="Enable this in paper.yml.", - inline=True) + value="Enable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -747,8 +671,7 @@ class Timings(commands.Cog): if mob_spawner_tick_rate == 1: embed_var.add_field(name="❌ mob-spawner-tick-rate", value="Increase this in paper.yml. " - "Recommended: 2.", - inline=True) + "Recommended: 2.") except KeyError: unchecked = unchecked + 1 @@ -758,8 +681,7 @@ class Timings(commands.Cog): "disable-chest-cat-detection"] if disable_chest_cat_detection == "false": embed_var.add_field(name="❌ disable-chest-cat-detection", - value="Enable this in paper.yml.", - inline=True) + value="Enable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -769,8 +691,7 @@ class Timings(commands.Cog): if container_update_tick_rate == "false": embed_var.add_field(name="❌ container-update-tick-rate", value="Increase this in paper.yml. " - "Recommended: 3.", - inline=True) + "Recommended: 3.") except KeyError: unchecked = unchecked + 1 @@ -780,29 +701,26 @@ class Timings(commands.Cog): if grass_spread_tick_rate == 1: embed_var.add_field(name="❌ grass-spread-tick-rate", value="Increase this in paper.yml. " - "Recommended: 4", - inline=True) + "Recommended: 4") except KeyError: unchecked = unchecked + 1 try: soft_despawn_range = int( r["timingsMaster"]["config"]["paper"]["world-settings"]["default"]["despawn-ranges"]["soft"]) - if soft_despawn_range == 32: + if soft_despawn_range >= 32: embed_var.add_field(name="❌ despawn-ranges.soft", value="Decrease this in paper.yml. " - "Recommended: 28", - inline=True) + "Recommended: 28") except KeyError: unchecked = unchecked + 1 try: hard_despawn_range = int(r["timingsMaster"]["config"]["paper"]["world-settings"]["default"]["despawn-ranges"]["soft"]) - if hard_despawn_range == 128: + if hard_despawn_range >= 128: embed_var.add_field(name="❌ despawn-ranges.hard", value="Decrease this in paper.yml. " - "Recommended: 48", - inline=True) + "Recommended: 48") except KeyError: unchecked = unchecked + 1 @@ -811,8 +729,7 @@ class Timings(commands.Cog): "disable-move-event"] if hopper_disable_move_event == "false": embed_var.add_field(name="❌ hopper.disable-move-event", - value="Enable this in paper.yml.", - inline=True) + value="Enable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -822,8 +739,7 @@ class Timings(commands.Cog): if non_player_arrow_despawn_rate == -1: embed_var.add_field(name="❌ non-player-arrow-despawn-rate", value="Set a value in paper.yml. " - "Recommended: 60", - inline=True) + "Recommended: 60") except KeyError: unchecked = unchecked + 1 @@ -833,8 +749,7 @@ class Timings(commands.Cog): if creative_arrow_despawn_rate == -1: embed_var.add_field(name="❌ creative-arrow-despawn-rate", value="Set a value in paper.yml. " - "Recommended: 60", - inline=True) + "Recommended: 60") except KeyError: unchecked = unchecked + 1 @@ -843,8 +758,7 @@ class Timings(commands.Cog): "prevent-moving-into-unloaded-chunks"] if prevent_moving_into_unloaded_chunks == "false": embed_var.add_field(name="❌ prevent-moving-into-unloaded-chunks", - value="Enable this in paper.yml.", - inline=True) + value="Enable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -853,8 +767,7 @@ class Timings(commands.Cog): "use-faster-eigencraft-redstone"] if eigencraft_redstone == "false": embed_var.add_field(name="❌ use-faster-eigencraft-redstone", - value="Enable this in paper.yml.", - inline=True) + value="Enable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -862,8 +775,7 @@ class Timings(commands.Cog): fix_climbing_bypass_gamerule = r["timingsMaster"]["config"]["paper"]["world-settings"]["default"]["fix-climbing-bypassing-cramming-rule"] if fix_climbing_bypass_gamerule == "false": embed_var.add_field(name="❌ fix-climbing-bypassing-cramming-rule", - value="Enable this in paper.yml.", - inline=True) + value="Enable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -871,8 +783,7 @@ class Timings(commands.Cog): armor_stands_do_collision_entity_lookups = r["timingsMaster"]["config"]["paper"]["world-settings"]["default"]["armor-stands-do-collision-entity-lookups"] if armor_stands_do_collision_entity_lookups == "true": embed_var.add_field(name="❌ armor-stands-do-collision-entity-lookups", - value="Disable this in paper.yml.", - inline=True) + value="Disable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -881,8 +792,7 @@ class Timings(commands.Cog): armor_stands_tick = r["timingsMaster"]["config"]["paper"]["world-settings"]["default"]["armor-stands-tick"] if armor_stands_tick == "true" and "PetBlocks" not in plugins and "BlockBalls" not in plugins and "ArmorStandTools" not in plugins: embed_var.add_field(name="❌ armor-stands-tick", - value="Disable this in paper.yml.", - inline=True) + value="Disable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -891,8 +801,7 @@ class Timings(commands.Cog): "per-player-mob-spawns"] if per_player_mob_spawns == "false": embed_var.add_field(name="❌ per-player-mob-spawns", - value="Enable this in paper.yml.", - inline=True) + value="Enable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -901,8 +810,7 @@ class Timings(commands.Cog): r["timingsMaster"]["config"]["paper"]["world-settings"]["default"]["alt-item-despawn-rate"]["enabled"] if alt_item_despawn_rate_enabled == "false": embed_var.add_field(name="❌ alt-item-despawn-rate.enabled", - value="Enable this in paper.yml.", - inline=True) + value="Enable this in paper.yml.") except KeyError: unchecked = unchecked + 1 @@ -918,14 +826,11 @@ class Timings(commands.Cog): if view_distance >= 4: embed_var.add_field(name="❌ no-tick-view-distance", value="Set a value in paper.yml. " - "Recommended: " + str( - view_distance) + ". And reduce view-distance in server.properties. Recommended: 3.", - inline=True) + "Recommended: " + str(view_distance) + ". And reduce view-distance in server.properties. Recommended: 3.") elif int(spigot_view_distance) >= 4: embed_var.add_field(name="❌ no-tick-view-distance", value="Set a value in paper.yml. " - "Recommended: " + spigot_view_distance + ". And reduce view-distance in spigot.yml. Recommended: 3.", - inline=True) + "Recommended: " + spigot_view_distance + ". And reduce view-distance in spigot.yml. Recommended: 3.") except KeyError: unchecked = unchecked + 1 @@ -934,8 +839,7 @@ class Timings(commands.Cog): "enable-treasure-maps"] if enable_treasure_maps == "true": embed_var.add_field(name="❌ enable-treasure-maps", - value="Disable this in paper.yml. Why? Generating treasure maps is extremely expensive and can hang a server if the structure it's trying to locate is really far away.", - inline=True) + value="Disable this in paper.yml. Why? Generating treasure maps is extremely expensive and can hang a server if the structure it's trying to locate is really far away.") except KeyError: unchecked = unchecked + 1 @@ -944,21 +848,19 @@ class Timings(commands.Cog): "projectile-load-save-per-chunk-limit"]) if projectile_load_save == -1: embed_var.add_field(name="❌ projectile-load-save-per-chunk-limit", - value="Set a value in paper.yml. Recommended: 8.", - inline=True) + value="Set a value in paper.yml. Recommended: 8.") except KeyError: unchecked = unchecked + 1 try: use_alternate_keepalive = r["timingsMaster"]["config"]["purpur"]["settings"]["use-alternate-keepalive"] + plugins = r["timingsMaster"]["plugins"] if use_alternate_keepalive == "false" and "TCPShield" not in plugins: embed_var.add_field(name="❌ use-alternate-keepalive", - value="Enable this in purpur.yml.", - inline=True) + value="Enable this in purpur.yml.") if use_alternate_keepalive == "true" and "TCPShield" in plugins: embed_var.add_field(name="❌ use-alternate-keepalive", - value="Disable this in purpur.yml. It causes issues with TCPShield.", - inline=True) + value="Disable this in purpur.yml. It causes issues with TCPShield.") except KeyError: unchecked = unchecked + 1 @@ -967,8 +869,7 @@ class Timings(commands.Cog): "dont-send-useless-entity-packets"] if dont_send_useless_entity_packets == "false": embed_var.add_field(name="❌ dont-send-useless-entity-packets", - value="Enable this in purpur.yml.", - inline=True) + value="Enable this in purpur.yml.") except KeyError: unchecked = unchecked + 1 @@ -978,8 +879,7 @@ class Timings(commands.Cog): "disable-treasure-searching"] if disable_treasure_searching == "false": embed_var.add_field(name="❌ dolphin.disable-treasure-searching", - value="Enable this in purpur.yml.", - inline=True) + value="Enable this in purpur.yml.") except KeyError: unchecked = unchecked + 1 @@ -990,8 +890,7 @@ class Timings(commands.Cog): if brain_ticks == 1: embed_var.add_field(name="❌ villager.brain-ticks", value="Increase this in purpur.yml. " - "Recommended: 4.", - inline=True) + "Recommended: 4.") except KeyError: unchecked = unchecked + 1 @@ -1002,8 +901,7 @@ class Timings(commands.Cog): if iron_golem_radius == 0: embed_var.add_field(name="❌ spawn-iron-golem.radius", value="Set a value in purpur.yml. " - "Recommended: 32.", - inline=True) + "Recommended: 32.") except KeyError: unchecked = unchecked + 1 @@ -1014,8 +912,7 @@ class Timings(commands.Cog): if iron_golem_limit == 0: embed_var.add_field(name="❌ spawn-iron-golem.limit", value="Set a value in purpur.yml. " - "Recommended: 5.", - inline=True) + "Recommended: 5.") except KeyError: unchecked = unchecked + 1 @@ -1025,8 +922,7 @@ class Timings(commands.Cog): "aggressive-towards-villager-when-lagging"] if aggressive_towards_villager_when_lagging == "true": embed_var.add_field(name="❌ zombie.aggresive-towards-villager-when-lagging", - value="Disable this in purpur.yml.", - inline=True) + value="Disable this in purpur.yml.") except KeyError: unchecked = unchecked + 1 @@ -1036,8 +932,7 @@ class Timings(commands.Cog): "entities-can-use-portals"] if entities_can_use_portals == "true": embed_var.add_field(name="❌ entities-can-use-portals", - value="Disable this in purpur.yml to prevent players from creating chunk anchors.", - inline=True) + value="Disable this in purpur.yml to prevent players from creating chunk anchors.") except KeyError: unchecked = unchecked + 1 @@ -1046,8 +941,7 @@ class Timings(commands.Cog): "lobotomize"]["enabled"] if lobotomize_enabled == "false": embed_var.add_field(name="❌ villager.lobotomize.enabled", - value="Enable this in purpur.yml.", - inline=True) + value="Enable this in purpur.yml.") except KeyError: unchecked = unchecked + 1 @@ -1055,16 +949,12 @@ class Timings(commands.Cog): teleport_if_outside_border = r["timingsMaster"]["config"]["purpur"]["world-settings"]["default"]["gameplay-mechanics"]["player"]["teleport-if-outside-border"] if teleport_if_outside_border == "false": embed_var.add_field(name="❌ player.teleport-if-outside-border", - value="Enable this in purpur.yml.", - inline=True) + value="Enable this in purpur.yml.") except KeyError: unchecked = unchecked + 1 except ValueError: embed_var.add_field(name="❌ Invalid Configuration", - value="At least one of your configuration files had an invalid data type.", - inline=True) - await message.reply(embed=embed_var) - return + value="At least one of your configuration files had an invalid data type.") if len(embed_var.fields) == 0: embed_var.add_field(name="✅ All good", @@ -1074,7 +964,7 @@ class Timings(commands.Cog): issue_count = len(embed_var.fields) if issue_count >= 25: - embed_var.insert_field_at(index=24, name="Plus " + str(issue_count - 24) + " more recommendations", value="Create a new timings report after resolving some of the above issues to see more,", inline=True) + embed_var.insert_field_at(index=24, name="Plus " + str(issue_count - 24) + " more recommendations", value="Create a new timings report after resolving some of the above issues to see more.") if unchecked > 0: embed_var.description = "||" + str(unchecked) + " missing configuration optimizations due to your server version.||" await message.reply(embed=embed_var) From 5bff6250180037306ce57efb603ed0bc17fb7dce Mon Sep 17 00:00:00 2001 From: DrBot7 <46543473+DrBot7@users.noreply.github.com> Date: Mon, 11 Jan 2021 16:02:55 -0600 Subject: [PATCH 07/10] Update timings.py --- cogs/timings.py | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/cogs/timings.py b/cogs/timings.py index fb85308..963f59b 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -21,7 +21,7 @@ class Timings(commands.Cog): "https://timings.spigotmc.org/?url="): embed_var = discord.Embed(title="Timings Analysis", color=0x55ffff) embed_var.add_field(name="❌ Spigot", - value="Upgrade to [Purpur](https://ci.pl3x.net/job/Purpur/).") + value="Upgrade to [Purpur](https://purpur.pl3x.net/downloads/#1.16.4).") embed_var.set_footer(text="Requested by " + message.author.name, icon_url=message.author.avatar_url) embed_var.url = timings_url await message.reply(embed=embed_var) @@ -499,7 +499,7 @@ class Timings(commands.Cog): try: wake_up_inactive_villagers_for = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["villagers-for"]) if wake_up_inactive_villagers_for >= 100: embed_var.add_field(name="❌ wake-up-inactive.villagers-for", value="Decrease this in spigot.yml. " @@ -510,7 +510,7 @@ class Timings(commands.Cog): try: wake_up_inactive_flying_monsters_for = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["flying-monsters-for"]) if wake_up_inactive_flying_monsters_for >= 100: embed_var.add_field(name="❌ wake-up-inactive.flying-monsters-for", value="Decrease this in spigot.yml. " @@ -521,7 +521,7 @@ class Timings(commands.Cog): try: wake_up_inactive_animals_every = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["animals-every"]) except KeyError: unchecked = unchecked + 1 @@ -529,7 +529,7 @@ class Timings(commands.Cog): try: wake_up_inactive_villagers_max_per_tick = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["villagers-max-per-tick"]) if wake_up_inactive_villagers_max_per_tick >= 4: embed_var.add_field(name="❌ wake-up-inactive.villagers-max-per-tick", value="Decrease this in spigot.yml. " @@ -540,7 +540,7 @@ class Timings(commands.Cog): try: wake_up_inactive_animals_for = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["animals-for"]) if wake_up_inactive_animals_for >= 100: embed_var.add_field(name="❌ wake-up-inactive.animals-for", value="Decrease this in spigot.yml. " @@ -551,7 +551,7 @@ class Timings(commands.Cog): try: wake_up_inactive_monsters_max_per_tick = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["monsters-max-per-tick"]) if wake_up_inactive_monsters_max_per_tick >= 8: embed_var.add_field(name="❌ wake-up-inactive.monsters-max-per-tick", value="Decrease this in spigot.yml. " @@ -562,7 +562,7 @@ class Timings(commands.Cog): try: wake_up_inactive_flying_monsters_max_per_tick = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["flying-monsters-max-per-tick"]) if wake_up_inactive_flying_monsters_max_per_tick >= 8: embed_var.add_field(name="❌ wake-up-inactive.flying-monsters-max-per-tick", value="Decrease this in spigot.yml. " @@ -573,21 +573,21 @@ class Timings(commands.Cog): try: wake_up_inactive_flying_monsters_every = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["flying-monsters-every"]) except KeyError: unchecked = unchecked + 1 try: wake_up_inactive_monsters_every = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["monsters-every"]) except KeyError: unchecked = unchecked + 1 try: wake_up_inactive_animals_max_per_tick = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["animals-max-per-tick"]) if wake_up_inactive_animals_max_per_tick >= 4: embed_var.add_field(name="❌ wake-up-inactive.animals-max-per-tick", value="Decrease this in spigot.yml. " @@ -598,7 +598,7 @@ class Timings(commands.Cog): try: wake_up_inactive_monsters_for = int( r["timingsMaster"]["config"]["spigot"]["world-settings"]["default"]["entity-activation-range"][ - "wake-up-inactive"]["villagers-every"]) + "wake-up-inactive"]["monsters-for"]) if wake_up_inactive_monsters_for >= 100: embed_var.add_field(name="❌ wake-up-inactive.monsters-for", value="Decrease this in spigot.yml. " From 883177f58542d177e0b528d9856b3d715b730bc9 Mon Sep 17 00:00:00 2001 From: DrBot7 <46543473+DrBot7@users.noreply.github.com> Date: Mon, 11 Jan 2021 16:30:34 -0600 Subject: [PATCH 08/10] Update timings.py --- cogs/timings.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/cogs/timings.py b/cogs/timings.py index 963f59b..c5ffd3f 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -217,10 +217,6 @@ class Timings(commands.Cog): embed_var.add_field(name="❌ CMI", value="CMI is a buggy plugin. " "Consider replacing CMI with [EssentialsX](https://essentialsx.net/downloads.html).") - if "Spartan" in plugins: - embed_var.add_field(name="❌ Spartan", - value="Spartan is a laggy anticheat. " - "Consider replacing it with [Matrix](https://matrix.rip/), [NCP](https://ci.codemc.io/job/Updated-NoCheatPlus/job/Updated-NoCheatPlus/), or [AAC](https://www.spigotmc.org/resources/aac-advanced-anti-cheat-hack-kill-aura-blocker.6442/).") if "IllegalStack" in plugins: embed_var.add_field(name="❌ IllegalStack", value="You probably don't need IllegalStack as Paper already has its features. " From 5f963c62a5ba3af9d86f8d9205232ef78c2d76a2 Mon Sep 17 00:00:00 2001 From: Purpur <43528123+Pemigrade@users.noreply.github.com> Date: Mon, 11 Jan 2021 16:34:06 -0600 Subject: [PATCH 09/10] change purpur download link --- cogs/timings.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cogs/timings.py b/cogs/timings.py index c5ffd3f..5388fb7 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -21,7 +21,7 @@ class Timings(commands.Cog): "https://timings.spigotmc.org/?url="): embed_var = discord.Embed(title="Timings Analysis", color=0x55ffff) embed_var.add_field(name="❌ Spigot", - value="Upgrade to [Purpur](https://purpur.pl3x.net/downloads/#1.16.4).") + value="Upgrade to [Purpur](https://purpur.pl3x.net/downloads/).") embed_var.set_footer(text="Requested by " + message.author.name, icon_url=message.author.avatar_url) embed_var.url = timings_url await message.reply(embed=embed_var) From 34d8563e30a6bed80b3abaf5bd9a9ca2bb01119e Mon Sep 17 00:00:00 2001 From: Purpur <43528123+Pemigrade@users.noreply.github.com> Date: Mon, 11 Jan 2021 23:54:19 -0600 Subject: [PATCH 10/10] Fix spacing typo --- cogs/timings.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cogs/timings.py b/cogs/timings.py index 5388fb7..e5b01ba 100644 --- a/cogs/timings.py +++ b/cogs/timings.py @@ -163,7 +163,7 @@ class Timings(commands.Cog): "Remove ClearLag.") if "LagAssist" in plugins: embed_var.add_field(name="❌ LagAssist", - value="LagAssist should only be used for analytics and preventative measures." + value="LagAssist should only be used for analytics and preventative measures. " "All other features of the plugin should be disabled.") if "NoChunkLag" in plugins: embed_var.add_field(name="❌ NoChunkLag",