Remap CraftBukkit to Mojang+Yarn Mappings

By: Initial Source <noreply+automated@papermc.io>
This commit is contained in:
CraftBukkit/Spigot
2024-12-11 22:26:55 +01:00
parent a265d64138
commit 30e4583dbe
1780 changed files with 44628 additions and 41274 deletions

View File

@@ -0,0 +1,11 @@
--- a/net/minecraft/commands/arguments/selector/EntitySelector.java
+++ b/net/minecraft/commands/arguments/selector/EntitySelector.java
@@ -93,7 +93,7 @@
}
private void checkPermissions(CommandSourceStack source) throws CommandSyntaxException {
- if (this.usesSelector && !source.hasPermission(2)) {
+ if (this.usesSelector && !source.hasPermission(2, "minecraft.command.selector")) { // CraftBukkit
throw EntityArgument.ERROR_SELECTORS_NOT_ALLOWED.create();
}
}

View File

@@ -1,11 +0,0 @@
--- a/net/minecraft/commands/arguments/selector/EntitySelector.java
+++ b/net/minecraft/commands/arguments/selector/EntitySelector.java
@@ -93,7 +93,7 @@
}
private void checkPermissions(CommandListenerWrapper commandlistenerwrapper) throws CommandSyntaxException {
- if (this.usesSelector && !commandlistenerwrapper.hasPermission(2)) {
+ if (this.usesSelector && !commandlistenerwrapper.hasPermission(2, "minecraft.command.selector")) { // CraftBukkit
throw ArgumentEntity.ERROR_SELECTORS_NOT_ALLOWED.create();
}
}

View File

@@ -1,11 +1,11 @@
--- a/net/minecraft/commands/arguments/selector/ArgumentParserSelector.java
+++ b/net/minecraft/commands/arguments/selector/ArgumentParserSelector.java
--- a/net/minecraft/commands/arguments/selector/EntitySelectorParser.java
+++ b/net/minecraft/commands/arguments/selector/EntitySelectorParser.java
@@ -158,7 +158,7 @@
axisalignedbb = this.createAabb(this.deltaX == null ? 0.0D : this.deltaX, this.deltaY == null ? 0.0D : this.deltaY, this.deltaZ == null ? 0.0D : this.deltaZ);
}
- Function function;
+ Function<Vec3D, Vec3D> function; // CraftBukkit - decompile error
+ Function<Vec3, Vec3> function; // CraftBukkit - decompile error
if (this.x == null && this.y == null && this.z == null) {
function = (vec3d) -> {
@@ -21,13 +21,13 @@
+ // CraftBukkit end
this.suggestions = this::suggestSelector;
if (!this.reader.canRead()) {
throw ArgumentParserSelector.ERROR_MISSING_SELECTOR_TYPE.createWithContext(this.reader);
throw EntitySelectorParser.ERROR_MISSING_SELECTOR_TYPE.createWithContext(this.reader);
@@ -505,6 +507,12 @@
}
public EntitySelector parse() throws CommandSyntaxException {
+ // CraftBukkit start
+ return parse(false);
+ return this.parse(false);
+ }
+
+ public EntitySelector parse(boolean overridePermissions) throws CommandSyntaxException {