@tresjs/cientos 2.1.4 → 2.2.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/composables/useLogger.d.ts +8 -0
- package/dist/core/abstractions/index.d.ts +1 -1
- package/dist/core/controls/KeyboardControls.vue.d.ts +151 -0
- package/dist/core/controls/index.d.ts +2 -1
- package/dist/core/loaders/index.d.ts +2 -1
- package/dist/core/loaders/useProgress.d.ts +6 -0
- package/dist/trescientos.js +3707 -3582
- package/dist/trescientos.umd.cjs +15 -15
- package/package.json +1 -1
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const isProd: boolean;
|
|
2
|
+
interface LoggerComposition {
|
|
3
|
+
logError: (message: string, error?: Error | ErrorEvent) => void;
|
|
4
|
+
logWarning: (message: string) => void;
|
|
5
|
+
logMessage: (name: string, value: any) => void;
|
|
6
|
+
}
|
|
7
|
+
export declare function useLogger(): LoggerComposition;
|
|
8
|
+
export {};
|
|
@@ -9,4 +9,4 @@ import Levioso from './Levioso.vue';
|
|
|
9
9
|
import ContactShadows from './ContactShadows.vue';
|
|
10
10
|
export * from './useParallax';
|
|
11
11
|
export * from './useEnvironment';
|
|
12
|
-
export { Text3D, useAnimations, Environment, MouseParallax, Stars, Smoke, Levioso, ContactShadows, Precipitation };
|
|
12
|
+
export { Text3D, useAnimations, Environment, MouseParallax, Stars, Smoke, Levioso, ContactShadows, Precipitation, };
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
import type { PropType as __PropType } from 'vue';
|
|
2
|
+
export type KeyboardControlsProps = {
|
|
3
|
+
/**
|
|
4
|
+
* Keys to go forward.
|
|
5
|
+
* @type {string[]}
|
|
6
|
+
* @default '[w, W]'
|
|
7
|
+
* @memberof KeyboardControlsProps
|
|
8
|
+
*
|
|
9
|
+
**/
|
|
10
|
+
forward?: string[] | string;
|
|
11
|
+
/**
|
|
12
|
+
* Keys to go back.
|
|
13
|
+
* @type {string[]}
|
|
14
|
+
* @default '[s, S]'
|
|
15
|
+
* @memberof KeyboardControlsProps
|
|
16
|
+
*
|
|
17
|
+
**/
|
|
18
|
+
back?: string[] | string;
|
|
19
|
+
/**
|
|
20
|
+
* Keys to go left.
|
|
21
|
+
* @type {string[]}
|
|
22
|
+
* @default '[a, A]'
|
|
23
|
+
* @memberof KeyboardControlsProps
|
|
24
|
+
*
|
|
25
|
+
**/
|
|
26
|
+
left?: string[] | string;
|
|
27
|
+
/**
|
|
28
|
+
* Keys to go right.
|
|
29
|
+
* @type {string[]}
|
|
30
|
+
* @default '[d, D]'
|
|
31
|
+
* @memberof KeyboardControlsProps
|
|
32
|
+
*
|
|
33
|
+
**/
|
|
34
|
+
right?: string[] | string;
|
|
35
|
+
/**
|
|
36
|
+
* Key to jump (only with PointerLockControls).
|
|
37
|
+
* @type {string[]}
|
|
38
|
+
* @default 'space'
|
|
39
|
+
* @memberof KeyboardControlsProps
|
|
40
|
+
*
|
|
41
|
+
**/
|
|
42
|
+
jump?: string[] | string;
|
|
43
|
+
/**
|
|
44
|
+
* Default gravity number for jump.
|
|
45
|
+
* @type {number}
|
|
46
|
+
* @default 9.8
|
|
47
|
+
* @memberof KeyboardControlsProps
|
|
48
|
+
*
|
|
49
|
+
**/
|
|
50
|
+
gravity?: number;
|
|
51
|
+
/**
|
|
52
|
+
* Speed movement.
|
|
53
|
+
* @type {number}
|
|
54
|
+
* @default 0.1
|
|
55
|
+
* @memberof KeyboardControlsProps
|
|
56
|
+
*
|
|
57
|
+
**/
|
|
58
|
+
moveSpeed?: number;
|
|
59
|
+
/**
|
|
60
|
+
* Activate/deactivate headBobbing effect (only with PointerLockControls).
|
|
61
|
+
* @type {boolean}
|
|
62
|
+
* @default false
|
|
63
|
+
* @memberof KeyboardControlsProps
|
|
64
|
+
*
|
|
65
|
+
**/
|
|
66
|
+
headBobbing?: boolean;
|
|
67
|
+
/**
|
|
68
|
+
* Indicates if the forward movement is in the Z axis or Y axis.
|
|
69
|
+
* @type {boolean}
|
|
70
|
+
* @default false
|
|
71
|
+
* @memberof KeyboardControlsProps
|
|
72
|
+
*
|
|
73
|
+
**/
|
|
74
|
+
is2D?: boolean;
|
|
75
|
+
};
|
|
76
|
+
declare const _sfc_main: import("vue").DefineComponent<{
|
|
77
|
+
forward: {
|
|
78
|
+
type: __PropType<string | string[] | undefined>;
|
|
79
|
+
required: false;
|
|
80
|
+
};
|
|
81
|
+
back: {
|
|
82
|
+
type: __PropType<string | string[] | undefined>;
|
|
83
|
+
required: false;
|
|
84
|
+
};
|
|
85
|
+
left: {
|
|
86
|
+
type: __PropType<string | string[] | undefined>;
|
|
87
|
+
required: false;
|
|
88
|
+
};
|
|
89
|
+
right: {
|
|
90
|
+
type: __PropType<string | string[] | undefined>;
|
|
91
|
+
required: false;
|
|
92
|
+
};
|
|
93
|
+
jump: {
|
|
94
|
+
type: __PropType<string | string[] | undefined>;
|
|
95
|
+
required: false;
|
|
96
|
+
};
|
|
97
|
+
gravity: {
|
|
98
|
+
type: __PropType<number | undefined>;
|
|
99
|
+
required: false;
|
|
100
|
+
};
|
|
101
|
+
moveSpeed: {
|
|
102
|
+
type: __PropType<number | undefined>;
|
|
103
|
+
required: false;
|
|
104
|
+
};
|
|
105
|
+
headBobbing: {
|
|
106
|
+
type: __PropType<boolean | undefined>;
|
|
107
|
+
required: false;
|
|
108
|
+
};
|
|
109
|
+
is2D: {
|
|
110
|
+
type: __PropType<boolean | undefined>;
|
|
111
|
+
required: false;
|
|
112
|
+
};
|
|
113
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
114
|
+
forward: {
|
|
115
|
+
type: __PropType<string | string[] | undefined>;
|
|
116
|
+
required: false;
|
|
117
|
+
};
|
|
118
|
+
back: {
|
|
119
|
+
type: __PropType<string | string[] | undefined>;
|
|
120
|
+
required: false;
|
|
121
|
+
};
|
|
122
|
+
left: {
|
|
123
|
+
type: __PropType<string | string[] | undefined>;
|
|
124
|
+
required: false;
|
|
125
|
+
};
|
|
126
|
+
right: {
|
|
127
|
+
type: __PropType<string | string[] | undefined>;
|
|
128
|
+
required: false;
|
|
129
|
+
};
|
|
130
|
+
jump: {
|
|
131
|
+
type: __PropType<string | string[] | undefined>;
|
|
132
|
+
required: false;
|
|
133
|
+
};
|
|
134
|
+
gravity: {
|
|
135
|
+
type: __PropType<number | undefined>;
|
|
136
|
+
required: false;
|
|
137
|
+
};
|
|
138
|
+
moveSpeed: {
|
|
139
|
+
type: __PropType<number | undefined>;
|
|
140
|
+
required: false;
|
|
141
|
+
};
|
|
142
|
+
headBobbing: {
|
|
143
|
+
type: __PropType<boolean | undefined>;
|
|
144
|
+
required: false;
|
|
145
|
+
};
|
|
146
|
+
is2D: {
|
|
147
|
+
type: __PropType<boolean | undefined>;
|
|
148
|
+
required: false;
|
|
149
|
+
};
|
|
150
|
+
}>>, {}, {}>;
|
|
151
|
+
export default _sfc_main;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import OrbitControls from './OrbitControls.vue';
|
|
2
|
+
import KeyboardControls from './KeyboardControls.vue';
|
|
2
3
|
import TransformControls from './TransformControls.vue';
|
|
3
4
|
import PointerLockControls from './PointerLockControls.vue';
|
|
4
5
|
import MapControls from './MapControls.vue';
|
|
5
|
-
export { OrbitControls, TransformControls, PointerLockControls, MapControls };
|
|
6
|
+
export { OrbitControls, TransformControls, PointerLockControls, MapControls, KeyboardControls };
|
|
@@ -2,4 +2,5 @@ import GLTFModel from './useGLTF/component.vue';
|
|
|
2
2
|
import FBXModel from './useFBX/component.vue';
|
|
3
3
|
export * from './useGLTF';
|
|
4
4
|
export * from './useFBX';
|
|
5
|
-
|
|
5
|
+
import { useProgress } from './useProgress';
|
|
6
|
+
export { FBXModel, GLTFModel, useProgress };
|