mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-19 09:42:21 +00:00
- Clicks: when two tools want the globe's clicks, the newest takes them and the older is told and turns itself off; a click is decided when it arrives, and ambient selection fires only when no tool holds the pointer. The "map is busy" paths and their strings are removed. - Recession: the limb fade is shared (src/render/recession.js) and reaches icon and model sets through SetSpec.recede; tuning applies on the next frame. - Display panel groups are published through src/ui/displayGroups.js; the Weather group and src/viewWeather.js are removed. - Draw port: a set whose icons only move is moved in place, and models that did not change are not restyled each frame, so moving fleets cost what they did when drawn directly; an untinted, fully opaque model is drawn without a colour. - Conformance: input.lease.lost checks the new lease inside onLost and reports a throwing onLost; draw.sets.recede covers model sets. - QA scripts read the renderer host instead of internals the seam replaced.
67 lines
2.1 KiB
JavaScript
67 lines
2.1 KiB
JavaScript
import { createDirectionsSource } from '../layers/directions/source.js';
|
|
/**
|
|
* @module directions
|
|
* @description Service bundle for the Directions layer.
|
|
*
|
|
* The layer itself lives in `src/layers/directions/`, which imports nothing
|
|
* but the renderer's draw port, geodesy and the pure step formatter. This
|
|
* module is the one place that names the application's shared services —
|
|
* the render governor, sprite order, the pick registry, the world overlay,
|
|
* the camera verbs, the shared ground floor and the pointer arbiter — and it
|
|
* re-exports the layer's pure helpers for the tests and the share-link code.
|
|
*/
|
|
|
|
import * as credits from './dataCredits.js';
|
|
import * as render from '../renderGovernor.js';
|
|
import * as sprites from './spriteOrder.js';
|
|
import * as picking from './pickRegistry.js';
|
|
import * as overlays from '../overlays/worldOverlay.js';
|
|
import * as camera from '../cameraVerbs.js';
|
|
import * as ground from './groundFloor.js';
|
|
import * as input from './inputOwnership.js';
|
|
import { createDirectionsLayer } from '../layers/directions/index.js';
|
|
|
|
/** The shared scene owners every Directions instance runs on. */
|
|
const directionsServices = Object.freeze({
|
|
credits,
|
|
render,
|
|
sprites,
|
|
picking,
|
|
overlays,
|
|
camera,
|
|
ground,
|
|
input,
|
|
});
|
|
|
|
/** Construct one Directions layer over the application scene owners. */
|
|
export function createApplicationDirectionsLayer({
|
|
source = createDirectionsSource(),
|
|
} = {}) {
|
|
return createDirectionsLayer({ services: directionsServices, source });
|
|
}
|
|
|
|
export {
|
|
DEFAULT_DIRECTIONS_MODE,
|
|
DIRECTIONS_MODES,
|
|
DIRECTIONS_POINTER_OWNER,
|
|
DIRECTIONS_ROUTE_COLOR,
|
|
STEP_ANCHOR_DEADLINE_MS,
|
|
STEP_ANCHOR_FAST_ATTEMPTS,
|
|
STEP_ANCHOR_RETRY_MS,
|
|
STEP_ANCHOR_SLOW_RETRY_MS,
|
|
DIRECTIONS_MARKER_OVERLAY_SOURCE_ID,
|
|
createDirectionsMarkerOverlayEntry,
|
|
createDirectionsStepOverlayEntry,
|
|
directionsRequestUrl,
|
|
directionsRowControls,
|
|
directionsStats,
|
|
directionsStepCopy,
|
|
directionsStepList,
|
|
normalizeDirectionsParams,
|
|
normalizeRoutePayload,
|
|
stepAnchorDelayMs,
|
|
stepIndexAtDistance,
|
|
stepMarkerHeightM,
|
|
stepMarkerIndices,
|
|
} from '../layers/directions/index.js';
|