hytopia 0.6.7 → 0.6.8
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/bun-server.mjs +71 -71
- package/docs/server.entity.md +35 -0
- package/docs/server.entity.modeltextureuri.md +13 -0
- package/docs/server.entity.setmodeltextureuri.md +53 -0
- package/docs/server.entityevent.md +14 -0
- package/docs/server.entityeventpayloads._entity.set_model_texture_uri_.md +16 -0
- package/docs/server.entityeventpayloads.md +19 -0
- package/docs/server.modelentityoptions.md +19 -0
- package/docs/server.modelentityoptions.modeltextureuri.md +13 -0
- package/node-server.mjs +67 -67
- package/package.json +1 -1
- package/server.api.json +171 -0
- package/server.d.ts +22 -5
package/package.json
CHANGED
package/server.api.json
CHANGED
@@ -13661,6 +13661,36 @@
|
|
13661
13661
|
"isProtected": false,
|
13662
13662
|
"isAbstract": false
|
13663
13663
|
},
|
13664
|
+
{
|
13665
|
+
"kind": "Property",
|
13666
|
+
"canonicalReference": "server!Entity#modelTextureUri:member",
|
13667
|
+
"docComment": "/**\n * The URI or path to the texture that overrides the model entity's default texture.\n */\n",
|
13668
|
+
"excerptTokens": [
|
13669
|
+
{
|
13670
|
+
"kind": "Content",
|
13671
|
+
"text": "get modelTextureUri(): "
|
13672
|
+
},
|
13673
|
+
{
|
13674
|
+
"kind": "Content",
|
13675
|
+
"text": "string | undefined"
|
13676
|
+
},
|
13677
|
+
{
|
13678
|
+
"kind": "Content",
|
13679
|
+
"text": ";"
|
13680
|
+
}
|
13681
|
+
],
|
13682
|
+
"isReadonly": true,
|
13683
|
+
"isOptional": false,
|
13684
|
+
"releaseTag": "Public",
|
13685
|
+
"name": "modelTextureUri",
|
13686
|
+
"propertyTypeTokenRange": {
|
13687
|
+
"startIndex": 1,
|
13688
|
+
"endIndex": 2
|
13689
|
+
},
|
13690
|
+
"isStatic": false,
|
13691
|
+
"isProtected": false,
|
13692
|
+
"isAbstract": false
|
13693
|
+
},
|
13664
13694
|
{
|
13665
13695
|
"kind": "Property",
|
13666
13696
|
"canonicalReference": "server!Entity#modelUri:member",
|
@@ -13965,6 +13995,54 @@
|
|
13965
13995
|
"isAbstract": false,
|
13966
13996
|
"name": "setModelHiddenNodes"
|
13967
13997
|
},
|
13998
|
+
{
|
13999
|
+
"kind": "Method",
|
14000
|
+
"canonicalReference": "server!Entity#setModelTextureUri:member(1)",
|
14001
|
+
"docComment": "/**\n * Sets the texture uri of the entity's model. Setting this overrides the model's default texture.\n *\n * @param modelTextureUri - The texture uri of the entity's model.\n */\n",
|
14002
|
+
"excerptTokens": [
|
14003
|
+
{
|
14004
|
+
"kind": "Content",
|
14005
|
+
"text": "setModelTextureUri(modelTextureUri: "
|
14006
|
+
},
|
14007
|
+
{
|
14008
|
+
"kind": "Content",
|
14009
|
+
"text": "string | undefined"
|
14010
|
+
},
|
14011
|
+
{
|
14012
|
+
"kind": "Content",
|
14013
|
+
"text": "): "
|
14014
|
+
},
|
14015
|
+
{
|
14016
|
+
"kind": "Content",
|
14017
|
+
"text": "void"
|
14018
|
+
},
|
14019
|
+
{
|
14020
|
+
"kind": "Content",
|
14021
|
+
"text": ";"
|
14022
|
+
}
|
14023
|
+
],
|
14024
|
+
"isStatic": false,
|
14025
|
+
"returnTypeTokenRange": {
|
14026
|
+
"startIndex": 3,
|
14027
|
+
"endIndex": 4
|
14028
|
+
},
|
14029
|
+
"releaseTag": "Public",
|
14030
|
+
"isProtected": false,
|
14031
|
+
"overloadIndex": 1,
|
14032
|
+
"parameters": [
|
14033
|
+
{
|
14034
|
+
"parameterName": "modelTextureUri",
|
14035
|
+
"parameterTypeTokenRange": {
|
14036
|
+
"startIndex": 1,
|
14037
|
+
"endIndex": 2
|
14038
|
+
},
|
14039
|
+
"isOptional": false
|
14040
|
+
}
|
14041
|
+
],
|
14042
|
+
"isOptional": false,
|
14043
|
+
"isAbstract": false,
|
14044
|
+
"name": "setModelTextureUri"
|
14045
|
+
},
|
13968
14046
|
{
|
13969
14047
|
"kind": "Method",
|
13970
14048
|
"canonicalReference": "server!Entity#setOpacity:member(1)",
|
@@ -14814,6 +14892,27 @@
|
|
14814
14892
|
"releaseTag": "Public",
|
14815
14893
|
"name": "SET_MODEL_HIDDEN_NODES"
|
14816
14894
|
},
|
14895
|
+
{
|
14896
|
+
"kind": "EnumMember",
|
14897
|
+
"canonicalReference": "server!EntityEvent.SET_MODEL_TEXTURE_URI:member",
|
14898
|
+
"docComment": "",
|
14899
|
+
"excerptTokens": [
|
14900
|
+
{
|
14901
|
+
"kind": "Content",
|
14902
|
+
"text": "SET_MODEL_TEXTURE_URI = "
|
14903
|
+
},
|
14904
|
+
{
|
14905
|
+
"kind": "Content",
|
14906
|
+
"text": "\"ENTITY.SET_MODEL_TEXTURE_URI\""
|
14907
|
+
}
|
14908
|
+
],
|
14909
|
+
"initializerTokenRange": {
|
14910
|
+
"startIndex": 1,
|
14911
|
+
"endIndex": 2
|
14912
|
+
},
|
14913
|
+
"releaseTag": "Public",
|
14914
|
+
"name": "SET_MODEL_TEXTURE_URI"
|
14915
|
+
},
|
14817
14916
|
{
|
14818
14917
|
"kind": "EnumMember",
|
14819
14918
|
"canonicalReference": "server!EntityEvent.SET_OPACITY:member",
|
@@ -15419,6 +15518,51 @@
|
|
15419
15518
|
"endIndex": 8
|
15420
15519
|
}
|
15421
15520
|
},
|
15521
|
+
{
|
15522
|
+
"kind": "PropertySignature",
|
15523
|
+
"canonicalReference": "server!EntityEventPayloads#\"ENTITY.SET_MODEL_TEXTURE_URI\":member",
|
15524
|
+
"docComment": "/**\n * Emitted when the texture uri of the entity's model is set.\n */\n",
|
15525
|
+
"excerptTokens": [
|
15526
|
+
{
|
15527
|
+
"kind": "Content",
|
15528
|
+
"text": "["
|
15529
|
+
},
|
15530
|
+
{
|
15531
|
+
"kind": "Reference",
|
15532
|
+
"text": "EntityEvent.SET_MODEL_TEXTURE_URI",
|
15533
|
+
"canonicalReference": "server!EntityEvent.SET_MODEL_TEXTURE_URI:member"
|
15534
|
+
},
|
15535
|
+
{
|
15536
|
+
"kind": "Content",
|
15537
|
+
"text": "]: "
|
15538
|
+
},
|
15539
|
+
{
|
15540
|
+
"kind": "Content",
|
15541
|
+
"text": "{\n entity: "
|
15542
|
+
},
|
15543
|
+
{
|
15544
|
+
"kind": "Reference",
|
15545
|
+
"text": "Entity",
|
15546
|
+
"canonicalReference": "server!Entity:class"
|
15547
|
+
},
|
15548
|
+
{
|
15549
|
+
"kind": "Content",
|
15550
|
+
"text": ";\n modelTextureUri: string | undefined;\n }"
|
15551
|
+
},
|
15552
|
+
{
|
15553
|
+
"kind": "Content",
|
15554
|
+
"text": ";"
|
15555
|
+
}
|
15556
|
+
],
|
15557
|
+
"isReadonly": false,
|
15558
|
+
"isOptional": false,
|
15559
|
+
"releaseTag": "Public",
|
15560
|
+
"name": "\"ENTITY.SET_MODEL_TEXTURE_URI\"",
|
15561
|
+
"propertyTypeTokenRange": {
|
15562
|
+
"startIndex": 3,
|
15563
|
+
"endIndex": 6
|
15564
|
+
}
|
15565
|
+
},
|
15422
15566
|
{
|
15423
15567
|
"kind": "PropertySignature",
|
15424
15568
|
"canonicalReference": "server!EntityEventPayloads#\"ENTITY.SET_OPACITY\":member",
|
@@ -25639,6 +25783,33 @@
|
|
25639
25783
|
"endIndex": 2
|
25640
25784
|
}
|
25641
25785
|
},
|
25786
|
+
{
|
25787
|
+
"kind": "PropertySignature",
|
25788
|
+
"canonicalReference": "server!ModelEntityOptions#modelTextureUri:member",
|
25789
|
+
"docComment": "/**\n * The texture uri of the entity's model. Setting this overrides the model's default texture.\n */\n",
|
25790
|
+
"excerptTokens": [
|
25791
|
+
{
|
25792
|
+
"kind": "Content",
|
25793
|
+
"text": "modelTextureUri?: "
|
25794
|
+
},
|
25795
|
+
{
|
25796
|
+
"kind": "Content",
|
25797
|
+
"text": "string"
|
25798
|
+
},
|
25799
|
+
{
|
25800
|
+
"kind": "Content",
|
25801
|
+
"text": ";"
|
25802
|
+
}
|
25803
|
+
],
|
25804
|
+
"isReadonly": false,
|
25805
|
+
"isOptional": true,
|
25806
|
+
"releaseTag": "Public",
|
25807
|
+
"name": "modelTextureUri",
|
25808
|
+
"propertyTypeTokenRange": {
|
25809
|
+
"startIndex": 1,
|
25810
|
+
"endIndex": 2
|
25811
|
+
}
|
25812
|
+
},
|
25642
25813
|
{
|
25643
25814
|
"kind": "PropertySignature",
|
25644
25815
|
"canonicalReference": "server!ModelEntityOptions#modelUri:member",
|
package/server.d.ts
CHANGED
@@ -1749,6 +1749,7 @@ export declare class Entity extends RigidBody implements protocol.Serializable {
|
|
1749
1749
|
|
1750
1750
|
|
1751
1751
|
|
1752
|
+
|
1752
1753
|
|
1753
1754
|
|
1754
1755
|
/**
|
@@ -1775,6 +1776,8 @@ export declare class Entity extends RigidBody implements protocol.Serializable {
|
|
1775
1776
|
get modelPreferredShape(): ColliderShape | undefined;
|
1776
1777
|
/** The scale of the entity's model. */
|
1777
1778
|
get modelScale(): number;
|
1779
|
+
/** The URI or path to the texture that overrides the model entity's default texture. */
|
1780
|
+
get modelTextureUri(): string | undefined;
|
1778
1781
|
/** The URI or path to the .gltf model asset to be used for the entity. */
|
1779
1782
|
get modelUri(): string | undefined;
|
1780
1783
|
/** The name of the entity. */
|
@@ -1808,6 +1811,11 @@ export declare class Entity extends RigidBody implements protocol.Serializable {
|
|
1808
1811
|
* Despawns the entity and all children from the world.
|
1809
1812
|
*/
|
1810
1813
|
despawn(): void;
|
1814
|
+
/**
|
1815
|
+
* Sets the controller for the entity.
|
1816
|
+
* @param controller - The controller to set.
|
1817
|
+
*/
|
1818
|
+
setController(controller: BaseEntityController | undefined): void;
|
1811
1819
|
/**
|
1812
1820
|
* Sets the playback rate of all animations on the entity's model.
|
1813
1821
|
*
|
@@ -1819,11 +1827,6 @@ export declare class Entity extends RigidBody implements protocol.Serializable {
|
|
1819
1827
|
* @param playbackRate - The playback rate of the entity's model animations.
|
1820
1828
|
*/
|
1821
1829
|
setModelAnimationsPlaybackRate(playbackRate: number): void;
|
1822
|
-
/**
|
1823
|
-
* Sets the controller for the entity.
|
1824
|
-
* @param controller - The controller to set.
|
1825
|
-
*/
|
1826
|
-
setController(controller: BaseEntityController | undefined): void;
|
1827
1830
|
/**
|
1828
1831
|
* Sets the nodes to hide on the entity's model. Matched nodes
|
1829
1832
|
* will be hidden for all players. Uses case insensitive
|
@@ -1831,6 +1834,12 @@ export declare class Entity extends RigidBody implements protocol.Serializable {
|
|
1831
1834
|
* @param modelHiddenNodes - The nodes to hide on the entity's model.
|
1832
1835
|
*/
|
1833
1836
|
setModelHiddenNodes(modelHiddenNodes: string[]): void;
|
1837
|
+
/**
|
1838
|
+
* Sets the texture uri of the entity's model. Setting
|
1839
|
+
* this overrides the model's default texture.
|
1840
|
+
* @param modelTextureUri - The texture uri of the entity's model.
|
1841
|
+
*/
|
1842
|
+
setModelTextureUri(modelTextureUri: string | undefined): void;
|
1834
1843
|
/**
|
1835
1844
|
* Sets the opacity of the entity.
|
1836
1845
|
* @param opacity - The opacity of the entity between 0 and 1. 0 is fully transparent, 1 is fully opaque.
|
@@ -1929,6 +1938,7 @@ export declare enum EntityEvent {
|
|
1929
1938
|
ENTITY_CONTACT_FORCE = "ENTITY.ENTITY_CONTACT_FORCE",
|
1930
1939
|
SET_MODEL_ANIMATIONS_PLAYBACK_RATE = "ENTITY.SET_MODEL_ANIMATIONS_PLAYBACK_RATE",
|
1931
1940
|
SET_MODEL_HIDDEN_NODES = "ENTITY.SET_MODEL_HIDDEN_NODES",
|
1941
|
+
SET_MODEL_TEXTURE_URI = "ENTITY.SET_MODEL_TEXTURE_URI",
|
1932
1942
|
SET_OPACITY = "ENTITY.SET_OPACITY",
|
1933
1943
|
SET_PARENT = "ENTITY.SET_PARENT",
|
1934
1944
|
SET_TINT_COLOR = "ENTITY.SET_TINT_COLOR",
|
@@ -1985,6 +1995,11 @@ export declare interface EntityEventPayloads {
|
|
1985
1995
|
entity: Entity;
|
1986
1996
|
modelHiddenNodes: Set<string>;
|
1987
1997
|
};
|
1998
|
+
/** Emitted when the texture uri of the entity's model is set. */
|
1999
|
+
[EntityEvent.SET_MODEL_TEXTURE_URI]: {
|
2000
|
+
entity: Entity;
|
2001
|
+
modelTextureUri: string | undefined;
|
2002
|
+
};
|
1988
2003
|
/** Emitted when the opacity of the entity is set. */
|
1989
2004
|
[EntityEvent.SET_OPACITY]: {
|
1990
2005
|
entity: Entity;
|
@@ -3230,6 +3245,8 @@ export declare interface ModelEntityOptions extends BaseEntityOptions {
|
|
3230
3245
|
modelPreferredShape?: ColliderShape;
|
3231
3246
|
/** The scale of the entity's model. */
|
3232
3247
|
modelScale?: number;
|
3248
|
+
/** The texture uri of the entity's model. Setting this overrides the model's default texture. */
|
3249
|
+
modelTextureUri?: string;
|
3233
3250
|
/** The URI or path to the .gltf model asset to be used for the entity. */
|
3234
3251
|
modelUri?: string;
|
3235
3252
|
}
|