mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-28 23:38:25 +01:00
Fix properly resend patches
This commit is contained in:
parent
1cc4c39836
commit
a47a33b837
1 changed files with 7 additions and 71 deletions
|
@ -69,17 +69,17 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||
} else if (this.gameModeForPlayer == GameType.SPECTATOR) {
|
||||
MenuProvider itileinventory = iblockdata.getMenuProvider(world, blockposition);
|
||||
@@ -0,0 +0,0 @@ public class ServerPlayerGameMode {
|
||||
|
||||
return enuminteractionresult;
|
||||
} else {
|
||||
+ // Paper start - Properly cancel usable items; Cancel only if cancelled + if the interact result is different from default response
|
||||
+ if (this.interactResult && this.interactResult != cancelledItem) {
|
||||
+ this.player.resyncUsingItem(this.player);
|
||||
+ }
|
||||
+ // Paper end - Properly cancel usable items
|
||||
return InteractionResult.PASS;
|
||||
}
|
||||
+ // Paper start - Properly cancel usable items; Cancel only if cancelled + if the interact result is different from default response
|
||||
+ else if (this.interactResult && this.interactResult != cancelledItem) {
|
||||
+ this.player.resyncUsingItem(this.player);
|
||||
+ }
|
||||
+ // Paper end - Properly cancel usable items
|
||||
}
|
||||
}
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
|
@ -118,70 +118,6 @@ diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/jav
|
|||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
@@ -0,0 +0,0 @@ import com.google.common.collect.Lists;
|
||||
import com.google.common.collect.Sets;
|
||||
import com.google.common.collect.UnmodifiableIterator;
|
||||
import com.mojang.logging.LogUtils;
|
||||
+import io.papermc.paper.util.MCUtil;
|
||||
import it.unimi.dsi.fastutil.objects.Object2DoubleArrayMap;
|
||||
import it.unimi.dsi.fastutil.objects.Object2DoubleMap;
|
||||
import java.util.Arrays;
|
||||
@@ -0,0 +0,0 @@ import net.minecraft.network.syncher.SyncedDataHolder;
|
||||
import net.minecraft.network.syncher.SynchedEntityData;
|
||||
import net.minecraft.resources.ResourceKey;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
-import io.papermc.paper.util.MCUtil;
|
||||
import net.minecraft.server.MinecraftServer;
|
||||
import net.minecraft.server.level.ServerLevel;
|
||||
import net.minecraft.server.level.ServerPlayer;
|
||||
@@ -0,0 +0,0 @@ import net.minecraft.world.phys.shapes.VoxelShape;
|
||||
import net.minecraft.world.scores.PlayerTeam;
|
||||
import net.minecraft.world.scores.ScoreHolder;
|
||||
import net.minecraft.world.scores.Team;
|
||||
-import org.slf4j.Logger;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.Location;
|
||||
-import org.bukkit.Server;
|
||||
import org.bukkit.block.BlockFace;
|
||||
import org.bukkit.command.CommandSender;
|
||||
-import org.bukkit.craftbukkit.event.CraftPortalEvent;
|
||||
-import org.bukkit.entity.Hanging;
|
||||
-import org.bukkit.entity.LivingEntity;
|
||||
-import org.bukkit.entity.Vehicle;
|
||||
-import org.bukkit.event.entity.EntityCombustByEntityEvent;
|
||||
-import org.bukkit.event.hanging.HangingBreakByEntityEvent;
|
||||
-import org.bukkit.event.vehicle.VehicleBlockCollisionEvent;
|
||||
-import org.bukkit.event.vehicle.VehicleEnterEvent;
|
||||
-import org.bukkit.event.vehicle.VehicleExitEvent;
|
||||
import org.bukkit.craftbukkit.CraftWorld;
|
||||
import org.bukkit.craftbukkit.entity.CraftEntity;
|
||||
import org.bukkit.craftbukkit.entity.CraftPlayer;
|
||||
import org.bukkit.craftbukkit.event.CraftEventFactory;
|
||||
+import org.bukkit.craftbukkit.event.CraftPortalEvent;
|
||||
import org.bukkit.craftbukkit.util.CraftLocation;
|
||||
+import org.bukkit.entity.Hanging;
|
||||
+import org.bukkit.entity.LivingEntity;
|
||||
import org.bukkit.entity.Pose;
|
||||
+import org.bukkit.entity.Vehicle;
|
||||
import org.bukkit.event.entity.EntityAirChangeEvent;
|
||||
+import org.bukkit.event.entity.EntityCombustByEntityEvent;
|
||||
import org.bukkit.event.entity.EntityCombustEvent;
|
||||
import org.bukkit.event.entity.EntityDismountEvent;
|
||||
import org.bukkit.event.entity.EntityDropItemEvent;
|
||||
@@ -0,0 +0,0 @@ import org.bukkit.event.entity.EntityMountEvent;
|
||||
import org.bukkit.event.entity.EntityPortalEvent;
|
||||
import org.bukkit.event.entity.EntityPoseChangeEvent;
|
||||
import org.bukkit.event.entity.EntityRemoveEvent;
|
||||
+import org.bukkit.event.hanging.HangingBreakByEntityEvent;
|
||||
import org.bukkit.event.player.PlayerTeleportEvent;
|
||||
+import org.bukkit.event.vehicle.VehicleBlockCollisionEvent;
|
||||
+import org.bukkit.event.vehicle.VehicleEnterEvent;
|
||||
+import org.bukkit.event.vehicle.VehicleExitEvent;
|
||||
import org.bukkit.plugin.PluginManager;
|
||||
+import org.slf4j.Logger;
|
||||
// CraftBukkit end
|
||||
|
||||
public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess, CommandSource, ScoreHolder {
|
||||
@@ -0,0 +0,0 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
|
||||
|
||||
// CraftBukkit start
|
||||
|
|
Loading…
Reference in a new issue