@bendyline/molen-client 0.0.11 → 0.0.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -66,6 +66,7 @@ probe — a pinned backend is what makes a captured frame reproducible.
66
66
  | `./camera-track` | `molen/cameratrack@1`: `registerCameraTrackSchema` + `evaluateCameraTrack` for scripted camera moves |
67
67
  | `./vite` | `molenScripts()` — a Vite plugin that type-strips `*.ts?raw` scene scripts so the browser never sees TypeScript |
68
68
  | `./vehicles` | `createVehicleVisual`, `createParkedVehicleBatch`, `vehicleCameraPose` — car visuals and cockpit/chase views, the render half of `@bendyline/molen-kernel/vehicles` |
69
+ | `./glass` | `createGlassVisual` — retained laminate cracks, released sheets and bounded glass fragments |
69
70
  | `./aircraft` | `createAircraftVisual`, `aircraftCameraPose` — animated airframe and instrumented cockpit, the render half of `@bendyline/molen-kernel/aircraft` |
70
71
  | `./instruments` | Named signal expressions and reusable wiring for calibrated dials, altimeters, attitude indicators, annunciators and seven-segment readouts; geometry stays in each model |
71
72
  | `./navigation` | `OrbitController`, `FlyController`, `WalkController` + `WalkCollision`, `FollowController`, `NavigationInputSource` (keys, gamepad, pointer gestures) and `createTouchJoystick` — camera navigation for `createViewer` hosts |
@@ -1,10 +1,10 @@
1
+ import { a as VehicleCameraPose, c as aircraftObstacleContacts, i as VehicleCameraOptions, n as VehicleInteriorVisual, s as AircraftObstacleScene } from "./vehicle-interior-B8TpzTAx.mjs";
1
2
  import { n as ModelSignals, t as ModelSignalVisual } from "./model-signals-BpeXhsim.mjs";
2
- import { a as VehicleCameraPose, i as VehicleCameraOptions, n as VehicleInteriorVisual } from "./vehicle-interior-BgcC750p.mjs";
3
- import { AircraftCollisionProbe, AircraftContact, AircraftInputData, AircraftSpec, AircraftStateData, LiveryData, VehicleSpec } from "@bendyline/molen-schema";
3
+ import { AircraftInputData, AircraftSpec, AircraftStateData, LiveryData } from "@bendyline/molen-schema";
4
4
  import * as THREE from "three";
5
5
 
6
6
  //#region src/aircraft-controls.d.ts
7
- type AircraftControlAction = "power" | "mixture" | "propeller" | "stick" | "yaw" | "gear" | "flaps" | "engine" | "brake" | "thrustVector";
7
+ type AircraftControlAction = "speedBrake" | "tailHook" | "canopy" | "wipers" | "headlights" | "power" | "mixture" | "propeller" | "stick" | "yaw" | "gear" | "flaps" | "engine" | "brake" | "thrustVector";
8
8
  interface AircraftCockpitControl {
9
9
  id: string;
10
10
  label: string;
@@ -79,30 +79,6 @@ interface AircraftCockpitPointerOptions {
79
79
  }
80
80
  declare function bindAircraftCockpitPointer(options: AircraftCockpitPointerOptions): AircraftCockpitPointer;
81
81
  //#endregion
82
- //#region src/aircraft-collision.d.ts
83
- interface AircraftObstacleScene {
84
- /** Collision tree origin and query, e.g. WalkCollision. */
85
- origin: THREE.Vector3;
86
- octree: {
87
- sphereIntersect(sphere: THREE.Sphere): false | {
88
- normal: THREE.Vector3;
89
- depth: number;
90
- };
91
- getSphereTriangles?(sphere: THREE.Sphere, triangles: THREE.Triangle[]): unknown;
92
- };
93
- cars: ReadonlyArray<{
94
- transform: {
95
- pos: [number, number, number];
96
- rot: [number, number, number, number];
97
- };
98
- spec: VehicleSpec;
99
- }>;
100
- /** Other aircraft body centers. The host excludes the queried aircraft. */
101
- aircraft: ReadonlyArray<[number, number, number]>;
102
- }
103
- /** Contact normals from streamed geometry and nearby parked vehicles, in absolute coordinates. */
104
- declare function aircraftObstacleContacts(probes: readonly AircraftCollisionProbe[], scene: AircraftObstacleScene): AircraftContact[];
105
- //#endregion
106
82
  //#region src/aircraft.d.ts
107
83
  interface AircraftVisual {
108
84
  setLivery(data: LiveryData | undefined): void;
@@ -113,10 +89,12 @@ interface AircraftVisual {
113
89
  animation?: ModelSignalVisual;
114
90
  update(state: AircraftStateData, input: AircraftInputData, altitude: number, signals?: ModelSignals, timeSeconds?: number): void;
115
91
  /**
116
- * The camera, in the coordinates of `object.position`. Cabin nodes (the spec's interior) are
117
- * drawn only near it: from farther away a cockpit is a few pixels behind the canopy, yet it held
118
- * most of an aircraft's draw calls, and as many again in the shadow pass. Boarded and chase
119
- * views are always near enough.
92
+ * The camera, in the coordinates of `object.position`. Cabin nodes (the spec's interior and the
93
+ * generated flight controls) are drawn only near it: from farther away a cockpit is a few pixels
94
+ * behind the canopy, yet it held most of an aircraft's draw calls, and as many again in the
95
+ * shadow pass. Boarded and chase views are always near enough, but within the cabin a part too
96
+ * small to see from the camera (CABIN_DETAIL_ANGLE) leaves the frame through its render layers,
97
+ * so a binding's or damage's own `visible` is never overridden.
120
98
  */
121
99
  updateView(camera: readonly [number, number, number]): void;
122
100
  dispose(): void;