hytopia 0.12.0-prerelease-6 → 0.12.1
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/docs/server.collider.md +77 -14
- package/docs/server.collider.optionsfrommodeluri.md +2 -2
- package/docs/server.collider.scale.md +3 -44
- package/docs/server.collider.sethalfextents.md +54 -0
- package/docs/server.collider.sethalfheight.md +54 -0
- package/docs/server.collider.setradius.md +54 -0
- package/docs/server.collider.setscale.md +52 -0
- package/docs/server.entity.md +1 -1
- package/docs/server.entity.modelscale.md +1 -1
- package/docs/server.entity.setmodelscale.md +3 -3
- package/docs/server.entityeventpayloads._entity.set_model_scale_.md +1 -1
- package/docs/server.entityeventpayloads.md +1 -1
- package/docs/server.modelentityoptions.md +2 -2
- package/docs/server.modelentityoptions.modelscale.md +2 -2
- package/docs/server.modelregistry.gettrimesh.md +3 -3
- package/package.json +1 -1
- package/server.api.json +249 -50
- package/server.d.ts +30 -12
- package/server.mjs +80 -80
package/server.api.json
CHANGED
|
@@ -8931,8 +8931,9 @@
|
|
|
8931
8931
|
"text": ", scale?: "
|
|
8932
8932
|
},
|
|
8933
8933
|
{
|
|
8934
|
-
"kind": "
|
|
8935
|
-
"text": "
|
|
8934
|
+
"kind": "Reference",
|
|
8935
|
+
"text": "Vector3Like",
|
|
8936
|
+
"canonicalReference": "server!Vector3Like:interface"
|
|
8936
8937
|
},
|
|
8937
8938
|
{
|
|
8938
8939
|
"kind": "Content",
|
|
@@ -9194,52 +9195,35 @@
|
|
|
9194
9195
|
"name": "removeFromSimulation"
|
|
9195
9196
|
},
|
|
9196
9197
|
{
|
|
9197
|
-
"kind": "
|
|
9198
|
-
"canonicalReference": "server!Collider#scale:member
|
|
9199
|
-
"docComment": "/**\n *
|
|
9198
|
+
"kind": "Property",
|
|
9199
|
+
"canonicalReference": "server!Collider#scale:member",
|
|
9200
|
+
"docComment": "/**\n * The scale of the collider.\n */\n",
|
|
9200
9201
|
"excerptTokens": [
|
|
9201
9202
|
{
|
|
9202
9203
|
"kind": "Content",
|
|
9203
|
-
"text": "scale(
|
|
9204
|
+
"text": "get scale(): "
|
|
9204
9205
|
},
|
|
9205
9206
|
{
|
|
9206
|
-
"kind": "
|
|
9207
|
-
"text": "
|
|
9208
|
-
|
|
9209
|
-
{
|
|
9210
|
-
"kind": "Content",
|
|
9211
|
-
"text": "): "
|
|
9212
|
-
},
|
|
9213
|
-
{
|
|
9214
|
-
"kind": "Content",
|
|
9215
|
-
"text": "void"
|
|
9207
|
+
"kind": "Reference",
|
|
9208
|
+
"text": "Vector3Like",
|
|
9209
|
+
"canonicalReference": "server!Vector3Like:interface"
|
|
9216
9210
|
},
|
|
9217
9211
|
{
|
|
9218
9212
|
"kind": "Content",
|
|
9219
9213
|
"text": ";"
|
|
9220
9214
|
}
|
|
9221
9215
|
],
|
|
9222
|
-
"
|
|
9223
|
-
"
|
|
9224
|
-
"startIndex": 3,
|
|
9225
|
-
"endIndex": 4
|
|
9226
|
-
},
|
|
9216
|
+
"isReadonly": true,
|
|
9217
|
+
"isOptional": false,
|
|
9227
9218
|
"releaseTag": "Public",
|
|
9219
|
+
"name": "scale",
|
|
9220
|
+
"propertyTypeTokenRange": {
|
|
9221
|
+
"startIndex": 1,
|
|
9222
|
+
"endIndex": 2
|
|
9223
|
+
},
|
|
9224
|
+
"isStatic": false,
|
|
9228
9225
|
"isProtected": false,
|
|
9229
|
-
"
|
|
9230
|
-
"parameters": [
|
|
9231
|
-
{
|
|
9232
|
-
"parameterName": "scalar",
|
|
9233
|
-
"parameterTypeTokenRange": {
|
|
9234
|
-
"startIndex": 1,
|
|
9235
|
-
"endIndex": 2
|
|
9236
|
-
},
|
|
9237
|
-
"isOptional": false
|
|
9238
|
-
}
|
|
9239
|
-
],
|
|
9240
|
-
"isOptional": false,
|
|
9241
|
-
"isAbstract": false,
|
|
9242
|
-
"name": "scale"
|
|
9226
|
+
"isAbstract": false
|
|
9243
9227
|
},
|
|
9244
9228
|
{
|
|
9245
9229
|
"kind": "Method",
|
|
@@ -9532,6 +9516,103 @@
|
|
|
9532
9516
|
"isAbstract": false,
|
|
9533
9517
|
"name": "setFrictionCombineRule"
|
|
9534
9518
|
},
|
|
9519
|
+
{
|
|
9520
|
+
"kind": "Method",
|
|
9521
|
+
"canonicalReference": "server!Collider#setHalfExtents:member(1)",
|
|
9522
|
+
"docComment": "/**\n * Sets the half extents of a simulated block collider.\n *\n * @param halfExtents - The half extents of the block collider.\n */\n",
|
|
9523
|
+
"excerptTokens": [
|
|
9524
|
+
{
|
|
9525
|
+
"kind": "Content",
|
|
9526
|
+
"text": "setHalfExtents(halfExtents: "
|
|
9527
|
+
},
|
|
9528
|
+
{
|
|
9529
|
+
"kind": "Reference",
|
|
9530
|
+
"text": "Vector3Like",
|
|
9531
|
+
"canonicalReference": "server!Vector3Like:interface"
|
|
9532
|
+
},
|
|
9533
|
+
{
|
|
9534
|
+
"kind": "Content",
|
|
9535
|
+
"text": "): "
|
|
9536
|
+
},
|
|
9537
|
+
{
|
|
9538
|
+
"kind": "Content",
|
|
9539
|
+
"text": "void"
|
|
9540
|
+
},
|
|
9541
|
+
{
|
|
9542
|
+
"kind": "Content",
|
|
9543
|
+
"text": ";"
|
|
9544
|
+
}
|
|
9545
|
+
],
|
|
9546
|
+
"isStatic": false,
|
|
9547
|
+
"returnTypeTokenRange": {
|
|
9548
|
+
"startIndex": 3,
|
|
9549
|
+
"endIndex": 4
|
|
9550
|
+
},
|
|
9551
|
+
"releaseTag": "Public",
|
|
9552
|
+
"isProtected": false,
|
|
9553
|
+
"overloadIndex": 1,
|
|
9554
|
+
"parameters": [
|
|
9555
|
+
{
|
|
9556
|
+
"parameterName": "halfExtents",
|
|
9557
|
+
"parameterTypeTokenRange": {
|
|
9558
|
+
"startIndex": 1,
|
|
9559
|
+
"endIndex": 2
|
|
9560
|
+
},
|
|
9561
|
+
"isOptional": false
|
|
9562
|
+
}
|
|
9563
|
+
],
|
|
9564
|
+
"isOptional": false,
|
|
9565
|
+
"isAbstract": false,
|
|
9566
|
+
"name": "setHalfExtents"
|
|
9567
|
+
},
|
|
9568
|
+
{
|
|
9569
|
+
"kind": "Method",
|
|
9570
|
+
"canonicalReference": "server!Collider#setHalfHeight:member(1)",
|
|
9571
|
+
"docComment": "/**\n * Sets the half height of a simulated capsule, cone, cylinder, or round cylinder collider.\n *\n * @param halfHeight - The half height of the capsule, cone, cylinder, or round cylinder collider.\n */\n",
|
|
9572
|
+
"excerptTokens": [
|
|
9573
|
+
{
|
|
9574
|
+
"kind": "Content",
|
|
9575
|
+
"text": "setHalfHeight(halfHeight: "
|
|
9576
|
+
},
|
|
9577
|
+
{
|
|
9578
|
+
"kind": "Content",
|
|
9579
|
+
"text": "number"
|
|
9580
|
+
},
|
|
9581
|
+
{
|
|
9582
|
+
"kind": "Content",
|
|
9583
|
+
"text": "): "
|
|
9584
|
+
},
|
|
9585
|
+
{
|
|
9586
|
+
"kind": "Content",
|
|
9587
|
+
"text": "void"
|
|
9588
|
+
},
|
|
9589
|
+
{
|
|
9590
|
+
"kind": "Content",
|
|
9591
|
+
"text": ";"
|
|
9592
|
+
}
|
|
9593
|
+
],
|
|
9594
|
+
"isStatic": false,
|
|
9595
|
+
"returnTypeTokenRange": {
|
|
9596
|
+
"startIndex": 3,
|
|
9597
|
+
"endIndex": 4
|
|
9598
|
+
},
|
|
9599
|
+
"releaseTag": "Public",
|
|
9600
|
+
"isProtected": false,
|
|
9601
|
+
"overloadIndex": 1,
|
|
9602
|
+
"parameters": [
|
|
9603
|
+
{
|
|
9604
|
+
"parameterName": "halfHeight",
|
|
9605
|
+
"parameterTypeTokenRange": {
|
|
9606
|
+
"startIndex": 1,
|
|
9607
|
+
"endIndex": 2
|
|
9608
|
+
},
|
|
9609
|
+
"isOptional": false
|
|
9610
|
+
}
|
|
9611
|
+
],
|
|
9612
|
+
"isOptional": false,
|
|
9613
|
+
"isAbstract": false,
|
|
9614
|
+
"name": "setHalfHeight"
|
|
9615
|
+
},
|
|
9535
9616
|
{
|
|
9536
9617
|
"kind": "Method",
|
|
9537
9618
|
"canonicalReference": "server!Collider#setMass:member(1)",
|
|
@@ -9633,6 +9714,54 @@
|
|
|
9633
9714
|
"isAbstract": false,
|
|
9634
9715
|
"name": "setOnCollision"
|
|
9635
9716
|
},
|
|
9717
|
+
{
|
|
9718
|
+
"kind": "Method",
|
|
9719
|
+
"canonicalReference": "server!Collider#setRadius:member(1)",
|
|
9720
|
+
"docComment": "/**\n * Sets the radius of a simulated ball, capsule, cylinder, or round cylinder collider.\n *\n * @param radius - The radius of the collider.\n */\n",
|
|
9721
|
+
"excerptTokens": [
|
|
9722
|
+
{
|
|
9723
|
+
"kind": "Content",
|
|
9724
|
+
"text": "setRadius(radius: "
|
|
9725
|
+
},
|
|
9726
|
+
{
|
|
9727
|
+
"kind": "Content",
|
|
9728
|
+
"text": "number"
|
|
9729
|
+
},
|
|
9730
|
+
{
|
|
9731
|
+
"kind": "Content",
|
|
9732
|
+
"text": "): "
|
|
9733
|
+
},
|
|
9734
|
+
{
|
|
9735
|
+
"kind": "Content",
|
|
9736
|
+
"text": "void"
|
|
9737
|
+
},
|
|
9738
|
+
{
|
|
9739
|
+
"kind": "Content",
|
|
9740
|
+
"text": ";"
|
|
9741
|
+
}
|
|
9742
|
+
],
|
|
9743
|
+
"isStatic": false,
|
|
9744
|
+
"returnTypeTokenRange": {
|
|
9745
|
+
"startIndex": 3,
|
|
9746
|
+
"endIndex": 4
|
|
9747
|
+
},
|
|
9748
|
+
"releaseTag": "Public",
|
|
9749
|
+
"isProtected": false,
|
|
9750
|
+
"overloadIndex": 1,
|
|
9751
|
+
"parameters": [
|
|
9752
|
+
{
|
|
9753
|
+
"parameterName": "radius",
|
|
9754
|
+
"parameterTypeTokenRange": {
|
|
9755
|
+
"startIndex": 1,
|
|
9756
|
+
"endIndex": 2
|
|
9757
|
+
},
|
|
9758
|
+
"isOptional": false
|
|
9759
|
+
}
|
|
9760
|
+
],
|
|
9761
|
+
"isOptional": false,
|
|
9762
|
+
"isAbstract": false,
|
|
9763
|
+
"name": "setRadius"
|
|
9764
|
+
},
|
|
9636
9765
|
{
|
|
9637
9766
|
"kind": "Method",
|
|
9638
9767
|
"canonicalReference": "server!Collider#setRelativePosition:member(1)",
|
|
@@ -9731,6 +9860,55 @@
|
|
|
9731
9860
|
"isAbstract": false,
|
|
9732
9861
|
"name": "setRelativeRotation"
|
|
9733
9862
|
},
|
|
9863
|
+
{
|
|
9864
|
+
"kind": "Method",
|
|
9865
|
+
"canonicalReference": "server!Collider#setScale:member(1)",
|
|
9866
|
+
"docComment": "/**\n * Scales the collider by the given scalar. Only ball, block, capsule, cone, cylinder, round cylinder are supported.\n *\n * @param scalar - The scalar to scale the collider by.\n */\n",
|
|
9867
|
+
"excerptTokens": [
|
|
9868
|
+
{
|
|
9869
|
+
"kind": "Content",
|
|
9870
|
+
"text": "setScale(scale: "
|
|
9871
|
+
},
|
|
9872
|
+
{
|
|
9873
|
+
"kind": "Reference",
|
|
9874
|
+
"text": "Vector3Like",
|
|
9875
|
+
"canonicalReference": "server!Vector3Like:interface"
|
|
9876
|
+
},
|
|
9877
|
+
{
|
|
9878
|
+
"kind": "Content",
|
|
9879
|
+
"text": "): "
|
|
9880
|
+
},
|
|
9881
|
+
{
|
|
9882
|
+
"kind": "Content",
|
|
9883
|
+
"text": "void"
|
|
9884
|
+
},
|
|
9885
|
+
{
|
|
9886
|
+
"kind": "Content",
|
|
9887
|
+
"text": ";"
|
|
9888
|
+
}
|
|
9889
|
+
],
|
|
9890
|
+
"isStatic": false,
|
|
9891
|
+
"returnTypeTokenRange": {
|
|
9892
|
+
"startIndex": 3,
|
|
9893
|
+
"endIndex": 4
|
|
9894
|
+
},
|
|
9895
|
+
"releaseTag": "Public",
|
|
9896
|
+
"isProtected": false,
|
|
9897
|
+
"overloadIndex": 1,
|
|
9898
|
+
"parameters": [
|
|
9899
|
+
{
|
|
9900
|
+
"parameterName": "scale",
|
|
9901
|
+
"parameterTypeTokenRange": {
|
|
9902
|
+
"startIndex": 1,
|
|
9903
|
+
"endIndex": 2
|
|
9904
|
+
},
|
|
9905
|
+
"isOptional": false
|
|
9906
|
+
}
|
|
9907
|
+
],
|
|
9908
|
+
"isOptional": false,
|
|
9909
|
+
"isAbstract": false,
|
|
9910
|
+
"name": "setScale"
|
|
9911
|
+
},
|
|
9734
9912
|
{
|
|
9735
9913
|
"kind": "Method",
|
|
9736
9914
|
"canonicalReference": "server!Collider#setSensor:member(1)",
|
|
@@ -14444,8 +14622,9 @@
|
|
|
14444
14622
|
"text": "get modelScale(): "
|
|
14445
14623
|
},
|
|
14446
14624
|
{
|
|
14447
|
-
"kind": "
|
|
14448
|
-
"text": "
|
|
14625
|
+
"kind": "Reference",
|
|
14626
|
+
"text": "Vector3Like",
|
|
14627
|
+
"canonicalReference": "server!Vector3Like:interface"
|
|
14449
14628
|
},
|
|
14450
14629
|
{
|
|
14451
14630
|
"kind": "Content",
|
|
@@ -14836,15 +15015,20 @@
|
|
|
14836
15015
|
{
|
|
14837
15016
|
"kind": "Method",
|
|
14838
15017
|
"canonicalReference": "server!Entity#setModelScale:member(1)",
|
|
14839
|
-
"docComment": "/**\n * Sets the scale of the entity's model and proportionally scales its colliders.\n *\n * @param modelScale - The scale of the entity's model.\n */\n",
|
|
15018
|
+
"docComment": "/**\n * Sets the scale of the entity's model and proportionally scales its colliders.\n *\n * @param modelScale - The scale of the entity's model. Can be a vector or a number for uniform scaling.\n */\n",
|
|
14840
15019
|
"excerptTokens": [
|
|
14841
15020
|
{
|
|
14842
15021
|
"kind": "Content",
|
|
14843
15022
|
"text": "setModelScale(modelScale: "
|
|
14844
15023
|
},
|
|
15024
|
+
{
|
|
15025
|
+
"kind": "Reference",
|
|
15026
|
+
"text": "Vector3Like",
|
|
15027
|
+
"canonicalReference": "server!Vector3Like:interface"
|
|
15028
|
+
},
|
|
14845
15029
|
{
|
|
14846
15030
|
"kind": "Content",
|
|
14847
|
-
"text": "number"
|
|
15031
|
+
"text": " | number"
|
|
14848
15032
|
},
|
|
14849
15033
|
{
|
|
14850
15034
|
"kind": "Content",
|
|
@@ -14861,8 +15045,8 @@
|
|
|
14861
15045
|
],
|
|
14862
15046
|
"isStatic": false,
|
|
14863
15047
|
"returnTypeTokenRange": {
|
|
14864
|
-
"startIndex":
|
|
14865
|
-
"endIndex":
|
|
15048
|
+
"startIndex": 4,
|
|
15049
|
+
"endIndex": 5
|
|
14866
15050
|
},
|
|
14867
15051
|
"releaseTag": "Public",
|
|
14868
15052
|
"isProtected": false,
|
|
@@ -14872,7 +15056,7 @@
|
|
|
14872
15056
|
"parameterName": "modelScale",
|
|
14873
15057
|
"parameterTypeTokenRange": {
|
|
14874
15058
|
"startIndex": 1,
|
|
14875
|
-
"endIndex":
|
|
15059
|
+
"endIndex": 3
|
|
14876
15060
|
},
|
|
14877
15061
|
"isOptional": false
|
|
14878
15062
|
}
|
|
@@ -16553,7 +16737,16 @@
|
|
|
16553
16737
|
},
|
|
16554
16738
|
{
|
|
16555
16739
|
"kind": "Content",
|
|
16556
|
-
"text": ";\n modelScale:
|
|
16740
|
+
"text": ";\n modelScale: "
|
|
16741
|
+
},
|
|
16742
|
+
{
|
|
16743
|
+
"kind": "Reference",
|
|
16744
|
+
"text": "Vector3Like",
|
|
16745
|
+
"canonicalReference": "server!Vector3Like:interface"
|
|
16746
|
+
},
|
|
16747
|
+
{
|
|
16748
|
+
"kind": "Content",
|
|
16749
|
+
"text": ";\n }"
|
|
16557
16750
|
},
|
|
16558
16751
|
{
|
|
16559
16752
|
"kind": "Content",
|
|
@@ -16566,7 +16759,7 @@
|
|
|
16566
16759
|
"name": "\"ENTITY.SET_MODEL_SCALE\"",
|
|
16567
16760
|
"propertyTypeTokenRange": {
|
|
16568
16761
|
"startIndex": 3,
|
|
16569
|
-
"endIndex":
|
|
16762
|
+
"endIndex": 8
|
|
16570
16763
|
}
|
|
16571
16764
|
},
|
|
16572
16765
|
{
|
|
@@ -28346,15 +28539,20 @@
|
|
|
28346
28539
|
{
|
|
28347
28540
|
"kind": "PropertySignature",
|
|
28348
28541
|
"canonicalReference": "server!ModelEntityOptions#modelScale:member",
|
|
28349
|
-
"docComment": "/**\n * The scale of the entity's model.\n */\n",
|
|
28542
|
+
"docComment": "/**\n * The scale of the entity's model. Can be a vector3 for per-axis scaling, or a number for uniform scaling.\n */\n",
|
|
28350
28543
|
"excerptTokens": [
|
|
28351
28544
|
{
|
|
28352
28545
|
"kind": "Content",
|
|
28353
28546
|
"text": "modelScale?: "
|
|
28354
28547
|
},
|
|
28548
|
+
{
|
|
28549
|
+
"kind": "Reference",
|
|
28550
|
+
"text": "Vector3Like",
|
|
28551
|
+
"canonicalReference": "server!Vector3Like:interface"
|
|
28552
|
+
},
|
|
28355
28553
|
{
|
|
28356
28554
|
"kind": "Content",
|
|
28357
|
-
"text": "number"
|
|
28555
|
+
"text": " | number"
|
|
28358
28556
|
},
|
|
28359
28557
|
{
|
|
28360
28558
|
"kind": "Content",
|
|
@@ -28367,7 +28565,7 @@
|
|
|
28367
28565
|
"name": "modelScale",
|
|
28368
28566
|
"propertyTypeTokenRange": {
|
|
28369
28567
|
"startIndex": 1,
|
|
28370
|
-
"endIndex":
|
|
28568
|
+
"endIndex": 3
|
|
28371
28569
|
}
|
|
28372
28570
|
},
|
|
28373
28571
|
{
|
|
@@ -28719,7 +28917,7 @@
|
|
|
28719
28917
|
{
|
|
28720
28918
|
"kind": "Method",
|
|
28721
28919
|
"canonicalReference": "server!ModelRegistry#getTrimesh:member(1)",
|
|
28722
|
-
"docComment": "/**\n * Retrieves the trimesh of a model.\n *\n * @param modelUri - The URI of the model to retrieve the trimesh for.\n *\n * @param scale - Optional
|
|
28920
|
+
"docComment": "/**\n * Retrieves the trimesh of a model.\n *\n * @param modelUri - The URI of the model to retrieve the trimesh for.\n *\n * @param scale - Optional scaling to apply to the trimesh. Defaults to 1 for all axes (no scaling).\n *\n * @returns The trimesh of the model.\n */\n",
|
|
28723
28921
|
"excerptTokens": [
|
|
28724
28922
|
{
|
|
28725
28923
|
"kind": "Content",
|
|
@@ -28734,8 +28932,9 @@
|
|
|
28734
28932
|
"text": ", scale?: "
|
|
28735
28933
|
},
|
|
28736
28934
|
{
|
|
28737
|
-
"kind": "
|
|
28738
|
-
"text": "
|
|
28935
|
+
"kind": "Reference",
|
|
28936
|
+
"text": "Vector3Like",
|
|
28937
|
+
"canonicalReference": "server!Vector3Like:interface"
|
|
28739
28938
|
},
|
|
28740
28939
|
{
|
|
28741
28940
|
"kind": "Content",
|
package/server.d.ts
CHANGED
|
@@ -1169,7 +1169,8 @@ export declare class Collider extends EventRouter {
|
|
|
1169
1169
|
|
|
1170
1170
|
|
|
1171
1171
|
|
|
1172
|
-
|
|
1172
|
+
|
|
1173
|
+
|
|
1173
1174
|
|
|
1174
1175
|
|
|
1175
1176
|
|
|
@@ -1190,7 +1191,7 @@ export declare class Collider extends EventRouter {
|
|
|
1190
1191
|
* @param preferredShape - The preferred shape to use for the collider.
|
|
1191
1192
|
* @returns The collider options object.
|
|
1192
1193
|
*/
|
|
1193
|
-
static optionsFromModelUri(modelUri: string, scale?:
|
|
1194
|
+
static optionsFromModelUri(modelUri: string, scale?: Vector3Like, preferredShape?: ColliderShape): ColliderOptions;
|
|
1194
1195
|
/** The bounciness of the collider. */
|
|
1195
1196
|
get bounciness(): number;
|
|
1196
1197
|
/** The bounciness combine rule of the collider. */
|
|
@@ -1219,6 +1220,8 @@ export declare class Collider extends EventRouter {
|
|
|
1219
1220
|
get relativePosition(): Vector3Like;
|
|
1220
1221
|
/** The relative rotation of the collider. */
|
|
1221
1222
|
get relativeRotation(): QuaternionLike;
|
|
1223
|
+
/** The scale of the collider. */
|
|
1224
|
+
get scale(): Vector3Like;
|
|
1222
1225
|
/** The shape of the collider. */
|
|
1223
1226
|
get shape(): ColliderShape;
|
|
1224
1227
|
/** An arbitrary identifier tag of the collider. Useful for your own logic. */
|
|
@@ -1253,6 +1256,16 @@ export declare class Collider extends EventRouter {
|
|
|
1253
1256
|
* @param frictionCombineRule - The friction combine rule of the collider.
|
|
1254
1257
|
*/
|
|
1255
1258
|
setFrictionCombineRule(frictionCombineRule: CoefficientCombineRule): void;
|
|
1259
|
+
/**
|
|
1260
|
+
* Sets the half extents of a simulated block collider.
|
|
1261
|
+
* @param halfExtents - The half extents of the block collider.
|
|
1262
|
+
*/
|
|
1263
|
+
setHalfExtents(halfExtents: Vector3Like): void;
|
|
1264
|
+
/**
|
|
1265
|
+
* Sets the half height of a simulated capsule, cone, cylinder, or round cylinder collider.
|
|
1266
|
+
* @param halfHeight - The half height of the capsule, cone, cylinder, or round cylinder collider.
|
|
1267
|
+
*/
|
|
1268
|
+
setHalfHeight(halfHeight: number): void;
|
|
1256
1269
|
/**
|
|
1257
1270
|
* Sets the mass of the collider.
|
|
1258
1271
|
* @param mass - The mass of the collider.
|
|
@@ -1263,6 +1276,11 @@ export declare class Collider extends EventRouter {
|
|
|
1263
1276
|
* @param callback - The on collision callback for the collider.
|
|
1264
1277
|
*/
|
|
1265
1278
|
setOnCollision(callback: CollisionCallback | undefined): void;
|
|
1279
|
+
/**
|
|
1280
|
+
* Sets the radius of a simulated ball, capsule, cylinder, or round cylinder collider.
|
|
1281
|
+
* @param radius - The radius of the collider.
|
|
1282
|
+
*/
|
|
1283
|
+
setRadius(radius: number): void;
|
|
1266
1284
|
/**
|
|
1267
1285
|
* Sets the relative rotation of the collider to its parent rigid body or the world origin.
|
|
1268
1286
|
*
|
|
@@ -1329,7 +1347,7 @@ export declare class Collider extends EventRouter {
|
|
|
1329
1347
|
* are supported.
|
|
1330
1348
|
* @param scalar - The scalar to scale the collider by.
|
|
1331
1349
|
*/
|
|
1332
|
-
scale
|
|
1350
|
+
setScale(scale: Vector3Like): void;
|
|
1333
1351
|
|
|
1334
1352
|
|
|
1335
1353
|
private _buildWedgeConvexHullVertices;
|
|
@@ -1900,7 +1918,7 @@ export declare class Entity extends RigidBody implements protocol.Serializable {
|
|
|
1900
1918
|
/** The preferred shape of the entity's model when automatically generating its collider when no explicit colliders are provided. */
|
|
1901
1919
|
get modelPreferredShape(): ColliderShape | undefined;
|
|
1902
1920
|
/** The scale of the entity's model. */
|
|
1903
|
-
get modelScale():
|
|
1921
|
+
get modelScale(): Vector3Like;
|
|
1904
1922
|
/** The nodes to show on the entity's model, overriding hidden nodes. */
|
|
1905
1923
|
get modelShownNodes(): ReadonlySet<string>;
|
|
1906
1924
|
/** The URI or path to the texture that overrides the model entity's default texture. */
|
|
@@ -1968,9 +1986,9 @@ export declare class Entity extends RigidBody implements protocol.Serializable {
|
|
|
1968
1986
|
/**
|
|
1969
1987
|
* Sets the scale of the entity's model and proportionally
|
|
1970
1988
|
* scales its colliders.
|
|
1971
|
-
* @param modelScale - The scale of the entity's model.
|
|
1989
|
+
* @param modelScale - The scale of the entity's model. Can be a vector or a number for uniform scaling.
|
|
1972
1990
|
*/
|
|
1973
|
-
setModelScale(modelScale: number): void;
|
|
1991
|
+
setModelScale(modelScale: Vector3Like | number): void;
|
|
1974
1992
|
/**
|
|
1975
1993
|
* Sets the nodes to show on the entity's model, overriding hidden nodes.
|
|
1976
1994
|
* Matched nodes will be shown for all players. Uses case insensitive
|
|
@@ -2144,7 +2162,7 @@ export declare interface EntityEventPayloads {
|
|
|
2144
2162
|
/** Emitted when the scale of the entity's model is set. */
|
|
2145
2163
|
[EntityEvent.SET_MODEL_SCALE]: {
|
|
2146
2164
|
entity: Entity;
|
|
2147
|
-
modelScale:
|
|
2165
|
+
modelScale: Vector3Like;
|
|
2148
2166
|
};
|
|
2149
2167
|
/** Emitted when nodes of the entity's model are set to be shown. */
|
|
2150
2168
|
[EntityEvent.SET_MODEL_SHOWN_NODES]: {
|
|
@@ -3540,8 +3558,8 @@ export declare interface ModelEntityOptions extends BaseEntityOptions {
|
|
|
3540
3558
|
modelLoopedAnimations?: string[];
|
|
3541
3559
|
/** The preferred shape of the entity's model when automatically generating its collider when no explicit colliders are provided. */
|
|
3542
3560
|
modelPreferredShape?: ColliderShape;
|
|
3543
|
-
/** The scale of the entity's model. */
|
|
3544
|
-
modelScale?: number;
|
|
3561
|
+
/** The scale of the entity's model. Can be a vector3 for per-axis scaling, or a number for uniform scaling. */
|
|
3562
|
+
modelScale?: Vector3Like | number;
|
|
3545
3563
|
/** The nodes to show on the entity's model, overriding hidden nodes. */
|
|
3546
3564
|
modelShownNodes?: string[];
|
|
3547
3565
|
/** The texture uri of the entity's model. Setting this overrides the model's default texture. */
|
|
@@ -3618,10 +3636,10 @@ export declare class ModelRegistry {
|
|
|
3618
3636
|
* Retrieves the trimesh of a model.
|
|
3619
3637
|
*
|
|
3620
3638
|
* @param modelUri - The URI of the model to retrieve the trimesh for.
|
|
3621
|
-
* @param scale - Optional
|
|
3639
|
+
* @param scale - Optional scaling to apply to the trimesh. Defaults to 1 for all axes (no scaling).
|
|
3622
3640
|
* @returns The trimesh of the model.
|
|
3623
3641
|
*/
|
|
3624
|
-
getTrimesh(modelUri: string, scale?:
|
|
3642
|
+
getTrimesh(modelUri: string, scale?: Vector3Like): ModelTrimesh | undefined;
|
|
3625
3643
|
/**
|
|
3626
3644
|
* Retrieves the X-axis width of a model for a scale of 1.
|
|
3627
3645
|
*
|
|
@@ -4453,7 +4471,6 @@ export declare type PathfindingOptions = {
|
|
|
4453
4471
|
export declare class PersistenceManager {
|
|
4454
4472
|
static readonly instance: PersistenceManager;
|
|
4455
4473
|
private _saveStatesClient;
|
|
4456
|
-
private _playerData;
|
|
4457
4474
|
|
|
4458
4475
|
/**
|
|
4459
4476
|
* Get global data from the data persistence service.
|
|
@@ -4472,6 +4489,7 @@ export declare class PersistenceManager {
|
|
|
4472
4489
|
setGlobalData(key: string, data: Record<string, unknown>): Promise<void>;
|
|
4473
4490
|
|
|
4474
4491
|
|
|
4492
|
+
|
|
4475
4493
|
}
|
|
4476
4494
|
|
|
4477
4495
|
/**
|