Use typed docking documents in Unity docking index
This commit is contained in:
parent
16c6211d4a
commit
d54af47ff5
2 changed files with 33 additions and 5 deletions
|
|
@ -167,7 +167,20 @@ public sealed class AetheriaUnityObservedDockingIndex : IDisposable
|
|||
docking = null;
|
||||
try
|
||||
{
|
||||
docking = _resolveClient()?.State?.CurrentDocking();
|
||||
var state = _resolveClient()?.State;
|
||||
if (state == null)
|
||||
return false;
|
||||
|
||||
var currentEntity = state.Current.LatestEntity();
|
||||
var currentDocking = state.Current.LatestDocking();
|
||||
var stationRefit = state.LatestStationRefit();
|
||||
if (currentDocking == null || stationRefit == null)
|
||||
return false;
|
||||
|
||||
docking = new AetheriaRuntimeObservedDockingState(
|
||||
currentEntity,
|
||||
currentDocking,
|
||||
stationRefit);
|
||||
return docking != null;
|
||||
}
|
||||
catch
|
||||
|
|
|
|||
Loading…
Reference in a new issue