@dcl/playground-assets 7.1.8 → 7.1.9-4789623295.commit-8cfb6bb
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 +32 -5
- package/dist/beta.d.ts +32 -5
- package/dist/index.bundled.d.ts +32 -5
- package/dist/index.js +5 -5
- package/dist/index.js.map +4 -4
- package/dist/playground/sdk/dcl-sdk.package.json +2 -2
- package/dist/playground-assets.d.ts +32 -5
- package/etc/playground-assets.api.json +183 -46
- package/etc/playground-assets.api.md +8 -1
- package/package.json +4 -4
package/dist/alpha.d.ts
CHANGED
|
@@ -1645,6 +1645,30 @@ export declare const enum Font {
|
|
|
1645
1645
|
F_MONOSPACE = 2
|
|
1646
1646
|
}
|
|
1647
1647
|
|
|
1648
|
+
/**
|
|
1649
|
+
* Get an iterator of entities that follow a tree structure for a component
|
|
1650
|
+
* @public
|
|
1651
|
+
* @param engine - the engine running the entities
|
|
1652
|
+
* @param entity - the root entity of the tree
|
|
1653
|
+
* @param component - the parenting component to filter by
|
|
1654
|
+
* @returns An iterator of an array as [entity, entity2, ...]
|
|
1655
|
+
*
|
|
1656
|
+
* Example:
|
|
1657
|
+
* ```ts
|
|
1658
|
+
* const TreeComponent = engine.defineComponent('custom::TreeComponent', {
|
|
1659
|
+
* label: Schemas.String,
|
|
1660
|
+
* parent: Schemas.Entity
|
|
1661
|
+
* })
|
|
1662
|
+
*
|
|
1663
|
+
* for (const entity of getComponentEntityTree(engine, entity, TreeComponent)) {
|
|
1664
|
+
* // entity in the tree
|
|
1665
|
+
* }
|
|
1666
|
+
* ```
|
|
1667
|
+
*/
|
|
1668
|
+
export declare function getComponentEntityTree<T>(engine: IEngine, entity: Entity, component: ComponentDefinition<T & {
|
|
1669
|
+
parent?: Entity;
|
|
1670
|
+
}>): Generator<Entity>;
|
|
1671
|
+
|
|
1648
1672
|
/**
|
|
1649
1673
|
* @public
|
|
1650
1674
|
* @deprecated composite is not being supported so far, please do not use this feature
|
|
@@ -1726,11 +1750,6 @@ export declare interface IEngine {
|
|
|
1726
1750
|
* @param entity - entity
|
|
1727
1751
|
*/
|
|
1728
1752
|
removeEntity(entity: Entity): void;
|
|
1729
|
-
/**
|
|
1730
|
-
* Remove all components of each entity in the tree made with Transform parenting
|
|
1731
|
-
* @param firstEntity - the root entity of the tree
|
|
1732
|
-
*/
|
|
1733
|
-
removeEntityWithChildren(firstEntity: Entity): void;
|
|
1734
1753
|
/**
|
|
1735
1754
|
*
|
|
1736
1755
|
* @public
|
|
@@ -4994,6 +5013,14 @@ export declare interface Rect {
|
|
|
4994
5013
|
height: number;
|
|
4995
5014
|
}
|
|
4996
5015
|
|
|
5016
|
+
/**
|
|
5017
|
+
* Remove all components of each entity in the tree made with Transform parenting
|
|
5018
|
+
* @param engine - the engine running the entities
|
|
5019
|
+
* @param firstEntity - the root entity of the tree
|
|
5020
|
+
* @public
|
|
5021
|
+
*/
|
|
5022
|
+
export declare function removeEntityWithChildren(engine: IEngine, entity: Entity): void;
|
|
5023
|
+
|
|
4997
5024
|
export declare type RPCSendableMessage = {
|
|
4998
5025
|
jsonrpc: '2.0';
|
|
4999
5026
|
id: number;
|
package/dist/beta.d.ts
CHANGED
|
@@ -1645,6 +1645,30 @@ export declare const enum Font {
|
|
|
1645
1645
|
F_MONOSPACE = 2
|
|
1646
1646
|
}
|
|
1647
1647
|
|
|
1648
|
+
/**
|
|
1649
|
+
* Get an iterator of entities that follow a tree structure for a component
|
|
1650
|
+
* @public
|
|
1651
|
+
* @param engine - the engine running the entities
|
|
1652
|
+
* @param entity - the root entity of the tree
|
|
1653
|
+
* @param component - the parenting component to filter by
|
|
1654
|
+
* @returns An iterator of an array as [entity, entity2, ...]
|
|
1655
|
+
*
|
|
1656
|
+
* Example:
|
|
1657
|
+
* ```ts
|
|
1658
|
+
* const TreeComponent = engine.defineComponent('custom::TreeComponent', {
|
|
1659
|
+
* label: Schemas.String,
|
|
1660
|
+
* parent: Schemas.Entity
|
|
1661
|
+
* })
|
|
1662
|
+
*
|
|
1663
|
+
* for (const entity of getComponentEntityTree(engine, entity, TreeComponent)) {
|
|
1664
|
+
* // entity in the tree
|
|
1665
|
+
* }
|
|
1666
|
+
* ```
|
|
1667
|
+
*/
|
|
1668
|
+
export declare function getComponentEntityTree<T>(engine: IEngine, entity: Entity, component: ComponentDefinition<T & {
|
|
1669
|
+
parent?: Entity;
|
|
1670
|
+
}>): Generator<Entity>;
|
|
1671
|
+
|
|
1648
1672
|
/**
|
|
1649
1673
|
* @public
|
|
1650
1674
|
* @deprecated composite is not being supported so far, please do not use this feature
|
|
@@ -1726,11 +1750,6 @@ export declare interface IEngine {
|
|
|
1726
1750
|
* @param entity - entity
|
|
1727
1751
|
*/
|
|
1728
1752
|
removeEntity(entity: Entity): void;
|
|
1729
|
-
/**
|
|
1730
|
-
* Remove all components of each entity in the tree made with Transform parenting
|
|
1731
|
-
* @param firstEntity - the root entity of the tree
|
|
1732
|
-
*/
|
|
1733
|
-
removeEntityWithChildren(firstEntity: Entity): void;
|
|
1734
1753
|
/**
|
|
1735
1754
|
*
|
|
1736
1755
|
* @public
|
|
@@ -4990,6 +5009,14 @@ export declare interface Rect {
|
|
|
4990
5009
|
height: number;
|
|
4991
5010
|
}
|
|
4992
5011
|
|
|
5012
|
+
/**
|
|
5013
|
+
* Remove all components of each entity in the tree made with Transform parenting
|
|
5014
|
+
* @param engine - the engine running the entities
|
|
5015
|
+
* @param firstEntity - the root entity of the tree
|
|
5016
|
+
* @public
|
|
5017
|
+
*/
|
|
5018
|
+
export declare function removeEntityWithChildren(engine: IEngine, entity: Entity): void;
|
|
5019
|
+
|
|
4993
5020
|
export declare type RPCSendableMessage = {
|
|
4994
5021
|
jsonrpc: '2.0';
|
|
4995
5022
|
id: number;
|
package/dist/index.bundled.d.ts
CHANGED
|
@@ -1645,6 +1645,30 @@ export declare const enum Font {
|
|
|
1645
1645
|
F_MONOSPACE = 2
|
|
1646
1646
|
}
|
|
1647
1647
|
|
|
1648
|
+
/**
|
|
1649
|
+
* Get an iterator of entities that follow a tree structure for a component
|
|
1650
|
+
* @public
|
|
1651
|
+
* @param engine - the engine running the entities
|
|
1652
|
+
* @param entity - the root entity of the tree
|
|
1653
|
+
* @param component - the parenting component to filter by
|
|
1654
|
+
* @returns An iterator of an array as [entity, entity2, ...]
|
|
1655
|
+
*
|
|
1656
|
+
* Example:
|
|
1657
|
+
* ```ts
|
|
1658
|
+
* const TreeComponent = engine.defineComponent('custom::TreeComponent', {
|
|
1659
|
+
* label: Schemas.String,
|
|
1660
|
+
* parent: Schemas.Entity
|
|
1661
|
+
* })
|
|
1662
|
+
*
|
|
1663
|
+
* for (const entity of getComponentEntityTree(engine, entity, TreeComponent)) {
|
|
1664
|
+
* // entity in the tree
|
|
1665
|
+
* }
|
|
1666
|
+
* ```
|
|
1667
|
+
*/
|
|
1668
|
+
export declare function getComponentEntityTree<T>(engine: IEngine, entity: Entity, component: ComponentDefinition<T & {
|
|
1669
|
+
parent?: Entity;
|
|
1670
|
+
}>): Generator<Entity>;
|
|
1671
|
+
|
|
1648
1672
|
/**
|
|
1649
1673
|
* @public
|
|
1650
1674
|
* @deprecated composite is not being supported so far, please do not use this feature
|
|
@@ -1726,11 +1750,6 @@ export declare interface IEngine {
|
|
|
1726
1750
|
* @param entity - entity
|
|
1727
1751
|
*/
|
|
1728
1752
|
removeEntity(entity: Entity): void;
|
|
1729
|
-
/**
|
|
1730
|
-
* Remove all components of each entity in the tree made with Transform parenting
|
|
1731
|
-
* @param firstEntity - the root entity of the tree
|
|
1732
|
-
*/
|
|
1733
|
-
removeEntityWithChildren(firstEntity: Entity): void;
|
|
1734
1753
|
/**
|
|
1735
1754
|
*
|
|
1736
1755
|
* @public
|
|
@@ -4990,6 +5009,14 @@ export declare interface Rect {
|
|
|
4990
5009
|
height: number;
|
|
4991
5010
|
}
|
|
4992
5011
|
|
|
5012
|
+
/**
|
|
5013
|
+
* Remove all components of each entity in the tree made with Transform parenting
|
|
5014
|
+
* @param engine - the engine running the entities
|
|
5015
|
+
* @param firstEntity - the root entity of the tree
|
|
5016
|
+
* @public
|
|
5017
|
+
*/
|
|
5018
|
+
export declare function removeEntityWithChildren(engine: IEngine, entity: Entity): void;
|
|
5019
|
+
|
|
4993
5020
|
export declare type RPCSendableMessage = {
|
|
4994
5021
|
jsonrpc: '2.0';
|
|
4995
5022
|
id: number;
|