From e5848f0e799642ee9da7e2a8b99ab8c902935ba1 Mon Sep 17 00:00:00 2001 From: Moonlit Productions Date: Mon, 29 Dec 2025 21:22:00 -0500 Subject: [PATCH] Something is voiding the iris, lets fix that.. also open on outgoing --- display.lua | 2 +- startup.lua | 15 +++++++++++---- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/display.lua b/display.lua index 65a6074..2b95f76 100644 --- a/display.lua +++ b/display.lua @@ -159,7 +159,7 @@ function display.showIncoming(addressName, addressString, allowed, reason) mon.setCursorPos(1, 6) mon.setBackgroundColor(colors.black) - + -- Show name if found in address book if addressName then mon.write("Name: " .. addressName) diff --git a/startup.lua b/startup.lua index 179d42e..7fdc006 100644 --- a/startup.lua +++ b/startup.lua @@ -249,8 +249,8 @@ end local function findAddressName(address) -- Search all address categories for matching address - local categories = {addresses.MainGates, addresses.playerGates, addresses.hazardGates} - + local categories = { addresses.MainGates, addresses.playerGates, addresses.hazardGates } + for _, category in ipairs(categories) do for _, entry in ipairs(category) do local name, storedAddress = entry[1], entry[2] @@ -269,7 +269,7 @@ local function findAddressName(address) end end end - + return nil -- Not found in address book end @@ -291,7 +291,7 @@ local function handleIncomingWormhole() -- Check security local allowed, reason = utils.isAddressAllowed(state.incomingAddress) local addressString = gate.addressToString(state.incomingAddress) or "Unknown" - + -- Look up address name in address book local addressName = findAddressName(state.incomingAddress) @@ -308,6 +308,8 @@ local function handleIncomingWormhole() if config.autoCloseIrisOnIncoming then sleep(config.irisCloseDelay) if allowed then + -- Wait 2 seconds after connection established before opening iris + sleep(2) utils.openIris() else utils.closeIris() @@ -547,6 +549,11 @@ local function handleOutgoingDial() os.pullEvent("stargate_outgoing_wormhole") + -- Open local iris for outgoing connection + if config.irisEnabled then + utils.openIris() + end + -- Wait briefly for version message from remote gate state.remoteHasComputer = false local function WaitForVersion()