From 284847cd81735292d328d7190c157065c007946d Mon Sep 17 00:00:00 2001 From: md_5 Date: Sun, 24 Mar 2013 18:53:01 +1100 Subject: [PATCH] Close Minecart containers on Entity portal. --- .../0044-Close-Minecart-Containers.patch | 29 +++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 CraftBukkit-Patches/0044-Close-Minecart-Containers.patch diff --git a/CraftBukkit-Patches/0044-Close-Minecart-Containers.patch b/CraftBukkit-Patches/0044-Close-Minecart-Containers.patch new file mode 100644 index 000000000..aac8d4c1e --- /dev/null +++ b/CraftBukkit-Patches/0044-Close-Minecart-Containers.patch @@ -0,0 +1,29 @@ +From 58995adb5304f5f8cc8e87c11204ad12e209157c Mon Sep 17 00:00:00 2001 +From: md_5 +Date: Sun, 24 Mar 2013 18:52:26 +1100 +Subject: [PATCH] Close Minecart Containers + +Close Minecart containers when they change worlds via entity portal. +--- + src/main/java/net/minecraft/server/EntityMinecartContainer.java | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/src/main/java/net/minecraft/server/EntityMinecartContainer.java b/src/main/java/net/minecraft/server/EntityMinecartContainer.java +index c207076..74f579d 100644 +--- a/src/main/java/net/minecraft/server/EntityMinecartContainer.java ++++ b/src/main/java/net/minecraft/server/EntityMinecartContainer.java +@@ -149,6 +149,11 @@ public abstract class EntityMinecartContainer extends EntityMinecartAbstract imp + } + + public void c(int i) { ++ // Spigot start ++ for (HumanEntity h : transaction) { ++ ((org.bukkit.craftbukkit.entity.CraftHumanEntity) h).getHandle().closeInventory(); ++ } ++ // Spigot end + this.b = false; + super.c(i); + } +-- +1.8.1-rc2 +