From d27075cb38342823099e041ca3adbe2bde9fc7ee Mon Sep 17 00:00:00 2001 From: Athanasius Date: Thu, 29 Apr 2021 12:28:45 +0100 Subject: [PATCH] Suits: Handle `LoadoutEquipModule` event We're assuming weapons only at this point. Might need adjustment when we get access to engineering. --- monitor.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/monitor.py b/monitor.py index 76de2d98..cac535bc 100644 --- a/monitor.py +++ b/monitor.py @@ -1072,7 +1072,14 @@ class EDLogs(FileSystemEventHandler): # type: ignore # See below # "SuitID":1698364940285172, "SuitName":"tacticalsuit_class1", "SuitName_Localised":"Dominator Suit", # "LoadoutID":4293000001, "SlotName":"PrimaryWeapon2", "ModuleName":"wpn_m_assaultrifle_laser_fauto", # "ModuleName_Localised":"TK Aphelion", "SuitModuleID":1698372938719590 } - pass + loadout_id = self.suit_loadout_id_from_loadoutid(entry['LoadoutID']) + self.state['SuitLoadouts'][loadout_id]['slots'][entry['SlotName']] = { + 'name': entry['ModuleName'], + 'locName': entry.get('ModuleName_Localised', entry['ModuleName']), + 'id': None, + 'weaponrackId': entry['SuitModuleID'], + 'locDescription': '', + } elif event_type == 'LoadoutRemoveModule': # alpha4