Change too big message, disable reflection for scoreboard for now on 1.20.4

This commit is contained in:
libraryaddict 2023-12-27 19:00:44 +13:00
parent 14ae9c9e6e
commit c7d8e44169
2 changed files with 8 additions and 3 deletions

View File

@ -143,13 +143,13 @@ public class LDUploadLogs implements LDCommand {
if (isTooBig(latest)) {
sender.sendMessage(
ChatColor.RED + "Your latest.log file is too big! It should be less than 512kb! Please restart and run this " + "command again!");
ChatColor.RED + "Your latest.log file is too big! It should be less than 10mb! Please restart and run this " + "command again!");
return;
}
if (isTooBig(disguises)) {
sender.sendMessage(ChatColor.RED + "Your disguises.yml is too big! You'll need to trim that file down before using this command! It " +
"should be less than 512kb!");
"should be less than 10mb!");
return;
}
@ -246,7 +246,7 @@ public class LDUploadLogs implements LDCommand {
}
private boolean isTooBig(long length) {
return length > 10_000_000;
return length > 10_048_000;
}
@Override

View File

@ -2540,6 +2540,11 @@ public class ReflectionManager {
}
public static void setScore(Scoreboard scoreboard, String name, int score, boolean canScheduleTask) {
// Disabled for 1.20.4, 1.20.4 introduces "read only" scores and I don't have an idea on how to deal with it as yet
if (NmsVersion.v1_20_R3.isSupported()) {
return;
}
if (canScheduleTask && (!Bukkit.isPrimaryThread() || DisguiseUtilities.isRunningPaper())) {
new BukkitRunnable() {
@Override