From b3cef1e29b8b51fa1f236840f718ade4fac7e2dd Mon Sep 17 00:00:00 2001 From: Athanasius Date: Tue, 30 Mar 2021 15:11:12 +0100 Subject: [PATCH] Server Lagging check now works again. Well, it doesn't now raise ServerLagging for a last Journal with a LoadGame on-foot and in-station. It does then cause "You're not docked at a station!" to show up. --- EDMarketConnector.py | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/EDMarketConnector.py b/EDMarketConnector.py index baace9bc..96634086 100755 --- a/EDMarketConnector.py +++ b/EDMarketConnector.py @@ -784,12 +784,18 @@ class AppWindow(object): # CAPI system must match last journal one raise companion.ServerLagging() - elif (monitor.on_foot and monitor.station - and data['lastStarport']['name'] != monitor.station # On foot station must match if set - or ((data['commander']['docked'] and data['lastStarport']['name'] or None) - != monitor.station) # CAPI lastStarport must match - ): - raise companion.ServerLagging() + elif data['lastStarport']['name'] != monitor.station: + if monitor.on_foot and monitor.station: + raise companion.ServerLagging() + + else: + last_station = None + if data['commander']['docked']: + last_station = data['lastStarport']['name'] + + if last_station != monitor.station: + # CAPI lastStarport must match + raise companion.ServerLagging() elif not monitor.on_foot and data['ship']['id'] != monitor.state['ShipID']: # CAPI ship must match