diff --git a/app/ecs/components/inventory.js b/app/ecs/components/inventory.js index 948e27a..8a2ff44 100644 --- a/app/ecs/components/inventory.js +++ b/app/ecs/components/inventory.js @@ -215,7 +215,9 @@ export default class Inventory extends Component { delete otherSlots[r]; } Component.markChange(this.entity, 'swapped', [[l, OtherInventory.entity, r]]); - Component.markChange(OtherInventory.entity, 'swapped', [[r, this.entity, l]]); + if (this.entity !== OtherInventory.entity) { + Component.markChange(OtherInventory.entity, 'swapped', [[r, this.entity, l]]); + } } toNet(recipient, data) { if (recipient.id !== this.entity && this !== recipient.Player.openInventory) {