mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-19 17:37:42 +01:00
Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly Paper Changes: PaperMC/Paper@2040c1e Player Flying Fall Damage API (#5357) PaperMC/Paper@fa42c68 Expose pre-collision moving velocity to VehicleBlockCollisionEvent (#8457) PaperMC/Paper@90750a6 Rework filtering spawn egg and tile entity nbt config (#6613)
This commit is contained in:
43
patches/server/0254-Fill-command-max-area-option.patch
Normal file
43
patches/server/0254-Fill-command-max-area-option.patch
Normal file
@@ -0,0 +1,43 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: BillyGalbreath <Blake.Galbreath@Gmail.com>
|
||||
Date: Sat, 29 Jan 2022 19:39:44 -0600
|
||||
Subject: [PATCH] Fill command max area option
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/commands/FillCommand.java b/src/main/java/net/minecraft/server/commands/FillCommand.java
|
||||
index 99fbb24dabe867ed4956a2996543107f58a57193..5c81c64540579fbacc335a3fadf4bf59f853dc39 100644
|
||||
--- a/src/main/java/net/minecraft/server/commands/FillCommand.java
|
||||
+++ b/src/main/java/net/minecraft/server/commands/FillCommand.java
|
||||
@@ -59,8 +59,10 @@ public class FillCommand {
|
||||
|
||||
private static int fillBlocks(CommandSourceStack source, BoundingBox range, BlockInput block, FillCommand.Mode mode, @Nullable Predicate<BlockInWorld> filter) throws CommandSyntaxException {
|
||||
int i = range.getXSpan() * range.getYSpan() * range.getZSpan();
|
||||
- if (i > 32768) {
|
||||
- throw ERROR_AREA_TOO_LARGE.create(32768, i);
|
||||
+ // Purpur start
|
||||
+ if (i > org.purpurmc.purpur.PurpurConfig.commandFillMaxArea) {
|
||||
+ throw ERROR_AREA_TOO_LARGE.create(org.purpurmc.purpur.PurpurConfig.commandFillMaxArea, i);
|
||||
+ // Purpur end
|
||||
} else {
|
||||
List<BlockPos> list = Lists.newArrayList();
|
||||
ServerLevel serverLevel = source.getLevel();
|
||||
diff --git a/src/main/java/org/purpurmc/purpur/PurpurConfig.java b/src/main/java/org/purpurmc/purpur/PurpurConfig.java
|
||||
index 4c702a1a5b555d2fc68a80231d73018cf7e6fec6..f158f62d47a1b1df39c0c9c3006afb32475e41b7 100644
|
||||
--- a/src/main/java/org/purpurmc/purpur/PurpurConfig.java
|
||||
+++ b/src/main/java/org/purpurmc/purpur/PurpurConfig.java
|
||||
@@ -257,6 +257,7 @@ public class PurpurConfig {
|
||||
public static float commandCompassBarProgressPercent = 1.0F;
|
||||
public static int commandCompassBarTickInterval = 5;
|
||||
public static boolean commandGamemodeRequiresPermission = false;
|
||||
+ public static int commandFillMaxArea = 32768;
|
||||
public static boolean hideHiddenPlayersFromEntitySelector = false;
|
||||
public static String uptimeFormat = "<days><hours><minutes><seconds>";
|
||||
public static String uptimeDay = "%02d day, ";
|
||||
@@ -286,6 +287,7 @@ public class PurpurConfig {
|
||||
commandCompassBarTickInterval = getInt("settings.command.compass.tick-interval", commandCompassBarTickInterval);
|
||||
|
||||
commandGamemodeRequiresPermission = getBoolean("settings.command.gamemode.requires-specific-permission", commandGamemodeRequiresPermission);
|
||||
+ commandFillMaxArea = getInt("settings.command.fill.max-area", commandFillMaxArea);
|
||||
hideHiddenPlayersFromEntitySelector = getBoolean("settings.command.hide-hidden-players-from-entity-selector", hideHiddenPlayersFromEntitySelector);
|
||||
uptimeFormat = getString("settings.command.uptime.format", uptimeFormat);
|
||||
uptimeDay = getString("settings.command.uptime.day", uptimeDay);
|
||||
Reference in New Issue
Block a user