@adatechnology/game-vehicles-three 0.4.0 → 0.6.0
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/dist/chunk-4SUQMRS3.js +2429 -0
- package/dist/chunk-4SUQMRS3.js.map +1 -0
- package/dist/index.d.ts +105 -183
- package/dist/index.global.js +4925 -416
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +66 -1221
- package/dist/index.js.map +1 -1
- package/dist/testing-gEnSqEF6.d.ts +349 -0
- package/dist/testing.d.ts +4 -0
- package/dist/testing.js +33 -0
- package/dist/testing.js.map +1 -0
- package/package.json +16 -8
|
@@ -0,0 +1,349 @@
|
|
|
1
|
+
import { EffectSink, Vec3, TestableModule } from '@adatechnology/game-contracts';
|
|
2
|
+
import { Damageable, VehicleContext, VehicleKit } from '@adatechnology/game-vehicles';
|
|
3
|
+
import { ProvingSubject, ProvingTestRegistry, ProvingCertificate } from '@adatechnology/game-vehicles-proving';
|
|
4
|
+
|
|
5
|
+
type VehicleQuality = 'high' | 'lite';
|
|
6
|
+
/** The measured size of a fleet vehicle in metres (the shape of `FleetDims` of `game-vehicles-fleet`). */
|
|
7
|
+
interface FleetDims {
|
|
8
|
+
length: number;
|
|
9
|
+
width: number;
|
|
10
|
+
height: number;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* The fleet content the builder reads: the paint palettes, the size the team measured and the colour a seed picks. It is the shape of what
|
|
14
|
+
* `game-vehicles-fleet` exports (`defaultVehicleFleet()` of `game-kit-defaults` hands it over), so this adapter imports no content.
|
|
15
|
+
*/
|
|
16
|
+
interface VehicleFleetContent {
|
|
17
|
+
readonly paintPalettes: {
|
|
18
|
+
readonly civil: unknown;
|
|
19
|
+
readonly military: unknown;
|
|
20
|
+
};
|
|
21
|
+
paletteOf(group: string): unknown;
|
|
22
|
+
colorFromSeed(seed: number | string, palette: unknown): string;
|
|
23
|
+
fleetDims(id: string): FleetDims | undefined;
|
|
24
|
+
}
|
|
25
|
+
interface BuildVehicleOptions {
|
|
26
|
+
/** `high`: the kit's vehicle at full detail. `lite`: fused into six meshes. Default `high`. */
|
|
27
|
+
quality?: VehicleQuality;
|
|
28
|
+
/** Body colour as a CSS colour. Wins over `seed`. */
|
|
29
|
+
color?: string;
|
|
30
|
+
/** Picks the body colour from the palette of the vehicle's group. */
|
|
31
|
+
seed?: number | string;
|
|
32
|
+
/** State of the vehicle. Default `intact`. */
|
|
33
|
+
state?: 'intact' | 'damaged' | 'modified';
|
|
34
|
+
}
|
|
35
|
+
interface BuiltVehicle {
|
|
36
|
+
key: string;
|
|
37
|
+
quality: VehicleQuality;
|
|
38
|
+
/** The colour the body ended up with, or null when the vehicle keeps its own paint. */
|
|
39
|
+
color: string | null;
|
|
40
|
+
seed: number | string | null;
|
|
41
|
+
/** Group in the game frame: front on +z, right on -x, centred on x and z, wheels on y = 0. */
|
|
42
|
+
group: any;
|
|
43
|
+
/** Damageable boxes in the game frame. */
|
|
44
|
+
damageables: Damageable[];
|
|
45
|
+
triangles: number;
|
|
46
|
+
drawCalls: number;
|
|
47
|
+
/** Measured size of the group in metres: length along z, width along x, height along y. */
|
|
48
|
+
length: number;
|
|
49
|
+
width: number;
|
|
50
|
+
height: number;
|
|
51
|
+
/** Pieces dropped for being smaller than 3 cm (lite only). */
|
|
52
|
+
pruned: number;
|
|
53
|
+
/** The measured size the team recorded for this vehicle, when the fleet knows it. */
|
|
54
|
+
expected: FleetDims | undefined;
|
|
55
|
+
/** The kit's context, for damage and animation (full detail only). */
|
|
56
|
+
context: VehicleContext | null;
|
|
57
|
+
dispose(): void;
|
|
58
|
+
}
|
|
59
|
+
interface VehiclesThree {
|
|
60
|
+
readonly THREE: any;
|
|
61
|
+
readonly kit: VehicleKit;
|
|
62
|
+
build(key: string, options?: BuildVehicleOptions): BuiltVehicle;
|
|
63
|
+
}
|
|
64
|
+
interface VehiclesThreeOptions {
|
|
65
|
+
kit: VehicleKit;
|
|
66
|
+
/**
|
|
67
|
+
* The fleet's palettes and measured sizes (`defaultVehicleFleet()` of `game-kit-defaults`, or the game's own). Default the ones of `game-vehicles-fleet`.
|
|
68
|
+
* @deprecated pass `fleet`; the default is removed in the next major.
|
|
69
|
+
*/
|
|
70
|
+
fleet?: VehicleFleetContent;
|
|
71
|
+
/** Vehicle id to the group id whose palette paints it. Defaults to the fleet group of the vehicle (`military` for the military ones). */
|
|
72
|
+
groupOf?: (key: string) => string;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Builds vehicles in a game frame. Port of `FrotaLeve.criar(...).construir` (frota-leve.js 14311-14442): the kit builds with +x to the front
|
|
76
|
+
* and +z to the right; the game wants +z to the front and -x to the right, the vehicle centred on x and z and standing on y = 0.
|
|
77
|
+
*/
|
|
78
|
+
declare function createVehiclesThree(THREE: any, options: VehiclesThreeOptions): VehiclesThree;
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* How a vehicle sounds, as data. An engine is a few loops crossfaded by RPM (idle, low/mid, high) plus a load layer (intake and exhaust roar) that
|
|
82
|
+
* follows the throttle, the way a sampled engine is mixed: when recorded loops arrive they take the same ids and the same crossfade. The pitch of
|
|
83
|
+
* each tone layer is the firing frequency of the engine (`rpm / 60 × cylinders / 2` for a four-stroke) times its harmonic.
|
|
84
|
+
*/
|
|
85
|
+
/** One tone layer of the engine: the loop id, where in the RPM range it is loudest (0 idle … 1 redline), and its level and cutoff. */
|
|
86
|
+
type EngineLayer = {
|
|
87
|
+
readonly sound: string;
|
|
88
|
+
/** Normalised RPM (0 at idle, 1 at the redline) where the layer is loudest. */
|
|
89
|
+
readonly centre: number;
|
|
90
|
+
/** How far from `centre` the layer fades out (equal-power crossfade). */
|
|
91
|
+
readonly width: number;
|
|
92
|
+
/** Multiple of the firing frequency the oscillator plays at. */
|
|
93
|
+
readonly harmonic: number;
|
|
94
|
+
/** Level at full load. */
|
|
95
|
+
readonly gain: number;
|
|
96
|
+
/** Low-pass cutoff, Hz, from no load at idle to full load at the redline. */
|
|
97
|
+
readonly cutoff: readonly [min: number, max: number];
|
|
98
|
+
};
|
|
99
|
+
/** The roar of the intake and exhaust: a noise loop that opens with the throttle and the RPM. */
|
|
100
|
+
type EngineLoadLayer = {
|
|
101
|
+
readonly sound: string;
|
|
102
|
+
readonly gain: number;
|
|
103
|
+
readonly cutoff: readonly [min: number, max: number];
|
|
104
|
+
};
|
|
105
|
+
type EngineProfile = {
|
|
106
|
+
readonly id: string;
|
|
107
|
+
readonly cylinders: number;
|
|
108
|
+
readonly idleRpm: number;
|
|
109
|
+
readonly redlineRpm: number;
|
|
110
|
+
/** Gear ratios times final drive per m/s, to guess the RPM from the speed when the driver has no engine model (the arcade driver). */
|
|
111
|
+
readonly rpmPerMps: readonly number[];
|
|
112
|
+
readonly layers: readonly EngineLayer[];
|
|
113
|
+
readonly load: EngineLoadLayer;
|
|
114
|
+
/** Level with the throttle closed, as a share of full load (engine braking is quieter and darker). */
|
|
115
|
+
readonly closedThrottle: number;
|
|
116
|
+
};
|
|
117
|
+
/** The sound ids a vehicle plays besides its engine. Every one is a key of `VEHICLE_SOUND_BANK`, and a game can point any of them elsewhere. */
|
|
118
|
+
type VehicleSoundKeys = {
|
|
119
|
+
readonly start: string;
|
|
120
|
+
readonly stop: string;
|
|
121
|
+
readonly fail: string;
|
|
122
|
+
readonly crashLight: string;
|
|
123
|
+
readonly crashMedium: string;
|
|
124
|
+
readonly crashHeavy: string;
|
|
125
|
+
readonly skidAsphalt: string;
|
|
126
|
+
readonly skidDirt: string;
|
|
127
|
+
readonly roll: string;
|
|
128
|
+
};
|
|
129
|
+
declare const DEFAULT_VEHICLE_SOUND_KEYS: VehicleSoundKeys;
|
|
130
|
+
/** The speed of the hit, m/s, where a crash stops being light (≈ 22 km/h: dents and plastic) and where it turns heavy (≈ 50 km/h: metal folds, glass goes). */
|
|
131
|
+
declare const CRASH_SPEEDS: {
|
|
132
|
+
readonly medium: 6;
|
|
133
|
+
readonly heavy: 14;
|
|
134
|
+
};
|
|
135
|
+
/** A four-cylinder petrol car: 800 to 6 500 rpm. */
|
|
136
|
+
declare const CAR_ENGINE: EngineProfile;
|
|
137
|
+
/** A six-cylinder diesel truck or bus: 650 to 2 600 rpm, low and clattering. */
|
|
138
|
+
declare const TRUCK_ENGINE: EngineProfile;
|
|
139
|
+
/** A four-cylinder sport bike: 1 300 to 12 000 rpm, bright and fast to rev. */
|
|
140
|
+
declare const BIKE_ENGINE: EngineProfile;
|
|
141
|
+
declare const ENGINE_PROFILES: Readonly<Record<string, EngineProfile>>;
|
|
142
|
+
|
|
143
|
+
/** The fleet the area runs on: its palettes and sizes, and how it is installed in a kit (`defaultVehicleFleet()` of `game-kit-defaults`). */
|
|
144
|
+
type VehiclesTestFleet = VehicleFleetContent & {
|
|
145
|
+
installFleet(kit: VehicleKit): void;
|
|
146
|
+
};
|
|
147
|
+
/** What the module needs of a document (canvas textures of the kit): a real `document`, or a stub in Node. */
|
|
148
|
+
type DocumentLike = {
|
|
149
|
+
createElement(tag: string): unknown;
|
|
150
|
+
};
|
|
151
|
+
/** The host's effects (`host.effects`, an `EffectSink` of the contracts: `game-vfx-three` is one): the module asks by id and writes no particle code. */
|
|
152
|
+
type EffectsLike = EffectSink;
|
|
153
|
+
/** The events the module turns into effect requests, and the effect id each one asks for. A game maps its own ids over these. */
|
|
154
|
+
type VehicleEffectIds = {
|
|
155
|
+
readonly ignite: string;
|
|
156
|
+
readonly explode: string;
|
|
157
|
+
readonly glass: string;
|
|
158
|
+
readonly sparks: string;
|
|
159
|
+
readonly leak: string;
|
|
160
|
+
/** The leak of a pierced tank caught fire: the whole sequence (fire along the pool, then the blast). `leak` is only the pool and the drips. */
|
|
161
|
+
readonly leakIgnited: string;
|
|
162
|
+
readonly exhaust: string;
|
|
163
|
+
};
|
|
164
|
+
declare const defaultEffectIds: VehicleEffectIds;
|
|
165
|
+
/**
|
|
166
|
+
* The sounds the module asks of `host.audio`, by id of the host's banks: the horn (placed at the car), and the vehicle's own sounds (`createVehicleSound`: the starter, the
|
|
167
|
+
* crashes by speed, the tyres). The engine loops come from the engine profile.
|
|
168
|
+
*/
|
|
169
|
+
type VehicleSoundIds = {
|
|
170
|
+
readonly horn: string;
|
|
171
|
+
} & VehicleSoundKeys;
|
|
172
|
+
declare const defaultSoundIds: VehicleSoundIds;
|
|
173
|
+
/** A damaged vehicle of the area: the item id, the fleet vehicle it is built from and the scenario of the kit applied while building. */
|
|
174
|
+
type VehicleWreck = {
|
|
175
|
+
readonly key: string;
|
|
176
|
+
readonly vehicle: string;
|
|
177
|
+
readonly scenario: string;
|
|
178
|
+
};
|
|
179
|
+
declare const DEFAULT_TEST_WRECKS: readonly VehicleWreck[];
|
|
180
|
+
type VehiclesTestOptions = {
|
|
181
|
+
/**
|
|
182
|
+
* The fleet content: paint palettes, measured sizes and the install into the default kit (`defaultVehicleFleet()` of `game-kit-defaults`). Default the ones of `game-vehicles-fleet`.
|
|
183
|
+
* @deprecated pass `fleet`; the default is removed in the next major.
|
|
184
|
+
*/
|
|
185
|
+
readonly fleet?: VehiclesTestFleet;
|
|
186
|
+
/** `en` or `pt-BR` (default). */
|
|
187
|
+
readonly locale?: string;
|
|
188
|
+
/** The kit the vehicles are built with, per three.js namespace. Default: `createVehicleKit` with the fleet installed (`fleet.installFleet`). */
|
|
189
|
+
readonly createKit?: (THREE: unknown) => VehicleKit;
|
|
190
|
+
readonly document?: DocumentLike;
|
|
191
|
+
/** The three.js namespace the door, hood and trunk clips are computed with (they are plain numbers, so any copy works). Default: the global `THREE`; without either the items bring no clips. */
|
|
192
|
+
readonly three?: unknown;
|
|
193
|
+
/** The vehicles to lay out, as fleet ids (default the 8 of the Frota test: hatch, sedan, pickup, sport bike, box truck, city bus, battle tank, attack helicopter). */
|
|
194
|
+
readonly vehicles?: readonly string[];
|
|
195
|
+
/** Wrecks laid out after the vehicles: item `key` is the fleet vehicle `vehicle` built with the registered damage `scenario` (default `sedan_burnt` and `hatch_burnt`, the fleet's `burnt`; an empty list lays none). */
|
|
196
|
+
readonly wrecks?: readonly VehicleWreck[];
|
|
197
|
+
/** Effect ids requested through `host.effects` (the defaults are ids of `game-vfx`: the Garagem's `car_fuel_tank` blast, the `vehicle_fire`, `vehicle_leak` (pool and drips only), `vehicle_leak_ignited` (the whole sequence) and `vehicle_exhaust` recipes written around a car from `engine_smoke` and `fuel_leak`, and the point-based `glass_burst` and `impact_metal`). */
|
|
198
|
+
readonly effects?: Partial<VehicleEffectIds>;
|
|
199
|
+
/** Sound ids requested through `host.audio` (the defaults: the vehicle bank of this package). */
|
|
200
|
+
readonly sounds?: Partial<VehicleSoundIds>;
|
|
201
|
+
};
|
|
202
|
+
/** The part of the test room the scenarios use (the room's `ScenarioContext.room` has all of it). */
|
|
203
|
+
type PartView = {
|
|
204
|
+
holes: {
|
|
205
|
+
through?: boolean;
|
|
206
|
+
}[];
|
|
207
|
+
cracks: unknown[];
|
|
208
|
+
dents: unknown[];
|
|
209
|
+
status: string;
|
|
210
|
+
hp: number;
|
|
211
|
+
maxHp: number;
|
|
212
|
+
temperature: number;
|
|
213
|
+
burning: boolean;
|
|
214
|
+
liters: number;
|
|
215
|
+
melt: number;
|
|
216
|
+
};
|
|
217
|
+
type SpawnedVehicle = {
|
|
218
|
+
objectId: string;
|
|
219
|
+
root: {
|
|
220
|
+
userData: Record<string, unknown>;
|
|
221
|
+
};
|
|
222
|
+
};
|
|
223
|
+
type VehiclesRoom = {
|
|
224
|
+
spawn(item: string, position?: Vec3, rotationY?: number): SpawnedVehicle;
|
|
225
|
+
setTool(weaponId: string): void;
|
|
226
|
+
/** Lets the tool in hand finish its draw time (the room's rule: a weapon cannot fire the moment it is taken). */
|
|
227
|
+
waitUntilReady(): void;
|
|
228
|
+
look(position: Vec3, target: Vec3): void;
|
|
229
|
+
use(hold?: number): void;
|
|
230
|
+
playAnimation(clipId: string, objectId?: string): boolean;
|
|
231
|
+
world: {
|
|
232
|
+
part(object: string, part: string): PartView;
|
|
233
|
+
hit(object: string, hit: Record<string, unknown>): unknown;
|
|
234
|
+
disassemble(object: string, joint: string, tool: string, dt: number): number;
|
|
235
|
+
state(object: string): {
|
|
236
|
+
joints: {
|
|
237
|
+
id: string;
|
|
238
|
+
open: boolean;
|
|
239
|
+
}[];
|
|
240
|
+
groups: unknown[][];
|
|
241
|
+
};
|
|
242
|
+
};
|
|
243
|
+
log: {
|
|
244
|
+
entries(filter: {
|
|
245
|
+
type?: string;
|
|
246
|
+
objectId?: string;
|
|
247
|
+
}): readonly unknown[];
|
|
248
|
+
};
|
|
249
|
+
};
|
|
250
|
+
/** What a scenario needs of the room: the pass/fail line, time, and the room for the ones that shoot and hit. */
|
|
251
|
+
type VehiclesContext = {
|
|
252
|
+
room: VehiclesRoom;
|
|
253
|
+
expect(condition: boolean, label: string, data?: Record<string, unknown>): void;
|
|
254
|
+
step(seconds: number): void;
|
|
255
|
+
};
|
|
256
|
+
|
|
257
|
+
declare const VEHICLES_AREA_ID = "vehicles_area";
|
|
258
|
+
/** The eight vehicles of the Frota test page, in its order, and the item id each one has in the area. */
|
|
259
|
+
declare const DEFAULT_TEST_VEHICLES: readonly string[];
|
|
260
|
+
/**
|
|
261
|
+
* The vehicles test area as a `TestableModule`: the vehicles of the Frota test (hatch, sedan, pickup, sport bike, box truck, city bus, battle tank, attack helicopter), each with its own
|
|
262
|
+
* `DestructibleImpl` and its door, hood and trunk clips, the eleven scenarios of that page (literal) and two for the drivers. The bench sets the quality (full or light mode), the paint
|
|
263
|
+
* by seed and palette, the driving mode and the surface, and shows the damageable boxes by material, the zones by type and the axes of the output frame. Effects (fire, glass, sparks,
|
|
264
|
+
* exhaust) are requested by id through `host.effects` when the host has it; this module draws none.
|
|
265
|
+
*/
|
|
266
|
+
declare function createVehiclesTestModule(options?: VehiclesTestOptions): TestableModule<VehiclesContext> & {
|
|
267
|
+
readonly placed: ReadonlyMap<string, unknown>;
|
|
268
|
+
};
|
|
269
|
+
/** What `loadVehiclesTestModule` needs of a room: `TestRoom.loadModule` has it. */
|
|
270
|
+
type ModuleRoomLike = {
|
|
271
|
+
loadModule(module: never): unknown;
|
|
272
|
+
};
|
|
273
|
+
/**
|
|
274
|
+
* Loads the vehicles module into a room. The door, hood and trunk clips of the items are computed when the room reads the items, before the module is lent the room's three.js
|
|
275
|
+
* (`attach`), so this first lends an empty module to learn the namespace and then loads the real one with it. Pass `three` to skip that.
|
|
276
|
+
*/
|
|
277
|
+
declare function loadVehiclesTestModule<Room extends ModuleRoomLike>(room: Room, options?: VehiclesTestOptions): ReturnType<Room['loadModule']>;
|
|
278
|
+
|
|
279
|
+
declare const VEHICLE_SCENARIO_IDS: readonly string[];
|
|
280
|
+
/** The ids of the Frota test page, for whoever keeps a report or a link made against it. */
|
|
281
|
+
declare const PAGE_SCENARIO_ALIASES: Readonly<Record<string, string>>;
|
|
282
|
+
declare const PAGE_ITEM_ALIASES: Readonly<Record<string, string>>;
|
|
283
|
+
|
|
284
|
+
declare const PROVING_AREA_ID = "vehicles_proving";
|
|
285
|
+
type Three = any;
|
|
286
|
+
/** Content comes in by option (the adapter does not import a content pack): the example wires the kit's fleet, a game its own catalogue. */
|
|
287
|
+
interface ProvingModuleOptions {
|
|
288
|
+
locale?: string;
|
|
289
|
+
/** Vehicles offered on the bench, by catalogue id. */
|
|
290
|
+
vehicles: readonly string[];
|
|
291
|
+
/** The proving subject of a vehicle (`fleetProvingSubject` of game-vehicles-fleet); `mass` is the kit's own when it has one. Null hides the vehicle. */
|
|
292
|
+
subject(id: string, mass: number | undefined): ProvingSubject | null;
|
|
293
|
+
/** The vehicle's name on the bench and the board (default: the id). */
|
|
294
|
+
nameOf?(id: string): string | undefined;
|
|
295
|
+
/** The tests (default: the kit's, see `createProvingTests`). */
|
|
296
|
+
tests?: ProvingTestRegistry;
|
|
297
|
+
/** Builds the vehicle kit, with the catalogue installed, for a three.js namespace. */
|
|
298
|
+
createKit(THREE: Three): VehicleKit;
|
|
299
|
+
sounds?: Partial<VehicleSoundIds>;
|
|
300
|
+
/** Called whenever a certificate changes (a result in, a sign-off), so a page can keep or show them. */
|
|
301
|
+
onCertificate?(certificate: ProvingCertificate): void;
|
|
302
|
+
}
|
|
303
|
+
/**
|
|
304
|
+
* The proving ground as a `TestableModule`: a track where a fleet vehicle runs the measured tests of `game-vehicles-proving` live (0-100, top speed, braking, turning circle, wet braking, mud)
|
|
305
|
+
* on the same semi-simulation driver the headless runner uses, with the vehicle cameras of `game-camera` (chase, cockpit, hood) taking over the room's view, the rear-view and side mirrors
|
|
306
|
+
* and the reversing camera with its guide lines as extra views of the host, a board by the track with the vehicle's certificate, and the sign-off of the visual checks.
|
|
307
|
+
*/
|
|
308
|
+
declare function createProvingModule(options: ProvingModuleOptions): TestableModule & {
|
|
309
|
+
certificates(): ProvingCertificate[];
|
|
310
|
+
certificate(id: string): ProvingCertificate | undefined;
|
|
311
|
+
};
|
|
312
|
+
/** What `loadProvingModule` needs of a room: `TestRoom.loadModule` has it. */
|
|
313
|
+
type ProvingRoomLike = {
|
|
314
|
+
loadModule(module: never): unknown;
|
|
315
|
+
openArea?(id: string): unknown;
|
|
316
|
+
};
|
|
317
|
+
declare function loadProvingModule<Room extends ProvingRoomLike>(room: Room, options: ProvingModuleOptions): ReturnType<Room['loadModule']>;
|
|
318
|
+
|
|
319
|
+
/** Texts of the proving ground, in Brazilian Portuguese and English. */
|
|
320
|
+
type ProvingText = {
|
|
321
|
+
name: string;
|
|
322
|
+
controls: Record<'vehicle' | 'test' | 'camera' | 'time_scale' | 'visual_check', string>;
|
|
323
|
+
hints: Record<'vehicle' | 'test' | 'camera' | 'time_scale' | 'visual_check', string>;
|
|
324
|
+
actions: Record<'run_test' | 'run_all' | 'certify_now' | 'reverse_park' | 'sign_ok' | 'sign_fail' | 'reset', string>;
|
|
325
|
+
layers: Record<'mirrors' | 'reverse_camera' | 'scoreboard', string>;
|
|
326
|
+
metrics: Record<'speed' | 'time' | 'value' | 'passed' | 'failed' | 'pending' | 'status', string>;
|
|
327
|
+
cameras: Record<'room' | 'chase' | 'cockpit' | 'hood', string>;
|
|
328
|
+
tests: Record<string, string>;
|
|
329
|
+
status: Record<'approved' | 'rejected' | 'pending', string>;
|
|
330
|
+
verdict: Record<'pass' | 'fail' | 'pending', string>;
|
|
331
|
+
board: {
|
|
332
|
+
title: string;
|
|
333
|
+
test: string;
|
|
334
|
+
value: string;
|
|
335
|
+
range: string;
|
|
336
|
+
verdict: string;
|
|
337
|
+
notRun: string;
|
|
338
|
+
running: string;
|
|
339
|
+
};
|
|
340
|
+
log: {
|
|
341
|
+
start: string;
|
|
342
|
+
result: string;
|
|
343
|
+
signed: string;
|
|
344
|
+
certified: string;
|
|
345
|
+
};
|
|
346
|
+
};
|
|
347
|
+
declare const PROVING_TEXT: Record<string, ProvingText>;
|
|
348
|
+
|
|
349
|
+
export { type VehiclesTestOptions as A, BIKE_ENGINE as B, CAR_ENGINE as C, DEFAULT_TEST_VEHICLES as D, type EngineProfile as E, type FleetDims as F, type VehiclesThree as G, type VehiclesThreeOptions as H, createProvingModule as I, createVehiclesTestModule as J, createVehiclesThree as K, defaultEffectIds as L, type ModuleRoomLike as M, defaultSoundIds as N, loadProvingModule as O, PAGE_ITEM_ALIASES as P, loadVehiclesTestModule as Q, TRUCK_ENGINE as T, type VehicleSoundKeys as V, type BuildVehicleOptions as a, type BuiltVehicle as b, CRASH_SPEEDS as c, DEFAULT_TEST_WRECKS as d, DEFAULT_VEHICLE_SOUND_KEYS as e, type DocumentLike as f, ENGINE_PROFILES as g, type EffectsLike as h, type EngineLayer as i, type EngineLoadLayer as j, PAGE_SCENARIO_ALIASES as k, PROVING_AREA_ID as l, PROVING_TEXT as m, type ProvingModuleOptions as n, type ProvingRoomLike as o, type ProvingText as p, VEHICLES_AREA_ID as q, VEHICLE_SCENARIO_IDS as r, type VehicleEffectIds as s, type VehicleFleetContent as t, type VehicleQuality as u, type VehicleSoundIds as v, type VehicleWreck as w, type VehiclesContext as x, type VehiclesRoom as y, type VehiclesTestFleet as z };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { D as DEFAULT_TEST_VEHICLES, d as DEFAULT_TEST_WRECKS, f as DocumentLike, h as EffectsLike, M as ModuleRoomLike, P as PAGE_ITEM_ALIASES, k as PAGE_SCENARIO_ALIASES, l as PROVING_AREA_ID, m as PROVING_TEXT, n as ProvingModuleOptions, o as ProvingRoomLike, p as ProvingText, q as VEHICLES_AREA_ID, r as VEHICLE_SCENARIO_IDS, s as VehicleEffectIds, v as VehicleSoundIds, w as VehicleWreck, x as VehiclesContext, y as VehiclesRoom, z as VehiclesTestFleet, A as VehiclesTestOptions, I as createProvingModule, J as createVehiclesTestModule, L as defaultEffectIds, N as defaultSoundIds, O as loadProvingModule, Q as loadVehiclesTestModule } from './testing-gEnSqEF6.js';
|
|
2
|
+
import '@adatechnology/game-contracts';
|
|
3
|
+
import '@adatechnology/game-vehicles';
|
|
4
|
+
import '@adatechnology/game-vehicles-proving';
|
package/dist/testing.js
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import {
|
|
2
|
+
DEFAULT_TEST_VEHICLES,
|
|
3
|
+
DEFAULT_TEST_WRECKS,
|
|
4
|
+
PAGE_ITEM_ALIASES,
|
|
5
|
+
PAGE_SCENARIO_ALIASES,
|
|
6
|
+
PROVING_AREA_ID,
|
|
7
|
+
PROVING_TEXT,
|
|
8
|
+
VEHICLES_AREA_ID,
|
|
9
|
+
VEHICLE_SCENARIO_IDS,
|
|
10
|
+
createProvingModule,
|
|
11
|
+
createVehiclesTestModule,
|
|
12
|
+
defaultEffectIds,
|
|
13
|
+
defaultSoundIds,
|
|
14
|
+
loadProvingModule,
|
|
15
|
+
loadVehiclesTestModule
|
|
16
|
+
} from "./chunk-4SUQMRS3.js";
|
|
17
|
+
export {
|
|
18
|
+
DEFAULT_TEST_VEHICLES,
|
|
19
|
+
DEFAULT_TEST_WRECKS,
|
|
20
|
+
PAGE_ITEM_ALIASES,
|
|
21
|
+
PAGE_SCENARIO_ALIASES,
|
|
22
|
+
PROVING_AREA_ID,
|
|
23
|
+
PROVING_TEXT,
|
|
24
|
+
VEHICLES_AREA_ID,
|
|
25
|
+
VEHICLE_SCENARIO_IDS,
|
|
26
|
+
createProvingModule,
|
|
27
|
+
createVehiclesTestModule,
|
|
28
|
+
defaultEffectIds,
|
|
29
|
+
defaultSoundIds,
|
|
30
|
+
loadProvingModule,
|
|
31
|
+
loadVehiclesTestModule
|
|
32
|
+
};
|
|
33
|
+
//# sourceMappingURL=testing.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adatechnology/game-vehicles-three",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "three.js output of the vehicles of @adatechnology/game-vehicles: a vehicle in a game frame (front on +z, centred, on the ground) at full detail or fused into six meshes (the team's Frota Leve light mode), coloured by seed, with its damageable boxes; and the vehicles test module.",
|
|
6
6
|
"keywords": [
|
|
@@ -31,18 +31,25 @@
|
|
|
31
31
|
"types": "./dist/index.d.ts",
|
|
32
32
|
"import": "./dist/index.js"
|
|
33
33
|
},
|
|
34
|
+
"./testing": {
|
|
35
|
+
"types": "./dist/testing.d.ts",
|
|
36
|
+
"import": "./dist/testing.js"
|
|
37
|
+
},
|
|
34
38
|
"./global": "./dist/index.global.js"
|
|
35
39
|
},
|
|
36
40
|
"files": [
|
|
37
41
|
"dist"
|
|
38
42
|
],
|
|
39
43
|
"dependencies": {
|
|
40
|
-
"@adatechnology/game-audio": "^0.
|
|
41
|
-
"@adatechnology/game-
|
|
42
|
-
"@adatechnology/game-
|
|
43
|
-
"@adatechnology/game-
|
|
44
|
-
"@adatechnology/game-
|
|
45
|
-
"@adatechnology/game-vehicles
|
|
44
|
+
"@adatechnology/game-audio": "^0.5.0",
|
|
45
|
+
"@adatechnology/game-camera": "^0.2.0",
|
|
46
|
+
"@adatechnology/game-contracts": "^0.23.0",
|
|
47
|
+
"@adatechnology/game-render-three": "^0.1.0",
|
|
48
|
+
"@adatechnology/game-shapes-three": "^0.3.1",
|
|
49
|
+
"@adatechnology/game-vehicles": "^0.6.1",
|
|
50
|
+
"@adatechnology/game-vehicles-driving": "^0.2.10",
|
|
51
|
+
"@adatechnology/game-vehicles-fleet": "^6.0.0",
|
|
52
|
+
"@adatechnology/game-vehicles-proving": "^0.1.1"
|
|
46
53
|
},
|
|
47
54
|
"devDependencies": {
|
|
48
55
|
"@types/node": "^22.10.7",
|
|
@@ -52,7 +59,8 @@
|
|
|
52
59
|
"tsup": "^8.5.1",
|
|
53
60
|
"typescript": "^5.7.3",
|
|
54
61
|
"vitest": "^3.2.4",
|
|
55
|
-
"@adatechnology/game-
|
|
62
|
+
"@adatechnology/game-kit-defaults": "^0.2.0",
|
|
63
|
+
"@adatechnology/game-test-room": "^0.22.0",
|
|
56
64
|
"@adatechnology/golden-tool": "^0.0.0"
|
|
57
65
|
},
|
|
58
66
|
"peerDependencies": {
|