@dcl/playground-assets 7.4.18 → 7.4.19-8818968750.commit-6d2ec97
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/alpha.d.ts +24 -257
- package/dist/beta.d.ts +24 -257
- package/dist/index.bundled.d.ts +24 -257
- package/dist/index.js +6 -6
- package/dist/index.js.map +4 -4
- package/dist/playground/sdk/apis.d.ts +6 -3
- package/dist/playground/sdk/dcl-sdk.package.json +2 -2
- package/dist/playground-assets.d.ts +24 -257
- package/etc/playground-assets.api.json +637 -1489
- package/etc/playground-assets.api.md +28 -143
- package/package.json +4 -4
|
@@ -1310,15 +1310,18 @@ declare module "~system/Runtime" {
|
|
|
1310
1310
|
}
|
|
1311
1311
|
|
|
1312
1312
|
// Function declaration section
|
|
1313
|
-
export interface
|
|
1313
|
+
export interface PBRealmInfo {
|
|
1314
1314
|
baseUrl: string;
|
|
1315
1315
|
realmName: string;
|
|
1316
1316
|
networkId: number;
|
|
1317
1317
|
commsAdapter: string;
|
|
1318
1318
|
isPreview: boolean;
|
|
1319
|
+
room?: string | undefined;
|
|
1319
1320
|
}
|
|
1320
|
-
|
|
1321
|
-
|
|
1321
|
+
|
|
1322
|
+
// Function declaration section
|
|
1323
|
+
export interface GetRealmResponse {
|
|
1324
|
+
realmInfo?: PBRealmInfo | undefined;
|
|
1322
1325
|
}
|
|
1323
1326
|
export interface GetWorldTimeResponse {
|
|
1324
1327
|
seconds: number;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dcl/sdk",
|
|
3
3
|
"description": "",
|
|
4
|
-
"version": "7.4.
|
|
4
|
+
"version": "7.4.19-8818968750.commit-6d2ec97",
|
|
5
5
|
"author": "Decentraland",
|
|
6
6
|
"dependencies": {
|
|
7
7
|
"@dcl/ecs": "file:../ecs",
|
|
@@ -35,5 +35,5 @@
|
|
|
35
35
|
},
|
|
36
36
|
"types": "./index.d.ts",
|
|
37
37
|
"typings": "./index.d.ts",
|
|
38
|
-
"commit": "
|
|
38
|
+
"commit": "6d2ec97a241339671c7b75c6971003d24d3fe233"
|
|
39
39
|
}
|
|
@@ -1245,6 +1245,7 @@ export declare const componentDefinitionByName: {
|
|
|
1245
1245
|
"core::PointerLock": LwwComponentGetter<LastWriteWinElementSetComponentDefinition<PBPointerLock>>;
|
|
1246
1246
|
"core::Raycast": LwwComponentGetter<LastWriteWinElementSetComponentDefinition<PBRaycast>>;
|
|
1247
1247
|
"core::RaycastResult": LwwComponentGetter<LastWriteWinElementSetComponentDefinition<PBRaycastResult>>;
|
|
1248
|
+
"core::RealmInfo": LwwComponentGetter<LastWriteWinElementSetComponentDefinition<PBRealmInfo>>;
|
|
1248
1249
|
"core::TextShape": LwwComponentGetter<LastWriteWinElementSetComponentDefinition<PBTextShape>>;
|
|
1249
1250
|
"core::Tween": LwwComponentGetter<LastWriteWinElementSetComponentDefinition<PBTween>>;
|
|
1250
1251
|
"core::TweenSequence": LwwComponentGetter<LastWriteWinElementSetComponentDefinition<PBTweenSequence>>;
|
|
@@ -1787,13 +1788,6 @@ export declare function Engine(options?: IEngineOptions): IEngine;
|
|
|
1787
1788
|
*/
|
|
1788
1789
|
export declare const engine: IEngine;
|
|
1789
1790
|
|
|
1790
|
-
/** @public */
|
|
1791
|
-
export declare type EngineEvent<T extends IEventNames = IEventNames, V = IEvents[T]> = {
|
|
1792
|
-
/** eventName */
|
|
1793
|
-
type: T;
|
|
1794
|
-
data: Readonly<V>;
|
|
1795
|
-
};
|
|
1796
|
-
|
|
1797
1791
|
/** @public */
|
|
1798
1792
|
export declare const EngineInfo: LastWriteWinElementSetComponentDefinition<PBEngineInfo>;
|
|
1799
1793
|
|
|
@@ -1966,39 +1960,12 @@ export declare function getComponentEntityTree<T>(engine: Pick<IEngine, 'getEnti
|
|
|
1966
1960
|
*/
|
|
1967
1961
|
export declare function getCompositeRootComponent(engine: IEngine): LastWriteWinElementSetComponentDefinition<CompositeRootType>;
|
|
1968
1962
|
|
|
1969
|
-
/** @public */
|
|
1970
|
-
export declare type GizmoDragEndEvent = {
|
|
1971
|
-
type: 'gizmoDragEnded';
|
|
1972
|
-
transforms: Array<{
|
|
1973
|
-
position: Vector3Type;
|
|
1974
|
-
rotation: QuaternionType;
|
|
1975
|
-
scale: Vector3Type;
|
|
1976
|
-
entityId: unknown;
|
|
1977
|
-
}>;
|
|
1978
|
-
};
|
|
1979
|
-
|
|
1980
|
-
/** @public */
|
|
1981
|
-
export declare type GizmoSelectedEvent = {
|
|
1982
|
-
type: 'gizmoSelected';
|
|
1983
|
-
gizmoType: 'MOVE' | 'ROTATE' | 'SCALE' | 'NONE';
|
|
1984
|
-
entities: string[];
|
|
1985
|
-
};
|
|
1986
|
-
|
|
1987
1963
|
export declare type GlobalDirectionRaycastOptions = RaycastSystemOptions & GlobalDirectionRaycastSystemOptions;
|
|
1988
1964
|
|
|
1989
1965
|
export declare type GlobalDirectionRaycastSystemOptions = {
|
|
1990
1966
|
direction?: PBVector3;
|
|
1991
1967
|
};
|
|
1992
1968
|
|
|
1993
|
-
/** @public */
|
|
1994
|
-
export declare type GlobalInputEventResult = InputEventResult & {
|
|
1995
|
-
/**
|
|
1996
|
-
* DOWN = 0,
|
|
1997
|
-
* UP = 1
|
|
1998
|
-
*/
|
|
1999
|
-
type: 0 | 1;
|
|
2000
|
-
};
|
|
2001
|
-
|
|
2002
1969
|
export declare type GlobalTargetRaycastOptions = RaycastSystemOptions & GlobalTargetRaycastSystemOptions;
|
|
2003
1970
|
|
|
2004
1971
|
export declare type GlobalTargetRaycastSystemOptions = {
|
|
@@ -2254,156 +2221,9 @@ export declare type IEventNames = keyof IEvents;
|
|
|
2254
2221
|
* Note: Don't use `on` prefix for IEvents to avoid redundancy with `event.on("onEventName")` syntax.
|
|
2255
2222
|
*/
|
|
2256
2223
|
export declare interface IEvents {
|
|
2257
|
-
/**
|
|
2258
|
-
* `positionChanged` is triggered when the position of the camera changes
|
|
2259
|
-
* This event is throttled to 10 times per second.
|
|
2260
|
-
*/
|
|
2261
|
-
positionChanged: {
|
|
2262
|
-
/** Camera position relative to the base parcel of the scene */
|
|
2263
|
-
position: Vector3Type;
|
|
2264
|
-
/** Camera position, this is a absolute world position */
|
|
2265
|
-
cameraPosition: Vector3Type;
|
|
2266
|
-
/** Eye height, in meters. */
|
|
2267
|
-
playerHeight: number;
|
|
2268
|
-
};
|
|
2269
|
-
/**
|
|
2270
|
-
* `rotationChanged` is triggered when the rotation of the camera changes.
|
|
2271
|
-
* This event is throttled to 10 times per second.
|
|
2272
|
-
*/
|
|
2273
|
-
rotationChanged: {
|
|
2274
|
-
/** Degree vector. Same as entities */
|
|
2275
|
-
rotation: Vector3Type;
|
|
2276
|
-
/** Rotation quaternion, useful in some scenarios. */
|
|
2277
|
-
quaternion: QuaternionType;
|
|
2278
|
-
};
|
|
2279
|
-
/**
|
|
2280
|
-
* `cameraModeChanged` is triggered when the user changes the camera mode
|
|
2281
|
-
*/
|
|
2282
|
-
cameraModeChanged: {
|
|
2283
|
-
/**
|
|
2284
|
-
* FIRST_PERSON = 0,
|
|
2285
|
-
* THIRD_PERSON = 1,
|
|
2286
|
-
* FREE_CAMERA = 2
|
|
2287
|
-
*/
|
|
2288
|
-
cameraMode: 0 | 1 | 2;
|
|
2289
|
-
};
|
|
2290
|
-
/**
|
|
2291
|
-
* `idleStateChanged` is triggered when the user not moves for a defined period of time
|
|
2292
|
-
*/
|
|
2293
|
-
idleStateChanged: {
|
|
2294
|
-
isIdle: boolean;
|
|
2295
|
-
};
|
|
2296
2224
|
playerExpression: {
|
|
2297
2225
|
expressionId: string;
|
|
2298
2226
|
};
|
|
2299
|
-
/**
|
|
2300
|
-
* `pointerUp` is triggered when the user releases an input pointer.
|
|
2301
|
-
* It could be a VR controller, a touch screen or the mouse.
|
|
2302
|
-
*/
|
|
2303
|
-
pointerUp: InputEventResult;
|
|
2304
|
-
/**
|
|
2305
|
-
* `pointerDown` is triggered when the user press an input pointer.
|
|
2306
|
-
* It could be a VR controller, a touch screen or the mouse.
|
|
2307
|
-
*/
|
|
2308
|
-
pointerDown: InputEventResult;
|
|
2309
|
-
/**
|
|
2310
|
-
* `pointerEvent` is triggered when the user press or releases an input pointer.
|
|
2311
|
-
* It could be a VR controller, a touch screen or the mouse.
|
|
2312
|
-
*
|
|
2313
|
-
* @deprecated use actionButtonEvent instead
|
|
2314
|
-
*/
|
|
2315
|
-
pointerEvent: GlobalInputEventResult;
|
|
2316
|
-
/**
|
|
2317
|
-
* `actionButtonEvent` is triggered when the user press or releases an input pointer.
|
|
2318
|
-
* It could be a VR controller, a touch screen or the mouse.
|
|
2319
|
-
*
|
|
2320
|
-
* This event is exactly the same as `pointerEvent` but the logic in the ECS had an unsolvable
|
|
2321
|
-
* condition that required us to create this new event to handle more cases for new buttons.
|
|
2322
|
-
*/
|
|
2323
|
-
actionButtonEvent: GlobalInputEventResult;
|
|
2324
|
-
/**
|
|
2325
|
-
* `raycastResponse` is triggered in response to a raycast query
|
|
2326
|
-
*/
|
|
2327
|
-
raycastResponse: RaycastResponsePayload<any>;
|
|
2328
|
-
/**
|
|
2329
|
-
* `chatMessage` is triggered when the user sends a message through chat entity.
|
|
2330
|
-
*/
|
|
2331
|
-
chatMessage: {
|
|
2332
|
-
id: string;
|
|
2333
|
-
sender: string;
|
|
2334
|
-
message: string;
|
|
2335
|
-
isCommand: boolean;
|
|
2336
|
-
};
|
|
2337
|
-
/**
|
|
2338
|
-
* `onChange` is triggered when an entity changes its own internal state.
|
|
2339
|
-
* Dispatched by the `ui-*` entities when their value is changed. It triggers a callback.
|
|
2340
|
-
* Notice: Only entities with ID will be listening for click events.
|
|
2341
|
-
*/
|
|
2342
|
-
onChange: {
|
|
2343
|
-
value?: any;
|
|
2344
|
-
/** ID of the pointer that triggered the event */
|
|
2345
|
-
pointerId?: number;
|
|
2346
|
-
};
|
|
2347
|
-
/**
|
|
2348
|
-
* `onEnter` is triggered when the user hits the "Enter" key from the keyboard
|
|
2349
|
-
* Used principally by the Chat internal scene
|
|
2350
|
-
*/
|
|
2351
|
-
onEnter: unknown;
|
|
2352
|
-
/**
|
|
2353
|
-
* `onPointerLock` is triggered when the user clicks the world canvas and the
|
|
2354
|
-
* pointer locks to it so the pointer moves the camera
|
|
2355
|
-
*/
|
|
2356
|
-
onPointerLock: {
|
|
2357
|
-
locked?: boolean;
|
|
2358
|
-
};
|
|
2359
|
-
/**
|
|
2360
|
-
* `onAnimationEnd` is triggered when an animation clip gets finish
|
|
2361
|
-
*/
|
|
2362
|
-
onAnimationEnd: {
|
|
2363
|
-
clipName: string;
|
|
2364
|
-
};
|
|
2365
|
-
/**
|
|
2366
|
-
* `onFocus` is triggered when an entity focus is active.
|
|
2367
|
-
* Dispatched by the `ui-input` and `ui-password` entities when the value is changed.
|
|
2368
|
-
* It triggers a callback.
|
|
2369
|
-
*
|
|
2370
|
-
* Notice: Only entities with ID will be listening for click events.
|
|
2371
|
-
*/
|
|
2372
|
-
onFocus: {
|
|
2373
|
-
/** ID of the entitiy of the event */
|
|
2374
|
-
entityId: unknown;
|
|
2375
|
-
/** ID of the pointer that triggered the event */
|
|
2376
|
-
pointerId: number;
|
|
2377
|
-
};
|
|
2378
|
-
/**
|
|
2379
|
-
* `onBlur` is triggered when an entity loses its focus.
|
|
2380
|
-
* Dispatched by the `ui-input` and `ui-password` entities when the value is changed.
|
|
2381
|
-
* It triggers a callback.
|
|
2382
|
-
*
|
|
2383
|
-
* Notice: Only entities with ID will be listening for click events.
|
|
2384
|
-
*/
|
|
2385
|
-
onBlur: {
|
|
2386
|
-
/** ID of the entitiy of the event */
|
|
2387
|
-
entityId: unknown;
|
|
2388
|
-
/** ID of the pointer that triggered the event */
|
|
2389
|
-
pointerId: number;
|
|
2390
|
-
};
|
|
2391
|
-
/** The onClick event is only used for UI elements */
|
|
2392
|
-
onClick: {
|
|
2393
|
-
entityId: unknown;
|
|
2394
|
-
};
|
|
2395
|
-
/**
|
|
2396
|
-
* This event gets triggered when an entity leaves the scene fences.
|
|
2397
|
-
*/
|
|
2398
|
-
entityOutOfScene: {
|
|
2399
|
-
entityId: unknown;
|
|
2400
|
-
};
|
|
2401
|
-
/**
|
|
2402
|
-
* This event gets triggered when an entity enters the scene fences.
|
|
2403
|
-
*/
|
|
2404
|
-
entityBackInScene: {
|
|
2405
|
-
entityId: unknown;
|
|
2406
|
-
};
|
|
2407
2227
|
/**
|
|
2408
2228
|
* This event gets triggered when the user enters the scene
|
|
2409
2229
|
*/
|
|
@@ -2427,46 +2247,6 @@ export declare interface IEvents {
|
|
|
2427
2247
|
* This is triggered once the scene should start.
|
|
2428
2248
|
*/
|
|
2429
2249
|
sceneStart: unknown;
|
|
2430
|
-
/**
|
|
2431
|
-
* This is triggered once the builder scene is loaded.
|
|
2432
|
-
*/
|
|
2433
|
-
builderSceneStart: unknown;
|
|
2434
|
-
/**
|
|
2435
|
-
* This is triggered once the builder scene is unloaded.
|
|
2436
|
-
*/
|
|
2437
|
-
builderSceneUnloaded: unknown;
|
|
2438
|
-
/**
|
|
2439
|
-
* After checking entities outside the fences, if any is outside, this event
|
|
2440
|
-
* will be triggered with all the entities outside the scene.
|
|
2441
|
-
*/
|
|
2442
|
-
entitiesOutOfBoundaries: {
|
|
2443
|
-
entities: string[];
|
|
2444
|
-
};
|
|
2445
|
-
uuidEvent: {
|
|
2446
|
-
uuid: string;
|
|
2447
|
-
payload: any;
|
|
2448
|
-
};
|
|
2449
|
-
onTextSubmit: {
|
|
2450
|
-
text: string;
|
|
2451
|
-
};
|
|
2452
|
-
metricsUpdate: {
|
|
2453
|
-
given: Record<string, number>;
|
|
2454
|
-
limit: Record<string, number>;
|
|
2455
|
-
};
|
|
2456
|
-
limitsExceeded: {
|
|
2457
|
-
given: Record<string, number>;
|
|
2458
|
-
limit: Record<string, number>;
|
|
2459
|
-
};
|
|
2460
|
-
/** For gizmos */
|
|
2461
|
-
gizmoEvent: GizmoDragEndEvent | GizmoSelectedEvent;
|
|
2462
|
-
externalAction: {
|
|
2463
|
-
type: string;
|
|
2464
|
-
[key: string]: any;
|
|
2465
|
-
};
|
|
2466
|
-
stateEvent: {
|
|
2467
|
-
type: string;
|
|
2468
|
-
payload: any;
|
|
2469
|
-
};
|
|
2470
2250
|
/** This is triggered at least for each videoStatus change */
|
|
2471
2251
|
videoEvent: {
|
|
2472
2252
|
componentId: string;
|
|
@@ -2507,10 +2287,6 @@ export declare interface IEvents {
|
|
|
2507
2287
|
distance: number;
|
|
2508
2288
|
};
|
|
2509
2289
|
};
|
|
2510
|
-
/** Triggered when pointer start hovering an entities' shape */
|
|
2511
|
-
pointerHoverEnter: unknown;
|
|
2512
|
-
/** Triggered when pointer stop hovering an entities' shape */
|
|
2513
|
-
pointerHoverExit: unknown;
|
|
2514
2290
|
}
|
|
2515
2291
|
|
|
2516
2292
|
/**
|
|
@@ -2609,31 +2385,6 @@ export declare const enum InputAction {
|
|
|
2609
2385
|
IA_ACTION_6 = 13
|
|
2610
2386
|
}
|
|
2611
2387
|
|
|
2612
|
-
/** @public */
|
|
2613
|
-
export declare type InputEventResult = {
|
|
2614
|
-
/** Origin of the ray, relative to the scene */
|
|
2615
|
-
origin: Vector3Type;
|
|
2616
|
-
/** Direction vector of the ray (normalized) */
|
|
2617
|
-
direction: Vector3Type;
|
|
2618
|
-
/** ID of the pointer that triggered the event */
|
|
2619
|
-
buttonId: number;
|
|
2620
|
-
/** Does this pointer event hit any object? */
|
|
2621
|
-
hit?: {
|
|
2622
|
-
/** Length of the ray */
|
|
2623
|
-
length: number;
|
|
2624
|
-
/** If the ray hits a mesh the intersection point will be this */
|
|
2625
|
-
hitPoint: Vector3Type;
|
|
2626
|
-
/** If the mesh has a name, it will be assigned to meshName */
|
|
2627
|
-
meshName: string;
|
|
2628
|
-
/** Normal of the hit */
|
|
2629
|
-
normal: Vector3Type;
|
|
2630
|
-
/** Normal of the hit, in world space */
|
|
2631
|
-
worldNormal: Vector3Type;
|
|
2632
|
-
/** Hit entity ID if any */
|
|
2633
|
-
entityId: unknown;
|
|
2634
|
-
};
|
|
2635
|
-
};
|
|
2636
|
-
|
|
2637
2388
|
/**
|
|
2638
2389
|
* @public
|
|
2639
2390
|
* Input system manager. Check for button events
|
|
@@ -5209,6 +4960,26 @@ export declare namespace PBRaycastResult {
|
|
|
5209
4960
|
export function decode(input: _m0.Reader | Uint8Array, length?: number): PBRaycastResult;
|
|
5210
4961
|
}
|
|
5211
4962
|
|
|
4963
|
+
/**
|
|
4964
|
+
* @public
|
|
4965
|
+
*/
|
|
4966
|
+
export declare interface PBRealmInfo {
|
|
4967
|
+
baseUrl: string;
|
|
4968
|
+
realmName: string;
|
|
4969
|
+
networkId: number;
|
|
4970
|
+
commsAdapter: string;
|
|
4971
|
+
isPreview: boolean;
|
|
4972
|
+
room?: string | undefined;
|
|
4973
|
+
}
|
|
4974
|
+
|
|
4975
|
+
/**
|
|
4976
|
+
* @public
|
|
4977
|
+
*/
|
|
4978
|
+
export declare namespace PBRealmInfo {
|
|
4979
|
+
export function encode(message: PBRealmInfo, writer?: _m0.Writer): _m0.Writer;
|
|
4980
|
+
export function decode(input: _m0.Reader | Uint8Array, length?: number): PBRealmInfo;
|
|
4981
|
+
}
|
|
4982
|
+
|
|
5212
4983
|
/**
|
|
5213
4984
|
* The TextShape component renders customizable floating text.
|
|
5214
4985
|
*
|
|
@@ -6352,13 +6123,6 @@ export declare const enum RaycastQueryType {
|
|
|
6352
6123
|
RQT_NONE = 2
|
|
6353
6124
|
}
|
|
6354
6125
|
|
|
6355
|
-
/** @public */
|
|
6356
|
-
export declare type RaycastResponsePayload<T> = {
|
|
6357
|
-
queryId: string;
|
|
6358
|
-
queryType: string;
|
|
6359
|
-
payload: T;
|
|
6360
|
-
};
|
|
6361
|
-
|
|
6362
6126
|
/** @public */
|
|
6363
6127
|
export declare const RaycastResult: LastWriteWinElementSetComponentDefinition<PBRaycastResult>;
|
|
6364
6128
|
|
|
@@ -6559,6 +6323,9 @@ export declare type ReadOnlyLastWriteWinElementSetComponentDefinition<T> = Omit<
|
|
|
6559
6323
|
*/
|
|
6560
6324
|
export declare type ReadonlyPrimitive = number | string | number[] | string[] | boolean | boolean[];
|
|
6561
6325
|
|
|
6326
|
+
/** @public */
|
|
6327
|
+
export declare const RealmInfo: LastWriteWinElementSetComponentDefinition<PBRealmInfo>;
|
|
6328
|
+
|
|
6562
6329
|
/**
|
|
6563
6330
|
* @public
|
|
6564
6331
|
*/
|