From aa5f711fe4cf959801bd64379843f06099a64d0c Mon Sep 17 00:00:00 2001 From: MayaTheShy Date: Sun, 29 Mar 2026 01:11:31 -0400 Subject: [PATCH] fix: acknowledge duplicate commands to prevent sender retries --- inventoryManager.lua | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/inventoryManager.lua b/inventoryManager.lua index 5946818..3d71c5a 100644 --- a/inventoryManager.lua +++ b/inventoryManager.lua @@ -673,6 +673,14 @@ local function main() if isCommandDuplicate(message.commandId) then log.debug("NET", "Duplicate command skipped: %s", tostring(message.commandId)) + -- Still ACK so the sender stops retrying + pcall(function() + ctx.networkModem.transmit(replyChannel, cfg.ORDER_CHANNEL, { + type = "command_ack", + commandId = message.commandId, + success = true, + }) + end) else recordCommandId(message.commandId) cleanupCommandIds()