Station model: the docked set no longer depends on whether the model draws

Hiding the model (the Cockpit riding Tiangong) gave the docked dots back and
with them forgot that the ridden vehicle was docked, which showed the model
again the next frame, and so on: the hull flickered in the Cockpit at SZ-23
and Mengtian. The orbit-against-orbit scan now keeps its own docked set,
kept current before the show decision, and the hand-over of the dots is a
separate matter.
This commit is contained in:
Denis Groshev committed 2026-11-16 19:04:35 +01:00
1 parent 9cc077964f
commit ae9cfa4ffb
2 files changed
+39 -14

No files matched your search

+12 -6
View File
@@ -262,12 +262,18 @@ test('a station without views on its model hides it while the Cockpit rides the
f.tick();
assert.equal(f.modelItem().show, true, 'outside the Cockpit it draws');
held = true;
f.tick();
assert.equal(
f.modelItem().show,
false,
'the Cockpit camera would sit inside the hull',
);
// Frame after frame: hiding the model gives the docked dots back, and
// that must not make the layer forget the companion is docked (which
// showed the model again, and so on, every other frame).
for (let i = 0; i < 4; i++) {
f.tick();
assert.equal(
f.modelItem().show,
false,
`the Cockpit camera would sit inside the hull (tick ${i})`,
);
assert.equal(f.model._trackedOnStation(), true, `docked (tick ${i})`);
}
assert.equal(f.model._visualPosition(), null);
// Riding the station itself.
held = false;