@dcl/playground-assets 7.3.31-7169243942.commit-5f044c6 → 7.3.32-7170667436.commit-11a2181
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 +117 -16
- package/dist/beta.d.ts +109 -6
- package/dist/index.bundled.d.ts +109 -6
- package/dist/index.js +6 -6
- package/dist/index.js.map +4 -4
- package/dist/playground/sdk/apis.d.ts +7 -0
- package/dist/playground/sdk/dcl-sdk.package.json +2 -2
- package/dist/playground-assets.d.ts +117 -16
- package/etc/playground-assets.api.json +1264 -119
- package/etc/playground-assets.api.md +111 -10
- package/package.json +4 -4
@@ -34,10 +34,17 @@ declare module "~system/CommunicationsController" {
|
|
34
34
|
message: string;
|
35
35
|
}
|
36
36
|
export interface RealSendResponse {
|
37
|
+
}
|
38
|
+
export interface SendBinaryRequest {
|
39
|
+
data: Uint8Array[];
|
40
|
+
}
|
41
|
+
export interface SendBinaryResponse {
|
42
|
+
data: Uint8Array[];
|
37
43
|
}
|
38
44
|
|
39
45
|
// Function declaration section
|
40
46
|
export function send(body: RealSendRequest): Promise<RealSendResponse>;
|
47
|
+
export function sendBinary(body: SendBinaryRequest): Promise<SendBinaryResponse>;
|
41
48
|
|
42
49
|
}
|
43
50
|
/**
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@dcl/sdk",
|
3
3
|
"description": "",
|
4
|
-
"version": "7.3.
|
4
|
+
"version": "7.3.32-7170667436.commit-11a2181",
|
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": "11a21816f9bf404c90ba02782ad7e359262a909d"
|
39
39
|
}
|
@@ -1357,12 +1357,12 @@ export declare const CRDT_MESSAGE_HEADER_LENGTH = 8;
|
|
1357
1357
|
/**
|
1358
1358
|
* @public
|
1359
1359
|
*/
|
1360
|
-
export declare type CrdtMessage = PutComponentMessage | DeleteComponentMessage | DeleteEntityMessage |
|
1360
|
+
export declare type CrdtMessage = PutComponentMessage | DeleteComponentMessage | AppendValueMessage | DeleteEntityMessage | PutNetworkComponentMessage | DeleteComponentNetworkMessage | DeleteEntityNetworkMessage;
|
1361
1361
|
|
1362
1362
|
/**
|
1363
1363
|
* @public
|
1364
1364
|
*/
|
1365
|
-
export declare type CrdtMessageBody = PutComponentMessageBody | DeleteComponentMessageBody | DeleteEntityMessageBody | AppendValueMessageBody;
|
1365
|
+
export declare type CrdtMessageBody = PutComponentMessageBody | DeleteComponentMessageBody | DeleteEntityMessageBody | AppendValueMessageBody | CrdtNetworkMessageBody;
|
1366
1366
|
|
1367
1367
|
/**
|
1368
1368
|
* Min length = 8 bytes
|
@@ -1414,9 +1414,17 @@ export declare enum CrdtMessageType {
|
|
1414
1414
|
DELETE_COMPONENT = 2,
|
1415
1415
|
DELETE_ENTITY = 3,
|
1416
1416
|
APPEND_VALUE = 4,
|
1417
|
-
|
1417
|
+
PUT_COMPONENT_NETWORK = 5,
|
1418
|
+
DELETE_COMPONENT_NETWORK = 6,
|
1419
|
+
DELETE_ENTITY_NETWORK = 7,
|
1420
|
+
MAX_MESSAGE_TYPE = 8
|
1418
1421
|
}
|
1419
1422
|
|
1423
|
+
/**
|
1424
|
+
* @public
|
1425
|
+
*/
|
1426
|
+
export declare type CrdtNetworkMessageBody = PutNetworkComponentMessageBody | DeleteComponentNetworkMessageBody | DeleteEntityNetworkMessageBody;
|
1427
|
+
|
1420
1428
|
export declare function createEthereumProvider(): {
|
1421
1429
|
send(message: RPCSendableMessage, callback?: ((error: Error | null, result?: any) => void) | undefined): void;
|
1422
1430
|
sendAsync(message: RPCSendableMessage, callback: (error: Error | null, result?: any) => void): void;
|
@@ -1497,6 +1505,38 @@ export declare type DeleteComponentMessageBody = {
|
|
1497
1505
|
timestamp: number;
|
1498
1506
|
};
|
1499
1507
|
|
1508
|
+
/**
|
1509
|
+
* @public
|
1510
|
+
*/
|
1511
|
+
export declare namespace DeleteComponentNetwork {
|
1512
|
+
const MESSAGE_HEADER_LENGTH = 16;
|
1513
|
+
/**
|
1514
|
+
* Write DeleteComponent message
|
1515
|
+
*/
|
1516
|
+
export function write(entity: Entity, componentId: number, timestamp: number, networkId: number, buf: ByteBuffer): void;
|
1517
|
+
export function read(buf: ByteBuffer): DeleteComponentNetworkMessage | null;
|
1518
|
+
}
|
1519
|
+
|
1520
|
+
/**
|
1521
|
+
* @public
|
1522
|
+
*/
|
1523
|
+
export declare type DeleteComponentNetworkMessage = CrdtMessageHeader & DeleteComponentNetworkMessageBody;
|
1524
|
+
|
1525
|
+
/**
|
1526
|
+
* @param entity - Uint32 number of the entity
|
1527
|
+
* @param componentId - Uint32 number of id
|
1528
|
+
* @param timestamp - Uint32 Lamport timestamp
|
1529
|
+
* @param networkId - Uint32 user network id
|
1530
|
+
* @public
|
1531
|
+
*/
|
1532
|
+
export declare type DeleteComponentNetworkMessageBody = {
|
1533
|
+
type: CrdtMessageType.DELETE_COMPONENT_NETWORK;
|
1534
|
+
entityId: Entity;
|
1535
|
+
componentId: number;
|
1536
|
+
timestamp: number;
|
1537
|
+
networkId: number;
|
1538
|
+
};
|
1539
|
+
|
1500
1540
|
/**
|
1501
1541
|
* @public
|
1502
1542
|
*/
|
@@ -1520,6 +1560,29 @@ export declare type DeleteEntityMessageBody = {
|
|
1520
1560
|
entityId: Entity;
|
1521
1561
|
};
|
1522
1562
|
|
1563
|
+
/**
|
1564
|
+
* @public
|
1565
|
+
*/
|
1566
|
+
export declare namespace DeleteEntityNetwork {
|
1567
|
+
const MESSAGE_HEADER_LENGTH = 8;
|
1568
|
+
export function write(entity: Entity, networkId: number, buf: ByteBuffer): void;
|
1569
|
+
export function read(buf: ByteBuffer): DeleteEntityNetworkMessage | null;
|
1570
|
+
}
|
1571
|
+
|
1572
|
+
/**
|
1573
|
+
* @public
|
1574
|
+
*/
|
1575
|
+
export declare type DeleteEntityNetworkMessage = CrdtMessageHeader & DeleteEntityNetworkMessageBody;
|
1576
|
+
|
1577
|
+
/**
|
1578
|
+
* @public
|
1579
|
+
*/
|
1580
|
+
export declare type DeleteEntityNetworkMessageBody = {
|
1581
|
+
type: CrdtMessageType.DELETE_ENTITY_NETWORK;
|
1582
|
+
entityId: Entity;
|
1583
|
+
networkId: number;
|
1584
|
+
};
|
1585
|
+
|
1523
1586
|
/**
|
1524
1587
|
* @public
|
1525
1588
|
*/
|
@@ -2058,18 +2121,6 @@ export declare interface IEngine {
|
|
2058
2121
|
* components that will be available to this engine and to run optimizations.
|
2059
2122
|
*/
|
2060
2123
|
seal(): void;
|
2061
|
-
/**
|
2062
|
-
* @alpha
|
2063
|
-
* Initialize network manager
|
2064
|
-
*/
|
2065
|
-
addNetworkManager(reservedLocalEntities: number, range: [number, number]): {
|
2066
|
-
addEntity: IEngine['addEntity'];
|
2067
|
-
};
|
2068
|
-
/**
|
2069
|
-
* @alpha
|
2070
|
-
* Get netowrk manager to create entities.
|
2071
|
-
*/
|
2072
|
-
getNetworkManager(): ReturnType<IEngine['addNetworkManager']>;
|
2073
2124
|
}
|
2074
2125
|
|
2075
2126
|
/**
|
@@ -2253,6 +2304,20 @@ export declare type IncludeUndefined<T> = {
|
|
2253
2304
|
[P in keyof T]: undefined extends T[P] ? P : never;
|
2254
2305
|
}[keyof T];
|
2255
2306
|
|
2307
|
+
export declare type INetowrkEntity = LastWriteWinElementSetComponentDefinition<INetowrkEntityType>;
|
2308
|
+
|
2309
|
+
export declare interface INetowrkEntityType {
|
2310
|
+
networkId: number;
|
2311
|
+
entityId: Entity;
|
2312
|
+
}
|
2313
|
+
|
2314
|
+
export declare type INetowrkParent = LastWriteWinElementSetComponentDefinition<INetowrkParentType>;
|
2315
|
+
|
2316
|
+
export declare interface INetowrkParentType {
|
2317
|
+
networkId: number;
|
2318
|
+
entityId: Entity;
|
2319
|
+
}
|
2320
|
+
|
2256
2321
|
/**
|
2257
2322
|
* @public
|
2258
2323
|
* Input component
|
@@ -3409,6 +3474,18 @@ export declare interface NameType {
|
|
3409
3474
|
value: string;
|
3410
3475
|
}
|
3411
3476
|
|
3477
|
+
/**
|
3478
|
+
* @alpha
|
3479
|
+
* Tag a entity to be syncronized through comms
|
3480
|
+
*/
|
3481
|
+
export declare const NetworkEntity: INetowrkEntity;
|
3482
|
+
|
3483
|
+
/**
|
3484
|
+
* @alpha
|
3485
|
+
* Tag a entity to be syncronized through comms
|
3486
|
+
*/
|
3487
|
+
export declare const NetworkParent: INetowrkParent;
|
3488
|
+
|
3412
3489
|
/** NftFrameType is a predefined framing style for the image. */
|
3413
3490
|
/**
|
3414
3491
|
* @public
|
@@ -5343,6 +5420,29 @@ export declare namespace PutComponentOperation {
|
|
5343
5420
|
export function read(buf: ByteBuffer): PutComponentMessage | null;
|
5344
5421
|
}
|
5345
5422
|
|
5423
|
+
/**
|
5424
|
+
* @public
|
5425
|
+
*/
|
5426
|
+
export declare type PutNetworkComponentMessage = CrdtMessageHeader & PutNetworkComponentMessageBody;
|
5427
|
+
|
5428
|
+
export declare type PutNetworkComponentMessageBody = Omit<PutComponentMessageBody, 'type'> & {
|
5429
|
+
type: CrdtMessageType.PUT_COMPONENT_NETWORK;
|
5430
|
+
networkId: number;
|
5431
|
+
};
|
5432
|
+
|
5433
|
+
/**
|
5434
|
+
* @public
|
5435
|
+
*/
|
5436
|
+
export declare namespace PutNetworkComponentOperation {
|
5437
|
+
const MESSAGE_HEADER_LENGTH = 20;
|
5438
|
+
/**
|
5439
|
+
* Call this function for an optimal writing data passing the ByteBuffer
|
5440
|
+
* already allocated
|
5441
|
+
*/
|
5442
|
+
export function write(entity: Entity, timestamp: number, componentId: number, networkId: number, data: Uint8Array, buf: ByteBuffer): void;
|
5443
|
+
export function read(buf: ByteBuffer): PutNetworkComponentMessage | null;
|
5444
|
+
}
|
5445
|
+
|
5346
5446
|
/**
|
5347
5447
|
* @public
|
5348
5448
|
* Quaternion is a type and a namespace.
|
@@ -5890,7 +5990,7 @@ export declare namespace Rect {
|
|
5890
5990
|
* @param firstEntity - the root entity of the tree
|
5891
5991
|
* @public
|
5892
5992
|
*/
|
5893
|
-
export declare function removeEntityWithChildren(engine: Pick<IEngine, 'getEntitiesWith' | 'defineComponentFromSchema' | 'removeEntity'>, entity: Entity): void;
|
5993
|
+
export declare function removeEntityWithChildren(engine: Pick<IEngine, 'getEntitiesWith' | 'defineComponentFromSchema' | 'removeEntity' | 'defineComponent'>, entity: Entity): void;
|
5894
5994
|
|
5895
5995
|
export declare const RESERVED_LOCAL_ENTITIES = 65535;
|
5896
5996
|
|
@@ -6434,6 +6534,7 @@ export declare type Transport = {
|
|
6434
6534
|
send(message: Uint8Array): Promise<void>;
|
6435
6535
|
onmessage?(message: Uint8Array): void;
|
6436
6536
|
filter(message: Omit<TransportMessage, 'messageBuffer'>): boolean;
|
6537
|
+
type?: string;
|
6437
6538
|
};
|
6438
6539
|
|
6439
6540
|
/**
|