Skip to content

fix vessel recovery#782

Merged
djungelorm merged 1 commit intokrpc:mainfrom
JonnyOThan:fix-vessel-recovery
Mar 14, 2024
Merged

fix vessel recovery#782
djungelorm merged 1 commit intokrpc:mainfrom
JonnyOThan:fix-vessel-recovery

Conversation

@JonnyOThan
Copy link
Contributor

@JonnyOThan JonnyOThan commented Mar 13, 2024

I've been using something similar to this in tpksp for years. Calling the event directly can spew nullrefs and softlock you out of buildings.

My initial fix was to add a component that fires the event in LateUpdate, but this also works and is simpler (tested on my stream).

I suspect the issue occurs because the event is normally fired from the stock ui code which runs late in the frame.

for reference, I originally hit this in RPM with the vessel recovery prop. This is the code I’d been using in tpksp as well: https://github.com/JonnyOThan/RasterPropMonitor/blob/958720c1d9ad2145cacf5f5098d8984682f5e00e/RasterPropMonitor/Core/JSIVesselRecovery.cs#L27

@djungelorm djungelorm added bug Something isn't working service:space-center labels Mar 14, 2024
@djungelorm djungelorm added this to the Next bug fix release milestone Mar 14, 2024
@djungelorm djungelorm merged commit 9787904 into krpc:main Mar 14, 2024
@JonnyOThan JonnyOThan deleted the fix-vessel-recovery branch March 18, 2024 16:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working service:space-center

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants