@adatechnology/game-vehicles-driving 0.3.10 → 0.3.12

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 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. */
@@ -1026,6 +1026,7 @@ var GameVehiclesDriving = (() => {
1026
1026
  return {
1027
1027
  keys,
1028
1028
  state,
1029
+ owns: (code) => driving.has(code),
1029
1030
  key(code, down) {
1030
1031
  if (!driving.has(code)) return false;
1031
1032
  const was = held.has(code);