@mml-io/3d-web-client-core 0.15.0 → 0.16.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.
@@ -2,7 +2,6 @@ export declare class KeyInputManager {
2
2
  private shouldCaptureKeyPress;
3
3
  private keys;
4
4
  private eventHandlerCollection;
5
- private directionJoystick;
6
5
  constructor(shouldCaptureKeyPress?: () => boolean);
7
6
  private handleUnfocus;
8
7
  private onKeyDown;
@@ -10,7 +10,7 @@ interface JoyStickAttributes {
10
10
  anchor?: "left" | "right";
11
11
  }
12
12
  export declare class VirtualJoystick {
13
- static JOYSTICK_DIV: HTMLDivElement | null;
13
+ private holderElement;
14
14
  private radius;
15
15
  private inner_radius;
16
16
  private anchor;
@@ -27,11 +27,9 @@ export declare class VirtualJoystick {
27
27
  up: boolean;
28
28
  down: boolean;
29
29
  hasDirection: boolean;
30
- constructor(attrs: JoyStickAttributes);
30
+ constructor(holderElement: HTMLElement, attrs: JoyStickAttributes);
31
31
  static checkForTouch(): boolean;
32
- static isTouchOnJoystick(touch: Touch): boolean;
33
32
  private checkTouch;
34
- private initializeJoystick;
35
33
  private setupBaseAndControl;
36
34
  private bindEvents;
37
35
  private handleTouchStart;
@@ -0,0 +1,19 @@
1
+ import { LoadingProgressManager } from "mml-web";
2
+ export declare class LoadingScreen {
3
+ private loadingProgressManager;
4
+ readonly element: HTMLDivElement;
5
+ private loadingBannerText;
6
+ private progressBarBackground;
7
+ private progressBarHolder;
8
+ private progressBar;
9
+ private loadingStatusText;
10
+ private progressDebugViewHolder;
11
+ private progressDebugView;
12
+ private progressDebugElement;
13
+ private debugLabel;
14
+ private debugCheckbox;
15
+ private hasCompleted;
16
+ private loadingCallback;
17
+ constructor(loadingProgressManager: LoadingProgressManager);
18
+ dispose(): void;
19
+ }
@@ -1,13 +1,17 @@
1
1
  import { IMMLScene, PositionAndRotation } from "mml-web";
2
2
  import { AudioListener, Group, PerspectiveCamera, Scene, WebGLRenderer } from "three";
3
3
  import { CollisionsManager } from "../collisions/CollisionsManager";
4
+ type MMLCompositionSceneConfig = {
5
+ targetElement: HTMLElement;
6
+ renderer: WebGLRenderer;
7
+ scene: Scene;
8
+ camera: PerspectiveCamera;
9
+ audioListener: AudioListener;
10
+ collisionsManager: CollisionsManager;
11
+ getUserPositionAndRotation: () => PositionAndRotation;
12
+ };
4
13
  export declare class MMLCompositionScene {
5
- private renderer;
6
- private scene;
7
- private camera;
8
- private audioListener;
9
- private collisionsManager;
10
- private getUserPositionAndRotation;
14
+ private config;
11
15
  group: Group;
12
16
  readonly mmlScene: IMMLScene;
13
17
  private readonly promptManager;
@@ -16,7 +20,8 @@ export declare class MMLCompositionScene {
16
20
  private readonly chatProbes;
17
21
  private readonly clickTrigger;
18
22
  private readonly loadingProgressManager;
19
- constructor(targetElement: HTMLElement, renderer: WebGLRenderer, scene: Scene, camera: PerspectiveCamera, audioListener: AudioListener, collisionsManager: CollisionsManager, getUserPositionAndRotation: () => PositionAndRotation);
23
+ constructor(config: MMLCompositionSceneConfig);
20
24
  onChatMessage(message: string): void;
21
25
  dispose(): void;
22
26
  }
27
+ export {};
@@ -40,6 +40,7 @@ export declare class Composer {
40
40
  dispose(): void;
41
41
  fitContainer(): void;
42
42
  render(timeManager: TimeManager): void;
43
+ useHDRJPG(url: string, fromFile?: boolean): void;
43
44
  useHDRI(url: string, fromFile?: boolean): void;
44
45
  setHDRIFromFile(): void;
45
46
  setFog(): void;
@@ -5,6 +5,7 @@ import { GaussGrainEffect } from "../rendering/post-effects/gauss-grain";
5
5
  import { Sun } from "../sun/Sun";
6
6
  import { TimeManager } from "../time/TimeManager";
7
7
  export declare class TweakPane {
8
+ private holderElement;
8
9
  private renderer;
9
10
  private scene;
10
11
  private composer;
@@ -20,7 +21,7 @@ export declare class TweakPane {
20
21
  private export;
21
22
  private saveVisibilityInLocalStorage;
22
23
  guiVisible: boolean;
23
- constructor(renderer: WebGLRenderer, scene: Scene, composer: EffectComposer);
24
+ constructor(holderElement: HTMLElement, renderer: WebGLRenderer, scene: Scene, composer: EffectComposer);
24
25
  private setupGUIListeners;
25
26
  private processKey;
26
27
  setupRenderPane(composer: EffectComposer, normalPass: NormalPass, ppssaoEffect: SSAOEffect, ppssaoPass: EffectPass, n8aopass: any, toneMappingEffect: ToneMappingEffect, toneMappingPass: EffectPass, brightnessContrastSaturation: typeof BrightnessContrastSaturation, bloomEffect: BloomEffect, gaussGrainEffect: typeof GaussGrainEffect, hasLighting: boolean, sun: Sun | null, setHDR: () => void, setAmbientLight: () => void, setFog: () => void): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mml-io/3d-web-client-core",
3
- "version": "0.15.0",
3
+ "version": "0.16.0",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -18,19 +18,21 @@
18
18
  "lint-fix": "eslint \"./{src,test}/**/*.{js,jsx,ts,tsx}\" --fix"
19
19
  },
20
20
  "dependencies": {
21
- "@mml-io/3d-web-avatar": "^0.15.0",
21
+ "@mml-io/3d-web-avatar": "^0.16.0",
22
+ "@mml-io/model-loader": "0.14.0",
23
+ "@monogrid/gainmap-js": "^3.0.5",
22
24
  "@tweakpane/core": "2.0.3",
23
25
  "@tweakpane/plugin-essentials": "0.2.1",
24
- "mml-web": "0.13.0",
25
- "postprocessing": "6.34.1",
26
- "three-mesh-bvh": "0.7.1",
26
+ "mml-web": "0.14.0",
27
+ "postprocessing": "6.35.4",
28
+ "three-mesh-bvh": "0.7.4",
27
29
  "tweakpane": "4.0.3"
28
30
  },
29
31
  "peerDependencies": {
30
- "three": ">= 0.153.0"
32
+ "three": ">= 0.163.0"
31
33
  },
32
34
  "devDependencies": {
33
- "@types/three": "0.153.0"
35
+ "@types/three": "0.163.0"
34
36
  },
35
- "gitHead": "8e179c2269a7865766dcab19e6a8992aec44feaa"
37
+ "gitHead": "c4ef44ae56497ed3cb9abaeee56be11dbc133460"
36
38
  }