Sprites for helicopters, ground vehicles, stations and vessel types; history to live without an empty map; model parts in Cesium

Aircraft icons are one size; helicopters turn a three-frame rotor while
airborne or moving; ADS-B ground vehicles share one amber sprite and
stations/obstacles one mast; vessels get hull sprites by type and one buoy.
Going live keeps contacts until the first live answer and replaces them by
id; fast playback holds before the loaded positions end and prefetches
ahead. Cesium models move their parts from the optional model part state.
This commit is contained in:
Sameh Khamis committed 2026-11-17 15:09:54 -08:00
1 parent 624c229bc2
commit 7186f720df
97 files changed
+6586 -343

No files matched your search

+20
View File
@@ -43,6 +43,7 @@ import {
transitModelSpec,
} from '../../data/fleetModels.js';
import { createFleetModelLayer } from '../../data/fleetModelInstances.js';
import { groundVehiclePartState } from '../../data/modelPartDrivers.js';
/** Layers built so far, so each one's draw sets have ids of their own. */
let instances = 0;
@@ -944,6 +945,25 @@ export function createRendering({ state, services, parts }) {
display: fleet.display,
policy: fleet.policy,
resolveAsset: fleet.resolveAsset,
partState: vehiclePartState,
});
}
/**
* Wheels rolling at the speed it is drawn moving at (else its reported
* one), doors open while it stands at a stop.
*/
function vehiclePartState(item, table) {
const entry = item.entry;
const drawn = entry?.sample?.segmentSpeedMps;
const reported = entry?.record?.speedMps;
return groundVehiclePartState(table, {
speedMps: Number.isFinite(drawn)
? drawn
: Number.isFinite(reported)
? reported
: null,
atStop: entry?.record?.status === 'STOPPED_AT',
});
}