@adatechnology/game-vehicles-driving 0.3.11 → 0.3.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/dist/index.d.ts +2 -0
- package/dist/index.global.js +3 -0
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -665,6 +665,8 @@ interface ControlledDriver {
|
|
|
665
665
|
interface VehicleControls {
|
|
666
666
|
/** A key went down or up. True when it is a driving key (the host keeps it from its own bindings). */
|
|
667
667
|
key(code: string, down: boolean): boolean;
|
|
668
|
+
/** Whether `code` is a driving key, without pressing it (a host keeps it from its own bindings while the driver is getting in or out). */
|
|
669
|
+
owns(code: string): boolean;
|
|
668
670
|
/** Runs a command as its key would (a button of a panel). */
|
|
669
671
|
command(command: ControlCommand): void;
|
|
670
672
|
/** The input for this step, pedals and wheel eased over `dt` seconds. */
|
package/dist/index.global.js
CHANGED
|
@@ -236,6 +236,8 @@ var GameVehiclesDriving = (() => {
|
|
|
236
236
|
[DEFERRED_QUEUE_ID.DESTRUCTION_PREFIT]: { priority: 40, phase: "idle", minEveryFrames: 30 }
|
|
237
237
|
};
|
|
238
238
|
var MUST_DRAIN_QUEUE_IDS = /* @__PURE__ */ new Set([DEFERRED_QUEUE_ID.DESTRUCTION_EVENTS, DEFERRED_QUEUE_ID.BREACH_CUT]);
|
|
239
|
+
var BODY_FOAM_SURFACES = ["hands", "arms", "torso", "hair", "mouth"];
|
|
240
|
+
var WASH_SURFACES = [...BODY_FOAM_SURFACES, "brush"];
|
|
239
241
|
var WARNED_KEY = /* @__PURE__ */ Symbol.for("@adatechnology/game-contracts.warned");
|
|
240
242
|
var warnedKeys = () => {
|
|
241
243
|
const holder = globalThis;
|
|
@@ -1026,6 +1028,7 @@ var GameVehiclesDriving = (() => {
|
|
|
1026
1028
|
return {
|
|
1027
1029
|
keys,
|
|
1028
1030
|
state,
|
|
1031
|
+
owns: (code) => driving.has(code),
|
|
1029
1032
|
key(code, down) {
|
|
1030
1033
|
if (!driving.has(code)) return false;
|
|
1031
1034
|
const was = held.has(code);
|