hytopia 0.14.36 → 0.14.37

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.
@@ -1,13 +1,13 @@
1
1
  <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
2
 
3
- [Home](./index.md) &gt; [server](./server.md) &gt; [Player](./server.player.md) &gt; [interactEnabled](./server.player.interactenabled.md)
3
+ [Home](./index.md) &gt; [server](./server.md) &gt; [Player](./server.player.md) &gt; [isInteractEnabled](./server.player.isinteractenabled.md)
4
4
 
5
- ## Player.interactEnabled property
5
+ ## Player.isInteractEnabled property
6
6
 
7
7
  Whether the players click/taps will cause interacts with blocks or entities. Defaults to true.
8
8
 
9
9
  **Signature:**
10
10
 
11
11
  ```typescript
12
- get interactEnabled(): boolean;
12
+ get isInteractEnabled(): boolean;
13
13
  ```
@@ -134,7 +134,7 @@ The current [PlayerInput](./server.playerinput.md) of the player.
134
134
  </td></tr>
135
135
  <tr><td>
136
136
 
137
- [interactEnabled](./server.player.interactenabled.md)
137
+ [isInteractEnabled](./server.player.isinteractenabled.md)
138
138
 
139
139
 
140
140
  </td><td>
@@ -0,0 +1,13 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [server](./server.md) &gt; [PlayerEntity](./server.playerentity.md) &gt; [isTickWithPlayerInputEnabled](./server.playerentity.istickwithplayerinputenabled.md)
4
+
5
+ ## PlayerEntity.isTickWithPlayerInputEnabled property
6
+
7
+ Whether tickWithPlayerInput() is called during the entity's tick.
8
+
9
+ **Signature:**
10
+
11
+ ```typescript
12
+ get isTickWithPlayerInputEnabled(): boolean;
13
+ ```
@@ -93,6 +93,27 @@ Description
93
93
  </th></tr></thead>
94
94
  <tbody><tr><td>
95
95
 
96
+ [isTickWithPlayerInputEnabled](./server.playerentity.istickwithplayerinputenabled.md)
97
+
98
+
99
+ </td><td>
100
+
101
+ `readonly`
102
+
103
+
104
+ </td><td>
105
+
106
+ boolean
107
+
108
+
109
+ </td><td>
110
+
111
+ Whether tickWithPlayerInput() is called during the entity's tick.
112
+
113
+
114
+ </td></tr>
115
+ <tr><td>
116
+
96
117
  [nametagSceneUI](./server.playerentity.nametagsceneui.md)
97
118
 
98
119
 
@@ -132,5 +153,39 @@ The SceneUI instance for the player entity's nametag.
132
153
  The player the player entity is assigned to and controlled by.
133
154
 
134
155
 
156
+ </td></tr>
157
+ </tbody></table>
158
+
159
+ ## Methods
160
+
161
+ <table><thead><tr><th>
162
+
163
+ Method
164
+
165
+
166
+ </th><th>
167
+
168
+ Modifiers
169
+
170
+
171
+ </th><th>
172
+
173
+ Description
174
+
175
+
176
+ </th></tr></thead>
177
+ <tbody><tr><td>
178
+
179
+ [setTickWithPlayerInputEnabled(enabled)](./server.playerentity.settickwithplayerinputenabled.md)
180
+
181
+
182
+ </td><td>
183
+
184
+
185
+ </td><td>
186
+
187
+ Sets whether tickWithPlayerInput() is called during the entity's tick. Disabling this effectively disables player control of the entity.
188
+
189
+
135
190
  </td></tr>
136
191
  </tbody></table>
@@ -0,0 +1,53 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [server](./server.md) &gt; [PlayerEntity](./server.playerentity.md) &gt; [setTickWithPlayerInputEnabled](./server.playerentity.settickwithplayerinputenabled.md)
4
+
5
+ ## PlayerEntity.setTickWithPlayerInputEnabled() method
6
+
7
+ Sets whether tickWithPlayerInput() is called during the entity's tick. Disabling this effectively disables player control of the entity.
8
+
9
+ **Signature:**
10
+
11
+ ```typescript
12
+ setTickWithPlayerInputEnabled(enabled: boolean): void;
13
+ ```
14
+
15
+ ## Parameters
16
+
17
+ <table><thead><tr><th>
18
+
19
+ Parameter
20
+
21
+
22
+ </th><th>
23
+
24
+ Type
25
+
26
+
27
+ </th><th>
28
+
29
+ Description
30
+
31
+
32
+ </th></tr></thead>
33
+ <tbody><tr><td>
34
+
35
+ enabled
36
+
37
+
38
+ </td><td>
39
+
40
+ boolean
41
+
42
+
43
+ </td><td>
44
+
45
+ Whether tickWithPlayerInput() should be called.
46
+
47
+
48
+ </td></tr>
49
+ </tbody></table>
50
+ **Returns:**
51
+
52
+ void
53
+
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hytopia",
3
- "version": "0.14.36",
3
+ "version": "0.14.37",
4
4
  "description": "The HYTOPIA SDK makes it easy for developers to create massively multiplayer games using JavaScript or TypeScript.",
5
5
  "type": "module",
6
6
  "main": "./server.mjs",
package/server.api.json CHANGED
@@ -34768,12 +34768,12 @@
34768
34768
  },
34769
34769
  {
34770
34770
  "kind": "Property",
34771
- "canonicalReference": "server!Player#interactEnabled:member",
34771
+ "canonicalReference": "server!Player#isInteractEnabled:member",
34772
34772
  "docComment": "/**\n * Whether the players click/taps will cause interacts with blocks or entities. Defaults to true.\n */\n",
34773
34773
  "excerptTokens": [
34774
34774
  {
34775
34775
  "kind": "Content",
34776
- "text": "get interactEnabled(): "
34776
+ "text": "get isInteractEnabled(): "
34777
34777
  },
34778
34778
  {
34779
34779
  "kind": "Content",
@@ -34787,7 +34787,7 @@
34787
34787
  "isReadonly": true,
34788
34788
  "isOptional": false,
34789
34789
  "releaseTag": "Public",
34790
- "name": "interactEnabled",
34790
+ "name": "isInteractEnabled",
34791
34791
  "propertyTypeTokenRange": {
34792
34792
  "startIndex": 1,
34793
34793
  "endIndex": 2
@@ -38014,6 +38014,36 @@
38014
38014
  }
38015
38015
  ]
38016
38016
  },
38017
+ {
38018
+ "kind": "Property",
38019
+ "canonicalReference": "server!PlayerEntity#isTickWithPlayerInputEnabled:member",
38020
+ "docComment": "/**\n * Whether tickWithPlayerInput() is called during the entity's tick.\n */\n",
38021
+ "excerptTokens": [
38022
+ {
38023
+ "kind": "Content",
38024
+ "text": "get isTickWithPlayerInputEnabled(): "
38025
+ },
38026
+ {
38027
+ "kind": "Content",
38028
+ "text": "boolean"
38029
+ },
38030
+ {
38031
+ "kind": "Content",
38032
+ "text": ";"
38033
+ }
38034
+ ],
38035
+ "isReadonly": true,
38036
+ "isOptional": false,
38037
+ "releaseTag": "Public",
38038
+ "name": "isTickWithPlayerInputEnabled",
38039
+ "propertyTypeTokenRange": {
38040
+ "startIndex": 1,
38041
+ "endIndex": 2
38042
+ },
38043
+ "isStatic": false,
38044
+ "isProtected": false,
38045
+ "isAbstract": false
38046
+ },
38017
38047
  {
38018
38048
  "kind": "Property",
38019
38049
  "canonicalReference": "server!PlayerEntity#nametagSceneUI:member",
@@ -38075,6 +38105,54 @@
38075
38105
  "isStatic": false,
38076
38106
  "isProtected": false,
38077
38107
  "isAbstract": false
38108
+ },
38109
+ {
38110
+ "kind": "Method",
38111
+ "canonicalReference": "server!PlayerEntity#setTickWithPlayerInputEnabled:member(1)",
38112
+ "docComment": "/**\n * Sets whether tickWithPlayerInput() is called during the entity's tick. Disabling this effectively disables player control of the entity.\n *\n * @param enabled - Whether tickWithPlayerInput() should be called.\n */\n",
38113
+ "excerptTokens": [
38114
+ {
38115
+ "kind": "Content",
38116
+ "text": "setTickWithPlayerInputEnabled(enabled: "
38117
+ },
38118
+ {
38119
+ "kind": "Content",
38120
+ "text": "boolean"
38121
+ },
38122
+ {
38123
+ "kind": "Content",
38124
+ "text": "): "
38125
+ },
38126
+ {
38127
+ "kind": "Content",
38128
+ "text": "void"
38129
+ },
38130
+ {
38131
+ "kind": "Content",
38132
+ "text": ";"
38133
+ }
38134
+ ],
38135
+ "isStatic": false,
38136
+ "returnTypeTokenRange": {
38137
+ "startIndex": 3,
38138
+ "endIndex": 4
38139
+ },
38140
+ "releaseTag": "Public",
38141
+ "isProtected": false,
38142
+ "overloadIndex": 1,
38143
+ "parameters": [
38144
+ {
38145
+ "parameterName": "enabled",
38146
+ "parameterTypeTokenRange": {
38147
+ "startIndex": 1,
38148
+ "endIndex": 2
38149
+ },
38150
+ "isOptional": false
38151
+ }
38152
+ ],
38153
+ "isOptional": false,
38154
+ "isAbstract": false,
38155
+ "name": "setTickWithPlayerInputEnabled"
38078
38156
  }
38079
38157
  ],
38080
38158
  "extendsTokenRange": {
package/server.d.ts CHANGED
@@ -4349,7 +4349,7 @@ export declare class Player extends EventRouter implements protocol.Serializable
4349
4349
  /** The current {@link PlayerInput} of the player. */
4350
4350
  get input(): PlayerInput;
4351
4351
  /** Whether the players click/taps will cause interacts with blocks or entities. Defaults to true. */
4352
- get interactEnabled(): boolean;
4352
+ get isInteractEnabled(): boolean;
4353
4353
  /** The maximum distance a player can interact with entities or blocks. The raycast distance in blocks for interactions. Defaults to 20. */
4354
4354
  get maxInteractDistance(): number;
4355
4355
  /** The current {@link World} the player is in. */
@@ -4784,10 +4784,19 @@ export declare class PlayerEntity extends Entity {
4784
4784
  readonly player: Player;
4785
4785
  /** The SceneUI instance for the player entity's nametag. */
4786
4786
  readonly nametagSceneUI: SceneUI;
4787
+
4787
4788
  /**
4788
4789
  * @param options - The options for the player entity.
4789
4790
  */
4790
4791
  constructor(options: PlayerEntityOptions);
4792
+ /** Whether tickWithPlayerInput() is called during the entity's tick. */
4793
+ get isTickWithPlayerInputEnabled(): boolean;
4794
+ /**
4795
+ * Sets whether tickWithPlayerInput() is called during the entity's tick. Disabling
4796
+ * this effectively disables player control of the entity.
4797
+ * @param enabled - Whether tickWithPlayerInput() should be called.
4798
+ */
4799
+ setTickWithPlayerInputEnabled(enabled: boolean): void;
4791
4800
 
4792
4801
 
4793
4802
  }