@dcl/playground-assets 7.0.6-3713220614.commit-d02ef9f → 7.0.6-3741197705.commit-bb37667
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 +92 -230
- package/dist/beta.d.ts +92 -230
- package/dist/index.bundled.d.ts +92 -230
- package/dist/index.js +155 -174
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/dist/playground/sdk/dcl-sdk.package.json +2 -2
- package/dist/playground-assets.d.ts +92 -230
- package/etc/playground-assets.api.json +658 -1527
- package/etc/playground-assets.api.md +79 -226
- package/package.json +3 -3
package/dist/alpha.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ export declare const Animator: AnimatorComponentDefinitionExtended;
|
|
|
5
5
|
/**
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
8
|
-
export declare type AnimatorComponentDefinition = ComponentDefinition<
|
|
8
|
+
export declare type AnimatorComponentDefinition = ComponentDefinition<PBAnimator>;
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
11
|
* @public
|
|
@@ -50,32 +50,11 @@ export declare interface AnimatorComponentDefinitionExtended extends AnimatorCom
|
|
|
50
50
|
stopAllAnimations(entity: Entity, resetCursor?: boolean): boolean;
|
|
51
51
|
}
|
|
52
52
|
|
|
53
|
-
/**
|
|
54
|
-
*
|
|
55
|
-
*/
|
|
56
|
-
export declare const AnimatorSchema: ISchema<PBAnimator> & {
|
|
57
|
-
COMPONENT_ID: number;
|
|
58
|
-
};
|
|
59
|
-
|
|
60
53
|
/** @public */
|
|
61
|
-
export declare const AudioSource: ComponentDefinition<
|
|
62
|
-
|
|
63
|
-
/**
|
|
64
|
-
*
|
|
65
|
-
*/
|
|
66
|
-
export declare const AudioSourceSchema: ISchema<PBAudioSource> & {
|
|
67
|
-
COMPONENT_ID: number;
|
|
68
|
-
};
|
|
54
|
+
export declare const AudioSource: ComponentDefinition<PBAudioSource>;
|
|
69
55
|
|
|
70
56
|
/** @public */
|
|
71
|
-
export declare const AudioStream: ComponentDefinition<
|
|
72
|
-
|
|
73
|
-
/**
|
|
74
|
-
*
|
|
75
|
-
*/
|
|
76
|
-
export declare const AudioStreamSchema: ISchema<PBAudioStream> & {
|
|
77
|
-
COMPONENT_ID: number;
|
|
78
|
-
};
|
|
57
|
+
export declare const AudioStream: ComponentDefinition<PBAudioStream>;
|
|
79
58
|
|
|
80
59
|
export declare const enum AvatarAnchorPointType {
|
|
81
60
|
AAPT_POSITION = 0,
|
|
@@ -85,24 +64,10 @@ export declare const enum AvatarAnchorPointType {
|
|
|
85
64
|
}
|
|
86
65
|
|
|
87
66
|
/** @public */
|
|
88
|
-
export declare const AvatarAttach: ComponentDefinition<
|
|
89
|
-
|
|
90
|
-
/**
|
|
91
|
-
*
|
|
92
|
-
*/
|
|
93
|
-
export declare const AvatarAttachSchema: ISchema<PBAvatarAttach> & {
|
|
94
|
-
COMPONENT_ID: number;
|
|
95
|
-
};
|
|
67
|
+
export declare const AvatarAttach: ComponentDefinition<PBAvatarAttach>;
|
|
96
68
|
|
|
97
69
|
/** @public */
|
|
98
|
-
export declare const AvatarModifierArea: ComponentDefinition<
|
|
99
|
-
|
|
100
|
-
/**
|
|
101
|
-
*
|
|
102
|
-
*/
|
|
103
|
-
export declare const AvatarModifierAreaSchema: ISchema<PBAvatarModifierArea> & {
|
|
104
|
-
COMPONENT_ID: number;
|
|
105
|
-
};
|
|
70
|
+
export declare const AvatarModifierArea: ComponentDefinition<PBAvatarModifierArea>;
|
|
106
71
|
|
|
107
72
|
export declare const enum AvatarModifierType {
|
|
108
73
|
AMT_HIDE_AVATARS = 0,
|
|
@@ -110,14 +75,7 @@ export declare const enum AvatarModifierType {
|
|
|
110
75
|
}
|
|
111
76
|
|
|
112
77
|
/** @public */
|
|
113
|
-
export declare const AvatarShape: ComponentDefinition<
|
|
114
|
-
|
|
115
|
-
/**
|
|
116
|
-
*
|
|
117
|
-
*/
|
|
118
|
-
export declare const AvatarShapeSchema: ISchema<PBAvatarShape> & {
|
|
119
|
-
COMPONENT_ID: number;
|
|
120
|
-
};
|
|
78
|
+
export declare const AvatarShape: ComponentDefinition<PBAvatarShape>;
|
|
121
79
|
|
|
122
80
|
export declare interface AvatarTexture {
|
|
123
81
|
userId: string;
|
|
@@ -136,20 +94,13 @@ export declare const AvatarTexture: {
|
|
|
136
94
|
};
|
|
137
95
|
|
|
138
96
|
/** @public */
|
|
139
|
-
export declare const Billboard: ComponentDefinition<
|
|
97
|
+
export declare const Billboard: ComponentDefinition<PBBillboard>;
|
|
140
98
|
|
|
141
99
|
export declare const enum BillboardMode {
|
|
142
100
|
BM_ALL_AXES = 0,
|
|
143
101
|
BM_Y_AXE = 1
|
|
144
102
|
}
|
|
145
103
|
|
|
146
|
-
/**
|
|
147
|
-
*
|
|
148
|
-
*/
|
|
149
|
-
export declare const BillboardSchema: ISchema<PBBillboard> & {
|
|
150
|
-
COMPONENT_ID: number;
|
|
151
|
-
};
|
|
152
|
-
|
|
153
104
|
/**
|
|
154
105
|
* @public
|
|
155
106
|
*/
|
|
@@ -258,24 +209,10 @@ export declare type ByteBuffer = {
|
|
|
258
209
|
};
|
|
259
210
|
|
|
260
211
|
/** @public */
|
|
261
|
-
export declare const CameraMode: ComponentDefinition<
|
|
212
|
+
export declare const CameraMode: ComponentDefinition<PBCameraMode>;
|
|
262
213
|
|
|
263
214
|
/** @public */
|
|
264
|
-
export declare const CameraModeArea: ComponentDefinition<
|
|
265
|
-
|
|
266
|
-
/**
|
|
267
|
-
*
|
|
268
|
-
*/
|
|
269
|
-
export declare const CameraModeAreaSchema: ISchema<PBCameraModeArea> & {
|
|
270
|
-
COMPONENT_ID: number;
|
|
271
|
-
};
|
|
272
|
-
|
|
273
|
-
/**
|
|
274
|
-
*
|
|
275
|
-
*/
|
|
276
|
-
export declare const CameraModeSchema: ISchema<PBCameraMode> & {
|
|
277
|
-
COMPONENT_ID: number;
|
|
278
|
-
};
|
|
215
|
+
export declare const CameraModeArea: ComponentDefinition<PBCameraModeArea>;
|
|
279
216
|
|
|
280
217
|
export declare const enum CameraType {
|
|
281
218
|
CT_FIRST_PERSON = 0,
|
|
@@ -1005,12 +942,12 @@ export declare type CommonProps = {
|
|
|
1005
942
|
/**
|
|
1006
943
|
* @public
|
|
1007
944
|
*/
|
|
1008
|
-
export declare type ComponentDefinition<T
|
|
945
|
+
export declare type ComponentDefinition<T> = {
|
|
1009
946
|
_id: number;
|
|
1010
947
|
/**
|
|
1011
948
|
* Return the default value of the current component
|
|
1012
949
|
*/
|
|
1013
|
-
default(): DeepReadonly<
|
|
950
|
+
default(): DeepReadonly<T>;
|
|
1014
951
|
/**
|
|
1015
952
|
* Get if the entity has this component
|
|
1016
953
|
* @param entity - entity to test
|
|
@@ -1021,45 +958,45 @@ export declare type ComponentDefinition<T extends ISchema<ConstructorType>, Cons
|
|
|
1021
958
|
* @param entity - Entity that will be used to get the component
|
|
1022
959
|
* @returns
|
|
1023
960
|
*/
|
|
1024
|
-
get(entity: Entity): DeepReadonly<
|
|
961
|
+
get(entity: Entity): DeepReadonly<T>;
|
|
1025
962
|
/**
|
|
1026
963
|
* Get the readonly component of the entity (to mutate it, use getMutable instead), or null if the entity doesn't have the component.
|
|
1027
964
|
* @param entity - Entity that will be used to try to get the component
|
|
1028
965
|
*/
|
|
1029
|
-
getOrNull(entity: Entity): DeepReadonly<
|
|
966
|
+
getOrNull(entity: Entity): DeepReadonly<T> | null;
|
|
1030
967
|
/**
|
|
1031
968
|
* Add the current component to an entity, throw an error if the component already exists (use `createOrReplace` instead).
|
|
1032
969
|
* - Internal comment: This method adds the <entity,component> to the list to be reviewed next frame
|
|
1033
970
|
* @param entity - Entity that will be used to create the component
|
|
1034
971
|
* @param val - The initial value
|
|
1035
972
|
*/
|
|
1036
|
-
create(entity: Entity, val?:
|
|
973
|
+
create(entity: Entity, val?: T): T;
|
|
1037
974
|
/**
|
|
1038
975
|
* Add the current component to an entity or replace the content if the entity already has the component
|
|
1039
976
|
* - Internal comment: This method adds the <entity,component> to the list to be reviewed next frame
|
|
1040
977
|
* @param entity - Entity that will be used to create or replace the component
|
|
1041
978
|
* @param val - The initial or new value
|
|
1042
979
|
*/
|
|
1043
|
-
createOrReplace(entity: Entity, val?:
|
|
980
|
+
createOrReplace(entity: Entity, val?: T): T;
|
|
1044
981
|
/**
|
|
1045
982
|
* @public
|
|
1046
983
|
* Delete the current component to an entity, return null if the entity doesn't have the current component.
|
|
1047
984
|
* - Internal comment: This method adds the <entity,component> to the list to be reviewed next frame
|
|
1048
985
|
* @param entity - Entity to delete the component from
|
|
1049
986
|
*/
|
|
1050
|
-
deleteFrom(entity: Entity):
|
|
987
|
+
deleteFrom(entity: Entity): T | null;
|
|
1051
988
|
/**
|
|
1052
989
|
* Get the mutable component of the entity, throw an error if the entity doesn't have the component.
|
|
1053
990
|
* - Internal comment: This method adds the <entity,component> to the list to be reviewed next frame
|
|
1054
991
|
* @param entity - Entity to get the component from
|
|
1055
992
|
*/
|
|
1056
|
-
getMutable(entity: Entity):
|
|
993
|
+
getMutable(entity: Entity): T;
|
|
1057
994
|
/**
|
|
1058
995
|
* Get the mutable component of the entity, return null if the entity doesn't have the component.
|
|
1059
996
|
* - Internal comment: This method adds the <entity,component> to the list to be reviewed next frame
|
|
1060
997
|
* @param entity - Entity to get the component from
|
|
1061
998
|
*/
|
|
1062
|
-
getMutableOrNull(entity: Entity):
|
|
999
|
+
getMutableOrNull(entity: Entity): T | null;
|
|
1063
1000
|
writeToByteBuffer(entity: Entity, buffer: ByteBuffer): void;
|
|
1064
1001
|
};
|
|
1065
1002
|
|
|
@@ -1072,11 +1009,6 @@ export declare type ComponentSchema<T extends [ComponentDefinition<any>, ...Comp
|
|
|
1072
1009
|
[K in keyof T]: T[K] extends ComponentDefinition<any> ? ReturnType<T[K]['getMutable']> : never;
|
|
1073
1010
|
};
|
|
1074
1011
|
|
|
1075
|
-
/**
|
|
1076
|
-
* @public
|
|
1077
|
-
*/
|
|
1078
|
-
export declare type ComponentType<T extends ISchema> = EcsResult<T>;
|
|
1079
|
-
|
|
1080
1012
|
export declare function Container({ width, height, children }: ContainerPropTypes): ReactEcs.JSX.Element;
|
|
1081
1013
|
|
|
1082
1014
|
export declare type ContainerPropTypes = Partial<CommonProps> & EntityPropTypes['uiTransform'];
|
|
@@ -1166,7 +1098,7 @@ export declare type DeepReadonlyObject<T> = {
|
|
|
1166
1098
|
*/
|
|
1167
1099
|
export declare type DeepReadonlySet<T> = ReadonlySet<DeepReadonly<T>>;
|
|
1168
1100
|
|
|
1169
|
-
export declare function defineComponent<T
|
|
1101
|
+
export declare function defineComponent<T>(componentId: number, spec: ISchema<T>): ComponentDefinition<T>;
|
|
1170
1102
|
|
|
1171
1103
|
/**
|
|
1172
1104
|
* Constant used to convert from Euler degrees to radians
|
|
@@ -1178,11 +1110,6 @@ export declare type EcsElements = {
|
|
|
1178
1110
|
entity: Partial<Omit<EntityComponents, 'onClick'> & CommonProps>;
|
|
1179
1111
|
};
|
|
1180
1112
|
|
|
1181
|
-
/**
|
|
1182
|
-
* @public
|
|
1183
|
-
*/
|
|
1184
|
-
export declare type EcsResult<T extends ISchema> = T extends ISchema ? ReturnType<T['deserialize']> : never;
|
|
1185
|
-
|
|
1186
1113
|
/**
|
|
1187
1114
|
* @public
|
|
1188
1115
|
*/
|
|
@@ -1275,14 +1202,7 @@ export declare type GlobalInputEventResult = InputEventResult & {
|
|
|
1275
1202
|
};
|
|
1276
1203
|
|
|
1277
1204
|
/** @public */
|
|
1278
|
-
export declare const GltfContainer: ComponentDefinition<
|
|
1279
|
-
|
|
1280
|
-
/**
|
|
1281
|
-
*
|
|
1282
|
-
*/
|
|
1283
|
-
export declare const GltfContainerSchema: ISchema<PBGltfContainer> & {
|
|
1284
|
-
COMPONENT_ID: number;
|
|
1285
|
-
};
|
|
1205
|
+
export declare const GltfContainer: ComponentDefinition<PBGltfContainer>;
|
|
1286
1206
|
|
|
1287
1207
|
/**
|
|
1288
1208
|
* @public
|
|
@@ -1344,7 +1264,7 @@ export declare type IEngine = {
|
|
|
1344
1264
|
* @param component - The component definition
|
|
1345
1265
|
* @param componentId - unique id to identify the component, if the component id already exist, it will fail.
|
|
1346
1266
|
*/
|
|
1347
|
-
registerCustomComponent<T
|
|
1267
|
+
registerCustomComponent<T>(component: ComponentDefinition<T>, componentId: number): ComponentDefinition<T>;
|
|
1348
1268
|
/**
|
|
1349
1269
|
* Define a component and add it to the engine.
|
|
1350
1270
|
* @param spec - An object with schema fields
|
|
@@ -1361,7 +1281,7 @@ export declare type IEngine = {
|
|
|
1361
1281
|
*
|
|
1362
1282
|
* ```
|
|
1363
1283
|
*/
|
|
1364
|
-
defineComponent<T extends Spec
|
|
1284
|
+
defineComponent<T extends Spec>(spec: T, componentId: number, constructorDefault?: Partial<MapResult<T>>): MapComponentDefinition<MapResult<T>>;
|
|
1365
1285
|
/**
|
|
1366
1286
|
* Define a component and add it to the engine.
|
|
1367
1287
|
* @param spec - An object with schema fields
|
|
@@ -1373,7 +1293,7 @@ export declare type IEngine = {
|
|
|
1373
1293
|
* const StateComponent = engine.defineComponent(Schemas.Bool, VisibleComponentId)
|
|
1374
1294
|
* ```
|
|
1375
1295
|
*/
|
|
1376
|
-
defineComponentFromSchema<T
|
|
1296
|
+
defineComponentFromSchema<T>(spec: ISchema<T>, componentId: number): ComponentDefinition<T>;
|
|
1377
1297
|
/**
|
|
1378
1298
|
* Get the component definition from the component id.
|
|
1379
1299
|
* @param componentId - component number used to identify the component descriptor
|
|
@@ -1383,7 +1303,7 @@ export declare type IEngine = {
|
|
|
1383
1303
|
* const StateComponent = engine.getComponent(StateComponentId)
|
|
1384
1304
|
* ```
|
|
1385
1305
|
*/
|
|
1386
|
-
getComponent<T
|
|
1306
|
+
getComponent<T>(componentId: number): ComponentDefinition<T>;
|
|
1387
1307
|
/**
|
|
1388
1308
|
* Get the component definition from the component id.
|
|
1389
1309
|
* @param componentId - component number used to identify the component descriptor
|
|
@@ -1393,7 +1313,7 @@ export declare type IEngine = {
|
|
|
1393
1313
|
* const StateComponent = engine.getComponent(StateComponentId)
|
|
1394
1314
|
* ```
|
|
1395
1315
|
*/
|
|
1396
|
-
getComponentOrNull<T
|
|
1316
|
+
getComponentOrNull<T>(componentId: number): ComponentDefinition<T> | null;
|
|
1397
1317
|
/**
|
|
1398
1318
|
* Get a iterator of entities that has all the component requested.
|
|
1399
1319
|
* @param components - a list of component definitions
|
|
@@ -1606,7 +1526,7 @@ export declare type IInputSystem = {
|
|
|
1606
1526
|
/**
|
|
1607
1527
|
* @public
|
|
1608
1528
|
*/
|
|
1609
|
-
export declare function IMap<T extends Spec>(spec: T): ISchema<
|
|
1529
|
+
export declare function IMap<T extends Spec>(spec: T, defaultValue?: Partial<MapResult<T>>): ISchema<MapResult<T>>;
|
|
1610
1530
|
|
|
1611
1531
|
/** Include property keys from T where the property is assignable to U */
|
|
1612
1532
|
export declare type IncludeUndefined<T> = {
|
|
@@ -1658,6 +1578,7 @@ export declare type ISchema<T = any> = {
|
|
|
1658
1578
|
serialize(value: T, builder: ByteBuffer): void;
|
|
1659
1579
|
deserialize(reader: ByteBuffer): T;
|
|
1660
1580
|
create(): T;
|
|
1581
|
+
extend?: (base?: T) => T;
|
|
1661
1582
|
};
|
|
1662
1583
|
|
|
1663
1584
|
export declare const isListener: (key: string) => key is "onClick";
|
|
@@ -1676,12 +1597,36 @@ export declare type Listeners = {
|
|
|
1676
1597
|
onClick?: EventSystemCallback;
|
|
1677
1598
|
};
|
|
1678
1599
|
|
|
1600
|
+
export declare interface MapComponentDefinition<T> extends ComponentDefinition<T> {
|
|
1601
|
+
/**
|
|
1602
|
+
* Add the current component to an entity, throw an error if the component already exists (use `createOrReplace` instead).
|
|
1603
|
+
* - Internal comment: This method adds the <entity,component> to the list to be reviewed next frame
|
|
1604
|
+
* @param entity - Entity that will be used to create the component
|
|
1605
|
+
* @param val - The initial value
|
|
1606
|
+
*/
|
|
1607
|
+
create(entity: Entity, val?: Partial<T>): T;
|
|
1608
|
+
/**
|
|
1609
|
+
* Add the current component to an entity or replace the content if the entity already has the component
|
|
1610
|
+
* - Internal comment: This method adds the <entity,component> to the list to be reviewed next frame
|
|
1611
|
+
* @param entity - Entity that will be used to create or replace the component
|
|
1612
|
+
* @param val - The initial or new value
|
|
1613
|
+
*/
|
|
1614
|
+
createOrReplace(entity: Entity, val?: Partial<T>): T;
|
|
1615
|
+
}
|
|
1616
|
+
|
|
1617
|
+
/**
|
|
1618
|
+
* @public
|
|
1619
|
+
*/
|
|
1620
|
+
export declare type MapResult<T extends Spec> = ToOptional<{
|
|
1621
|
+
[K in keyof T]: T[K] extends ISchema ? ReturnType<T[K]['deserialize']> : T[K] extends Spec ? MapResult<T[K]> : never;
|
|
1622
|
+
}>;
|
|
1623
|
+
|
|
1679
1624
|
export declare const Material: MaterialComponentDefinitionExtended;
|
|
1680
1625
|
|
|
1681
1626
|
/**
|
|
1682
1627
|
* @public
|
|
1683
1628
|
*/
|
|
1684
|
-
export declare type MaterialComponentDefinition = ComponentDefinition<
|
|
1629
|
+
export declare type MaterialComponentDefinition = ComponentDefinition<PBMaterial>;
|
|
1685
1630
|
|
|
1686
1631
|
/**
|
|
1687
1632
|
* @public
|
|
@@ -1705,13 +1650,6 @@ export declare interface MaterialComponentDefinitionExtended extends MaterialCom
|
|
|
1705
1650
|
setPbrMaterial: (entity: Entity, material: PBMaterial_PbrMaterial) => void;
|
|
1706
1651
|
}
|
|
1707
1652
|
|
|
1708
|
-
/**
|
|
1709
|
-
*
|
|
1710
|
-
*/
|
|
1711
|
-
export declare const MaterialSchema: ISchema<PBMaterial> & {
|
|
1712
|
-
COMPONENT_ID: number;
|
|
1713
|
-
};
|
|
1714
|
-
|
|
1715
1653
|
export declare const enum MaterialTransparencyMode {
|
|
1716
1654
|
MTM_OPAQUE = 0,
|
|
1717
1655
|
MTM_ALPHA_TEST = 1,
|
|
@@ -2456,7 +2394,7 @@ export declare const MeshCollider: MeshColliderComponentDefinitionExtended;
|
|
|
2456
2394
|
/**
|
|
2457
2395
|
* @public
|
|
2458
2396
|
*/
|
|
2459
|
-
export declare type MeshColliderComponentDefinition = ComponentDefinition<
|
|
2397
|
+
export declare type MeshColliderComponentDefinition = ComponentDefinition<PBMeshCollider>;
|
|
2460
2398
|
|
|
2461
2399
|
/**
|
|
2462
2400
|
* @public
|
|
@@ -2494,19 +2432,12 @@ export declare interface MeshColliderComponentDefinitionExtended extends MeshCol
|
|
|
2494
2432
|
setSphere(entity: Entity, colliderLayers?: ColliderLayer | ColliderLayer[]): void;
|
|
2495
2433
|
}
|
|
2496
2434
|
|
|
2497
|
-
/**
|
|
2498
|
-
*
|
|
2499
|
-
*/
|
|
2500
|
-
export declare const MeshColliderSchema: ISchema<PBMeshCollider> & {
|
|
2501
|
-
COMPONENT_ID: number;
|
|
2502
|
-
};
|
|
2503
|
-
|
|
2504
2435
|
export declare const MeshRenderer: MeshRendererComponentDefinitionExtended;
|
|
2505
2436
|
|
|
2506
2437
|
/**
|
|
2507
2438
|
* @public
|
|
2508
2439
|
*/
|
|
2509
|
-
export declare type MeshRendererComponentDefinition = ComponentDefinition<
|
|
2440
|
+
export declare type MeshRendererComponentDefinition = ComponentDefinition<PBMeshRenderer>;
|
|
2510
2441
|
|
|
2511
2442
|
/**
|
|
2512
2443
|
* @public
|
|
@@ -2542,13 +2473,6 @@ export declare interface MeshRendererComponentDefinitionExtended extends MeshRen
|
|
|
2542
2473
|
setSphere(entity: Entity): void;
|
|
2543
2474
|
}
|
|
2544
2475
|
|
|
2545
|
-
/**
|
|
2546
|
-
*
|
|
2547
|
-
*/
|
|
2548
|
-
export declare const MeshRendererSchema: ISchema<PBMeshRenderer> & {
|
|
2549
|
-
COMPONENT_ID: number;
|
|
2550
|
-
};
|
|
2551
|
-
|
|
2552
2476
|
export declare class MessageBus {
|
|
2553
2477
|
private messageQueue;
|
|
2554
2478
|
private flushing;
|
|
@@ -2585,14 +2509,7 @@ export declare const enum NftFrameType {
|
|
|
2585
2509
|
}
|
|
2586
2510
|
|
|
2587
2511
|
/** @public */
|
|
2588
|
-
export declare const NftShape: ComponentDefinition<
|
|
2589
|
-
|
|
2590
|
-
/**
|
|
2591
|
-
*
|
|
2592
|
-
*/
|
|
2593
|
-
export declare const NftShapeSchema: ISchema<PBNftShape> & {
|
|
2594
|
-
COMPONENT_ID: number;
|
|
2595
|
-
};
|
|
2512
|
+
export declare const NftShape: ComponentDefinition<PBNftShape>;
|
|
2596
2513
|
|
|
2597
2514
|
export declare class Observable<T> {
|
|
2598
2515
|
private _observers;
|
|
@@ -3619,14 +3536,7 @@ export declare namespace Plane {
|
|
|
3619
3536
|
}
|
|
3620
3537
|
|
|
3621
3538
|
/** @public */
|
|
3622
|
-
export declare const PointerEventsResult: ComponentDefinition<
|
|
3623
|
-
|
|
3624
|
-
/**
|
|
3625
|
-
*
|
|
3626
|
-
*/
|
|
3627
|
-
export declare const PointerEventsResultSchema: ISchema<PBPointerEventsResult> & {
|
|
3628
|
-
COMPONENT_ID: number;
|
|
3629
|
-
};
|
|
3539
|
+
export declare const PointerEventsResult: ComponentDefinition<PBPointerEventsResult>;
|
|
3630
3540
|
|
|
3631
3541
|
export declare type PointerEventsSystem = ReturnType<typeof createPointerEventSystem>;
|
|
3632
3542
|
|
|
@@ -3647,24 +3557,10 @@ export declare const enum PointerEventType {
|
|
|
3647
3557
|
}
|
|
3648
3558
|
|
|
3649
3559
|
/** @public */
|
|
3650
|
-
export declare const PointerHoverFeedback: ComponentDefinition<
|
|
3651
|
-
|
|
3652
|
-
/**
|
|
3653
|
-
*
|
|
3654
|
-
*/
|
|
3655
|
-
export declare const PointerHoverFeedbackSchema: ISchema<PBPointerHoverFeedback> & {
|
|
3656
|
-
COMPONENT_ID: number;
|
|
3657
|
-
};
|
|
3560
|
+
export declare const PointerHoverFeedback: ComponentDefinition<PBPointerHoverFeedback>;
|
|
3658
3561
|
|
|
3659
3562
|
/** @public */
|
|
3660
|
-
export declare const PointerLock: ComponentDefinition<
|
|
3661
|
-
|
|
3662
|
-
/**
|
|
3663
|
-
*
|
|
3664
|
-
*/
|
|
3665
|
-
export declare const PointerLockSchema: ISchema<PBPointerLock> & {
|
|
3666
|
-
COMPONENT_ID: number;
|
|
3667
|
-
};
|
|
3563
|
+
export declare const PointerLock: ComponentDefinition<PBPointerLock>;
|
|
3668
3564
|
|
|
3669
3565
|
/**
|
|
3670
3566
|
* @public
|
|
@@ -3942,7 +3838,7 @@ export declare type QuaternionType = {
|
|
|
3942
3838
|
export declare const RAD2DEG: number;
|
|
3943
3839
|
|
|
3944
3840
|
/** @public */
|
|
3945
|
-
export declare const Raycast: ComponentDefinition<
|
|
3841
|
+
export declare const Raycast: ComponentDefinition<PBRaycast>;
|
|
3946
3842
|
|
|
3947
3843
|
/** Position will be relative to the scene */
|
|
3948
3844
|
export declare interface RaycastHit {
|
|
@@ -3975,21 +3871,7 @@ export declare type RaycastResponsePayload<T> = {
|
|
|
3975
3871
|
};
|
|
3976
3872
|
|
|
3977
3873
|
/** @public */
|
|
3978
|
-
export declare const RaycastResult: ComponentDefinition<
|
|
3979
|
-
|
|
3980
|
-
/**
|
|
3981
|
-
*
|
|
3982
|
-
*/
|
|
3983
|
-
export declare const RaycastResultSchema: ISchema<PBRaycastResult> & {
|
|
3984
|
-
COMPONENT_ID: number;
|
|
3985
|
-
};
|
|
3986
|
-
|
|
3987
|
-
/**
|
|
3988
|
-
*
|
|
3989
|
-
*/
|
|
3990
|
-
export declare const RaycastSchema: ISchema<PBRaycast> & {
|
|
3991
|
-
COMPONENT_ID: number;
|
|
3992
|
-
};
|
|
3874
|
+
export declare const RaycastResult: ComponentDefinition<PBRaycastResult>;
|
|
3993
3875
|
|
|
3994
3876
|
export declare type ReactBasedUiSystem = {
|
|
3995
3877
|
destroy(): void;
|
|
@@ -4012,8 +3894,8 @@ export declare const ReactEcsRenderer: ReactBasedUiSystem;
|
|
|
4012
3894
|
/**
|
|
4013
3895
|
* @public
|
|
4014
3896
|
*/
|
|
4015
|
-
export declare type ReadonlyComponentSchema<T extends [ComponentDefinition<
|
|
4016
|
-
[K in keyof T]: T[K] extends ComponentDefinition<
|
|
3897
|
+
export declare type ReadonlyComponentSchema<T extends [ComponentDefinition<unknown>, ...ComponentDefinition<unknown>[]]> = {
|
|
3898
|
+
[K in keyof T]: T[K] extends ComponentDefinition<unknown> ? ReturnType<T[K]['get']> : never;
|
|
4017
3899
|
};
|
|
4018
3900
|
|
|
4019
3901
|
/**
|
|
@@ -4031,13 +3913,6 @@ export declare type ReceiveMessage = {
|
|
|
4031
3913
|
messageBuffer: Uint8Array;
|
|
4032
3914
|
};
|
|
4033
3915
|
|
|
4034
|
-
/**
|
|
4035
|
-
* @public
|
|
4036
|
-
*/
|
|
4037
|
-
export declare type Result<T extends Spec> = ToOptional<{
|
|
4038
|
-
[K in keyof T]: T[K] extends ISchema ? ReturnType<T[K]['deserialize']> : T[K] extends Spec ? Result<T[K]> : never;
|
|
4039
|
-
}>;
|
|
4040
|
-
|
|
4041
3916
|
export declare type RPCSendableMessage = {
|
|
4042
3917
|
jsonrpc: '2.0';
|
|
4043
3918
|
id: number;
|
|
@@ -4274,6 +4149,12 @@ export declare interface Spec {
|
|
|
4274
4149
|
*/
|
|
4275
4150
|
export declare type SystemFn = (dt: number) => void;
|
|
4276
4151
|
|
|
4152
|
+
export declare type SystemItem = {
|
|
4153
|
+
fn: SystemFn;
|
|
4154
|
+
priority: number;
|
|
4155
|
+
name?: string;
|
|
4156
|
+
};
|
|
4157
|
+
|
|
4277
4158
|
export declare type Task<T = unknown> = () => Promise<T>;
|
|
4278
4159
|
|
|
4279
4160
|
export declare const enum TextAlignMode {
|
|
@@ -4289,14 +4170,7 @@ export declare const enum TextAlignMode {
|
|
|
4289
4170
|
}
|
|
4290
4171
|
|
|
4291
4172
|
/** @public */
|
|
4292
|
-
export declare const TextShape: ComponentDefinition<
|
|
4293
|
-
|
|
4294
|
-
/**
|
|
4295
|
-
*
|
|
4296
|
-
*/
|
|
4297
|
-
export declare const TextShapeSchema: ISchema<PBTextShape> & {
|
|
4298
|
-
COMPONENT_ID: number;
|
|
4299
|
-
};
|
|
4173
|
+
export declare const TextShape: ComponentDefinition<PBTextShape>;
|
|
4300
4174
|
|
|
4301
4175
|
export declare interface Texture {
|
|
4302
4176
|
src: string;
|
|
@@ -4373,9 +4247,20 @@ export declare const ToLinearSpace = 2.2;
|
|
|
4373
4247
|
|
|
4374
4248
|
export declare type ToOptional<T> = OnlyOptionalUndefinedTypes<T> & OnlyNonUndefinedTypes<T>;
|
|
4375
4249
|
|
|
4376
|
-
export declare const Transform:
|
|
4250
|
+
export declare const Transform: TransformComponentExtended;
|
|
4377
4251
|
|
|
4378
|
-
|
|
4252
|
+
/**
|
|
4253
|
+
* @public
|
|
4254
|
+
*/
|
|
4255
|
+
export declare type TransformComponent = ComponentDefinition<TransformType>;
|
|
4256
|
+
|
|
4257
|
+
/**
|
|
4258
|
+
* @public
|
|
4259
|
+
*/
|
|
4260
|
+
export declare interface TransformComponentExtended extends TransformComponent {
|
|
4261
|
+
create(entity: Entity, val?: TransformTypeWithOptionals): TransformType;
|
|
4262
|
+
createOrReplace(entity: Entity, val?: TransformTypeWithOptionals): TransformType;
|
|
4263
|
+
}
|
|
4379
4264
|
|
|
4380
4265
|
/**
|
|
4381
4266
|
* @public
|
|
@@ -4400,6 +4285,11 @@ export declare type TransformType = {
|
|
|
4400
4285
|
parent?: Entity;
|
|
4401
4286
|
};
|
|
4402
4287
|
|
|
4288
|
+
/**
|
|
4289
|
+
* @public
|
|
4290
|
+
*/
|
|
4291
|
+
export declare type TransformTypeWithOptionals = Partial<TransformType>;
|
|
4292
|
+
|
|
4403
4293
|
export declare type Transport = {
|
|
4404
4294
|
send(message: Uint8Array): Promise<void>;
|
|
4405
4295
|
onmessage?(message: Uint8Array): void;
|
|
@@ -4409,14 +4299,7 @@ export declare type Transport = {
|
|
|
4409
4299
|
export declare type TransportMessage = Omit<ReceiveMessage, 'data'>;
|
|
4410
4300
|
|
|
4411
4301
|
/** @public */
|
|
4412
|
-
export declare const UiBackground: ComponentDefinition<
|
|
4413
|
-
|
|
4414
|
-
/**
|
|
4415
|
-
*
|
|
4416
|
-
*/
|
|
4417
|
-
export declare const UiBackgroundSchema: ISchema<PBUiBackground> & {
|
|
4418
|
-
COMPONENT_ID: number;
|
|
4419
|
-
};
|
|
4302
|
+
export declare const UiBackground: ComponentDefinition<PBUiBackground>;
|
|
4420
4303
|
|
|
4421
4304
|
export declare type UiComponent = () => JSX.Element;
|
|
4422
4305
|
|
|
@@ -4426,17 +4309,10 @@ export declare type UiComponent = () => JSX.Element;
|
|
|
4426
4309
|
export declare function UiEntity(props: EntityPropTypes & Partial<CommonProps>): ReactEcs.JSX.Element;
|
|
4427
4310
|
|
|
4428
4311
|
/** @public */
|
|
4429
|
-
export declare const UiText: ComponentDefinition<
|
|
4430
|
-
|
|
4431
|
-
/**
|
|
4432
|
-
*
|
|
4433
|
-
*/
|
|
4434
|
-
export declare const UiTextSchema: ISchema<PBUiText> & {
|
|
4435
|
-
COMPONENT_ID: number;
|
|
4436
|
-
};
|
|
4312
|
+
export declare const UiText: ComponentDefinition<PBUiText>;
|
|
4437
4313
|
|
|
4438
4314
|
/** @public */
|
|
4439
|
-
export declare const UiTransform: ComponentDefinition<
|
|
4315
|
+
export declare const UiTransform: ComponentDefinition<PBUiTransform>;
|
|
4440
4316
|
|
|
4441
4317
|
/**
|
|
4442
4318
|
* @public
|
|
@@ -4466,13 +4342,6 @@ export declare interface UiTransformProps {
|
|
|
4466
4342
|
overflow?: YGOverflow;
|
|
4467
4343
|
}
|
|
4468
4344
|
|
|
4469
|
-
/**
|
|
4470
|
-
*
|
|
4471
|
-
*/
|
|
4472
|
-
export declare const UiTransformSchema: ISchema<PBUiTransform> & {
|
|
4473
|
-
COMPONENT_ID: number;
|
|
4474
|
-
};
|
|
4475
|
-
|
|
4476
4345
|
/**
|
|
4477
4346
|
* @public
|
|
4478
4347
|
*/
|
|
@@ -5082,14 +4951,7 @@ export declare type Vector3Type = {
|
|
|
5082
4951
|
};
|
|
5083
4952
|
|
|
5084
4953
|
/** @public */
|
|
5085
|
-
export declare const VisibilityComponent: ComponentDefinition<
|
|
5086
|
-
|
|
5087
|
-
/**
|
|
5088
|
-
*
|
|
5089
|
-
*/
|
|
5090
|
-
export declare const VisibilityComponentSchema: ISchema<PBVisibilityComponent> & {
|
|
5091
|
-
COMPONENT_ID: number;
|
|
5092
|
-
};
|
|
4954
|
+
export declare const VisibilityComponent: ComponentDefinition<PBVisibilityComponent>;
|
|
5093
4955
|
|
|
5094
4956
|
export declare namespace WireMessage {
|
|
5095
4957
|
export type Uint32 = number;
|
|
@@ -5114,7 +4976,7 @@ export declare namespace WireMessage {
|
|
|
5114
4976
|
*/
|
|
5115
4977
|
export function validate(buf: ByteBuffer): boolean;
|
|
5116
4978
|
export function readHeader(buf: ByteBuffer): Header | null;
|
|
5117
|
-
export function getType(component: ComponentDefinition<
|
|
4979
|
+
export function getType(component: ComponentDefinition<unknown>, entity: Entity): Enum;
|
|
5118
4980
|
}
|
|
5119
4981
|
|
|
5120
4982
|
export declare const enum YGAlign {
|