@needle-tools/engine 5.1.1 → 5.1.2

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.
Files changed (68) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/{needle-engine.bundle-Dv-p5m4z.js → needle-engine.bundle-BAUfRyBA.js} +2861 -2708
  3. package/dist/{needle-engine.bundle-Cb39lTJn.umd.cjs → needle-engine.bundle-BL2wG5Te.umd.cjs} +101 -101
  4. package/dist/{needle-engine.bundle-BUT4ua7U.min.js → needle-engine.bundle-BpNRkY3s.min.js} +148 -148
  5. package/dist/needle-engine.d.ts +18 -6
  6. package/dist/needle-engine.js +401 -401
  7. package/dist/needle-engine.min.js +1 -1
  8. package/dist/needle-engine.umd.cjs +1 -1
  9. package/lib/engine/api.d.ts +1 -1
  10. package/lib/engine/api.js +1 -1
  11. package/lib/engine/api.js.map +1 -1
  12. package/lib/engine/engine_init.js +2 -2
  13. package/lib/engine/engine_init.js.map +1 -1
  14. package/lib/engine/engine_license.d.ts +45 -7
  15. package/lib/engine/engine_license.js +276 -77
  16. package/lib/engine/engine_license.js.map +1 -1
  17. package/lib/engine/engine_networking.js +6 -0
  18. package/lib/engine/engine_networking.js.map +1 -1
  19. package/lib/engine/engine_networking_blob.js +3 -3
  20. package/lib/engine/engine_networking_blob.js.map +1 -1
  21. package/lib/engine/engine_utils_qrcode.js +2 -2
  22. package/lib/engine/engine_utils_qrcode.js.map +1 -1
  23. package/lib/engine/webcomponents/needle menu/needle-menu-spatial.js +2 -2
  24. package/lib/engine/webcomponents/needle menu/needle-menu-spatial.js.map +1 -1
  25. package/lib/engine/webcomponents/needle menu/needle-menu.js +5 -5
  26. package/lib/engine/webcomponents/needle menu/needle-menu.js.map +1 -1
  27. package/lib/engine/webcomponents/needle-engine.js +31 -2
  28. package/lib/engine/webcomponents/needle-engine.js.map +1 -1
  29. package/lib/engine/webcomponents/needle-engine.loading.js +2 -2
  30. package/lib/engine/webcomponents/needle-engine.loading.js.map +1 -1
  31. package/lib/engine/xr/NeedleXRSync.js +23 -4
  32. package/lib/engine/xr/NeedleXRSync.js.map +1 -1
  33. package/lib/engine/xr/TempXRContext.js +2 -2
  34. package/lib/engine/xr/TempXRContext.js.map +1 -1
  35. package/lib/engine-components/SyncedTransform.d.ts +5 -1
  36. package/lib/engine-components/SyncedTransform.js +45 -8
  37. package/lib/engine-components/SyncedTransform.js.map +1 -1
  38. package/lib/engine-components/export/usdz/USDZExporter.js +4 -4
  39. package/lib/engine-components/export/usdz/USDZExporter.js.map +1 -1
  40. package/lib/engine-components/webxr/Avatar.d.ts +8 -0
  41. package/lib/engine-components/webxr/Avatar.js +60 -32
  42. package/lib/engine-components/webxr/Avatar.js.map +1 -1
  43. package/lib/engine-schemes/synced-transform-model.d.ts +2 -0
  44. package/lib/engine-schemes/synced-transform-model.js +8 -1
  45. package/lib/engine-schemes/synced-transform-model.js.map +1 -1
  46. package/package.json +1 -1
  47. package/plugins/common/license.js +4 -4
  48. package/plugins/types/userconfig.d.ts +4 -3
  49. package/plugins/vite/build-pipeline.d.ts +3 -1
  50. package/plugins/vite/build-pipeline.js +19 -9
  51. package/plugins/vite/license.js +4 -4
  52. package/src/engine/api.ts +1 -1
  53. package/src/engine/engine_init.ts +2 -2
  54. package/src/engine/engine_license.ts +263 -73
  55. package/src/engine/engine_networking.ts +5 -0
  56. package/src/engine/engine_networking_blob.ts +3 -3
  57. package/src/engine/engine_utils_qrcode.ts +2 -2
  58. package/src/engine/webcomponents/needle menu/needle-menu-spatial.ts +2 -2
  59. package/src/engine/webcomponents/needle menu/needle-menu.ts +5 -5
  60. package/src/engine/webcomponents/needle-engine.loading.ts +6 -6
  61. package/src/engine/webcomponents/needle-engine.ts +31 -2
  62. package/src/engine/xr/NeedleXRSync.ts +24 -4
  63. package/src/engine/xr/TempXRContext.ts +2 -2
  64. package/src/engine-components/SyncedTransform.ts +49 -10
  65. package/src/engine-components/export/usdz/USDZExporter.ts +4 -4
  66. package/src/engine-components/webxr/Avatar.ts +60 -33
  67. package/src/engine-schemes/synced-transform-model.ts +10 -1
  68. package/src/engine-schemes/transforms.fbs +1 -0
@@ -116,16 +116,12 @@ import { XRControllerModelFactory } from '../../../../node_modules/@types/three/
116
116
  import { XRHandMeshModel } from '../../../../node_modules/@types/three/examples/jsm/webxr/XRHandMeshModel.js';
117
117
  import { XRHandSpace } from 'three';
118
118
 
119
- export declare const $componentName: unique symbol;
119
+ /* Excluded from this release type: _$apSvAt */
120
120
 
121
- /* Excluded from this release type: $Mhcqc */
121
+ export declare const $componentName: unique symbol;
122
122
 
123
123
  export declare const $physicsKey: unique symbol;
124
124
 
125
- /* Excluded from this release type: $uRk */
126
-
127
- /* Excluded from this release type: __dSkNu */
128
-
129
125
  export declare class __Ignore {
130
126
  }
131
127
 
@@ -2126,6 +2122,8 @@ export declare class Avatar extends Component {
2126
2122
  rightHand?: AssetReference;
2127
2123
  private _leftHandMeshes?;
2128
2124
  private _rightHandMeshes?;
2125
+ private _remoteLeftHandMeshes?;
2126
+ private _remoteRightHandMeshes?;
2129
2127
  private _syncTransforms?;
2130
2128
  onEnterXR(_args: NeedleXREventArgs): Promise<void>;
2131
2129
  onLeaveXR(_args: NeedleXREventArgs): void;
@@ -2133,6 +2131,12 @@ export declare class Avatar extends Component {
2133
2131
  onBeforeRender(): void;
2134
2132
  private updateHandVisibility;
2135
2133
  private updateRemoteAvatarVisibility;
2134
+ /**
2135
+ * Show/hide a remote avatar hand render-only. The hand object stays active so its SyncedTransform keeps
2136
+ * applying networked updates (toggling `.visible` would deactivate it and could free the owner's ownership).
2137
+ * The mesh list is gathered lazily and cached, and returned so the caller can keep it.
2138
+ */
2139
+ private setRemoteHandRendered;
2136
2140
  private tryFindAvatarObjectsIfMissing;
2137
2141
  private prepareAvatar;
2138
2142
  private loadAvatarObjects;
@@ -8596,6 +8600,8 @@ export declare class HoverAnimation extends Component {
8596
8600
  /** SSR-safe base class for web components. */
8597
8601
  declare const HTMLElementBase: typeof HTMLElement;
8598
8602
 
8603
+ /* Excluded from this release type: _hyjgv */
8604
+
8599
8605
  export declare type IAnimationComponent = Pick<IComponent, "gameObject"> & {
8600
8606
  isAnimationComponent: boolean;
8601
8607
  addClip?(clip: AnimationClip): void;
@@ -10497,6 +10503,8 @@ export declare interface IXRRig extends Pick<IComponent, "gameObject"> {
10497
10503
  priority?: number;
10498
10504
  }
10499
10505
 
10506
+ /* Excluded from this release type: Jkdun */
10507
+
10500
10508
  /** Received when listening to `RoomEvents.JoinedRoom` event */
10501
10509
  export declare class JoinedRoomResponse {
10502
10510
  room: string;
@@ -21313,17 +21321,21 @@ export declare class OrbitControls extends Component implements ICameraControlle
21313
21321
  interpolatePosition: boolean;
21314
21322
  /** Whether to smoothly interpolate rotation changes when receiving updates */
21315
21323
  interpolateRotation: boolean;
21324
+ /** Whether to smoothly interpolate scale changes when receiving updates */
21325
+ interpolateScale: boolean;
21316
21326
  /** When true, sends updates at a higher frequency, useful for fast-moving objects */
21317
21327
  fastMode: boolean;
21318
21328
  /** When true, notifies other clients when this object is destroyed */
21319
21329
  syncDestroy: boolean;
21320
21330
  private _model;
21321
21331
  private _needsUpdate;
21332
+ private _hadOwnershipBeforeDisable;
21322
21333
  private rb;
21323
21334
  private _wasKinematic;
21324
21335
  private _receivedDataBefore;
21325
21336
  private _targetPosition;
21326
21337
  private _targetRotation;
21338
+ private _targetScale;
21327
21339
  private _receivedFastUpdate;
21328
21340
  private _shouldRequestOwnership;
21329
21341
  /**