Don't restore item on toss event cancel when dead. Fixes
@@ -925,6 +925,11 @@ private static Tristate getTristateFromResult(Result result) {
ItemTossEvent forgeEvent = new ItemTossEvent(item, (EntityPlayerMP) entity);
((IMixinEventBus) MinecraftForge.EVENT_BUS).post(forgeEvent, true);
if (forgeEvent.isCanceled()) {
+ if (item.isDead) {
+ // Don't restore packet item if a mod wants it dead
+ // Mods such as Flux-Networks kills the entity item to spawn a custom one
+ return spongeEvent;
+ }
spongeEvent.setCancelled(true);
} else {
// Forge treats EntityJoinWorldEvent separately from Toss so we need to call it here
