diff --git a/arclight-common/src/main/java/io/izzel/arclight/common/mixin/core/world/entity/player/ServerPlayerMixin.java b/arclight-common/src/main/java/io/izzel/arclight/common/mixin/core/world/entity/player/ServerPlayerMixin.java index 9ee34823..101c4b3a 100644 --- a/arclight-common/src/main/java/io/izzel/arclight/common/mixin/core/world/entity/player/ServerPlayerMixin.java +++ b/arclight-common/src/main/java/io/izzel/arclight/common/mixin/core/world/entity/player/ServerPlayerMixin.java @@ -724,7 +724,9 @@ public abstract class ServerPlayerMixin extends PlayerMixin implements ServerPla @Inject(method = "doCloseContainer", at = @At("HEAD")) private void arclight$invClose(CallbackInfo ci) { if (this.containerMenu != this.inventoryMenu) { + ArclightCaptures.captureContainerOwner((ServerPlayer) (Object) this); CraftEventFactory.handleInventoryCloseEvent((ServerPlayer) (Object) this); + ArclightCaptures.resetContainerOwner(); } }