mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-04 22:22:18 -07:00
SPIGOT-4046: Fix selectors in tick functions
This commit is contained in:
@@ -9,3 +9,19 @@
|
||||
|
||||
if (parseresults.getReader().canRead()) {
|
||||
if (parseresults.getExceptions().size() == 1) {
|
||||
@@ -142,7 +142,14 @@
|
||||
}
|
||||
|
||||
public void a(CustomFunctionData customfunctiondata, CommandListenerWrapper commandlistenerwrapper, ArrayDeque<CustomFunctionData.a> arraydeque, int i) throws CommandSyntaxException {
|
||||
- customfunctiondata.d().execute(new ParseResults(this.a.getContext().withSource(commandlistenerwrapper), this.a.getReader(), this.a.getExceptions()));
|
||||
+ // CraftBukkit start
|
||||
+ org.bukkit.craftbukkit.command.VanillaCommandWrapper.WorldRescueContext rescue = new org.bukkit.craftbukkit.command.VanillaCommandWrapper.WorldRescueContext().start(commandlistenerwrapper.getWorld());
|
||||
+ try {
|
||||
+ customfunctiondata.d().execute(new ParseResults(this.a.getContext().withSource(commandlistenerwrapper), this.a.getReader(), this.a.getExceptions()));
|
||||
+ } finally {
|
||||
+ rescue.end();
|
||||
+ }
|
||||
+ // CraftBukkit end
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
|
Reference in New Issue
Block a user