mirror of
https://hub.spigotmc.org/stash/scm/spigot/craftbukkit.git
synced 2024-11-25 06:56:14 +00:00
28 lines
1.4 KiB
Diff
28 lines
1.4 KiB
Diff
--- a/net/minecraft/world/item/component/SuspiciousStewEffects.java
|
|
+++ b/net/minecraft/world/item/component/SuspiciousStewEffects.java
|
|
@@ -29,7 +29,7 @@
|
|
public static final StreamCodec<RegistryFriendlyByteBuf, SuspiciousStewEffects> STREAM_CODEC = SuspiciousStewEffects.a.STREAM_CODEC.apply(ByteBufCodecs.list()).map(SuspiciousStewEffects::new, SuspiciousStewEffects::effects);
|
|
|
|
public SuspiciousStewEffects withEffectAdded(SuspiciousStewEffects.a suspicioussteweffects_a) {
|
|
- return new SuspiciousStewEffects(SystemUtils.copyAndAdd(this.effects, (Object) suspicioussteweffects_a));
|
|
+ return new SuspiciousStewEffects(SystemUtils.copyAndAdd(this.effects, suspicioussteweffects_a)); // CraftBukkit - decompile error
|
|
}
|
|
|
|
@Override
|
|
@@ -44,6 +44,15 @@
|
|
|
|
}
|
|
|
|
+ // CraftBukkit start
|
|
+ @Override
|
|
+ public void cancelUsingItem(net.minecraft.server.level.EntityPlayer entityplayer, ItemStack itemstack) {
|
|
+ for (SuspiciousStewEffects.a suspicioussteweffects_a : this.effects) {
|
|
+ entityplayer.connection.send(new net.minecraft.network.protocol.game.PacketPlayOutRemoveEntityEffect(entityplayer.getId(), suspicioussteweffects_a.effect()));
|
|
+ }
|
|
+ }
|
|
+ // CraftBukkit end
|
|
+
|
|
@Override
|
|
public void addToTooltip(Item.b item_b, Consumer<IChatBaseComponent> consumer, TooltipFlag tooltipflag) {
|
|
if (tooltipflag.isCreative()) {
|