Athanasius
652fecc3e8
SuitLoadout: Attempt to get all state set correctly.
...
I think this is now correct, but not yet triggering the unhide of the
'Suit' UI line, will check that next.
2021-05-20 10:51:49 +01:00
Athanasius
eeed2cf7af
Initial attempt at SuitLoadout
event support
...
Need to see examples to be sure.
2021-05-18 22:42:27 +01:00
Athanasius
a50ed31450
Add note about maybe not wanting to use UseConsumable to track Backpack
...
*Hopefully* `BackpackChange` will be 100% reliable in place of this.
Test once live Odyssey is available!
2021-05-18 22:42:27 +01:00
Athanasius
bcbf37599e
Odyssey Backpack: Add support for v31 Backpack
and BackpackChange
...
Leaving the, meant to be defunct, `BackPackMaterials` code in for now,
as it's only one extra conditional that will never be stepped into if
the event never happens.
Yes, Frontier now uses 'Backpack' not 'BackPack', but we've already
published our plugin API as using the CamelCase version, so not changing
the monitor.state key.
2021-05-18 22:42:27 +01:00
Athanasius
286060a796
monitor: Add state flag 'Odyssey' for if LoadGame states we're running under Odyssey
2021-05-12 17:54:39 +01:00
Athanasius
aaf1fda1a1
Credits: Be paranoid about all related Journal events
...
MissionCompleted doesn't contain 'Reward' if you pick an option without
a credits amount (rather than being there but with zero value).
Let's not wait to find out about other exceptions, just utilise
entry.get(<field>, 0) on them all.
2021-05-08 19:25:38 +01:00
Athanasius
f1ca2b8283
Separate 'Docked' processing to own conditional.
...
A taxi 'Docked' event has much less data than an own-ship one. Rather
than put tortured conditionals into the
Location/FSDJump/CarrierJump/Docked conditional I've split Docked into
its own.
There should always be one of the other events to set things like
SystemAddress before a 'Docked' event, so limiting the new conditional
to setting/changing only the station-related state variables.
2021-05-05 12:20:24 +01:00
Athanasius
692856bbe1
Disembark: Use the alpha4-new flag to detect if on-station
2021-05-05 11:42:29 +01:00
Athanasius
5f29c866e7
Dropship: Set OnFoot for DropshipDeploy, but ignore BookDropship
...
See the comment added to BookDropship code for why we're ignoring it.
2021-05-05 11:34:10 +01:00
Athanasius
543e0477c2
Don't assume ModuleRetrieve/Store have a Cost.
...
The Journal doc says they do, but one report of ModuleRetrieve saying it
doesn't, and ModuleStore does say "Cost (if any)".
2021-05-05 10:01:07 +01:00
Athanasius
f6cb69ebad
Embark: Keep monitor.station set when Embarking OnStation.
2021-05-01 13:12:14 +01:00
Athanasius
7c7609f2ee
Cargo: Update ship cargo on CargoTransfer
event
...
We missed this when it was brought in with Fleet Carriers in 2020.
2021-05-01 12:15:57 +01:00
Athanasius
812398ee0d
Credits: Review and add/tweak code for all Journal events
...
There are a few where either the v30 Journal doc is wrong/has an
ommision, or we genuinely don't get the required information.
2021-05-01 12:03:45 +01:00
Athanasius
77d96f61c7
Odyssey Credits: Update for book/cancel Taxi/Dropship
2021-05-01 10:50:20 +01:00
Athanasius
d74b886587
Update credits for SellOrganicData
2021-05-01 10:46:25 +01:00
Athanasius
751002bf1a
Suits: Guards for if we don't have CAPI data yet
...
We still need each try/except in case:
1. Journal has you buying a suit, or creating a SuitLoadout.
2. It then has you selling/deleting a different one.
3. But no CAPI data yet, so we don't know about that different one.
2021-05-01 10:42:54 +01:00
Athanasius
81104ca973
Suits: Only debug log if we can't find loadout for DeleteSuitLoadout
2021-05-01 10:31:08 +01:00
Athanasius
0e18666054
Suits: Only process SwitchSuitLoadout
if we know about Suits and Loadouts
2021-05-01 10:25:39 +01:00
Athanasius
3ab8b97562
Suits: We might not know about SuitLoadout being switched to
2021-05-01 10:19:10 +01:00
Athanasius
6d58863a40
Suits: Fix 'mame' typo
2021-04-30 15:42:10 +01:00
Athanasius
60b2045ea4
Items: Fix DropItems
and CollectItems
...
Tested as actually working.
2021-04-30 15:21:47 +01:00
Athanasius
e1a63c2879
Items: Correct UseConsumable
code
2021-04-30 15:12:12 +01:00
Athanasius
f89ed7999e
Items: Implement CollectItems
, DropItems
and UseConsumable
...
The paranoia when subtracting from counts is because of the lack of
fresh `BackPackMaterials` if relogging whilst on foot.
2021-04-30 14:44:20 +01:00
Athanasius
422b766586
Items: Decrement BackPack Consumable on UseConsumable
2021-04-30 14:30:37 +01:00
Athanasius
1f8215ed92
Items: ShipLockerMaterials
now has Data
...
But also, we're not getting a `BackPackMaterials` at the same time to be
sure of the state of things.
2021-04-30 13:56:26 +01:00
Athanasius
8e8c9fa3ff
Items: Data
is now in BackPackMaterials
as well
2021-04-30 13:50:52 +01:00
Athanasius
eed4402340
Suits: Init monitor.state['Suits'] to empty dict
2021-04-30 10:53:38 +01:00
Athanasius
30b8a5eead
Suits: Log if a buy/sell event doesn't contain Price
2021-04-30 10:49:39 +01:00
Athanasius
203fb051b0
Suits: Simplify BuySuit
code.
2021-04-30 10:47:09 +01:00
Athanasius
ac4f052695
Suits: Update credits on BuyWeapon
...
Also cleaning out some verbose comments.
2021-04-29 12:38:01 +01:00
Athanasius
7b76e327ce
Suits: Always set 'id' to None
...
Better to get a `None` value than a KeyError.
2021-04-29 12:32:31 +01:00
Athanasius
d27075cb38
Suits: Handle LoadoutEquipModule
event
...
We're assuming weapons only at this point. Might need adjustment when
we get access to engineering.
2021-04-29 12:28:45 +01:00
Athanasius
d35f64ebd5
Suits: Handle LoadoutRemoveModule
...
Currently this seems to only trigger if you 'overwrite' an equipped
weapon with another one. The one being removed will be cited in this
event.
2021-04-29 12:21:08 +01:00
Athanasius
218073ed73
Suits: Remove weapon from all loadouts if sold.
...
Also update credits total for the sale.
2021-04-29 12:07:48 +01:00
Athanasius
2253e45c18
Suits: Add some paranoia around Loadouts
...
* Initialise to empty dict.
* try/except in case CAPI pull hasn't happened yet when parsing Journal
events.
2021-04-29 11:45:06 +01:00
Athanasius
e796684fc6
Suits: Handle RenameSuitLoadout
2021-04-29 11:40:59 +01:00
Athanasius
e24e0b3547
Suits: Update DeleteSuitLoadout
code with alpha4 example
...
Also slightly simplified this. Leaving the try/except for now, although
it should no longer be necessary.
2021-04-29 11:34:29 +01:00
Athanasius
addb178d3d
Suits: Handle 'CreateSuitLoadout'
...
This entails converting the Journal supplied data into CAPI form.
2021-04-29 11:23:14 +01:00
Athanasius
29a517ce11
Suits: Note that we need an 'UpgradeSuit' example still
...
The journal document has to be mistaken about cost being in credits.
2021-04-29 10:34:03 +01:00
Athanasius
aeca211a88
Suits: Handle 'SellSuit'
2021-04-29 10:26:55 +01:00
Athanasius
c8d98bba2e
suits: Guard against "no CAPI pull yet" on BuySuit
2021-04-29 10:23:39 +01:00
Athanasius
7b8c113962
suits: Record a newly bought suit in monitor.state['Suits']
...
We can't fill in the 'id' field, but this is likely the FDevID of the
suit type ?
2021-04-29 10:12:49 +01:00
Athanasius
96d9a80956
odyssey-4: Add outlines/comments for all upcoming events
2021-04-27 11:54:15 +01:00
Athanasius
f6611148e6
Suits: Add Artemis (ExplorationSuit_Class1) suit to ON_FOOT regex
2021-04-15 16:38:56 +01:00
Athanasius
8e8e57024d
Suits: Location Ship "TacticalSuit_Class1" is also on-foot
...
This is the 'Dominator' suit.
2021-04-15 14:20:00 +01:00
Athanasius
d9d36dd12b
Suits: Comments about suit/weapon events not having instance ID
2021-04-15 10:55:51 +01:00
Athanasius
d095e8b054
Suits: We can't do anything on SellSuit
yet, placeholder.
2021-04-15 10:43:42 +01:00
Athanasius
550ca61e44
Suits: Support DeleteSuitLoadout
event
...
* Factored "find CAPI slot id from journal LoadoutID" into its own
function.
2021-04-14 10:16:34 +01:00
Athanasius
1509bcde2b
Suits: Placeholders for DeleteSuitLoadout and CreateSuitLoadout
2021-04-14 10:01:36 +01:00
Athanasius
bb90d0fb59
Suits: If user switches to an unknown loadout, say so
2021-04-13 16:56:48 +01:00