@nativewrappers/server 0.0.160 → 0.0.161
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/entities/Player.d.ts +6 -0
- package/entities/Player.js +8 -0
- package/package.json +1 -1
package/entities/Player.d.ts
CHANGED
|
@@ -51,6 +51,12 @@ export declare class Player {
|
|
|
51
51
|
* @returns the current routhing bucket the player is in, default is 0
|
|
52
52
|
*/
|
|
53
53
|
get RoutingBucket(): number;
|
|
54
|
+
/**
|
|
55
|
+
* Sets the players routing bucket to {@see routingBucket}
|
|
56
|
+
* You can use onPlayerBucketChange to listen for routing bucket changes
|
|
57
|
+
* {@link https://github.com/citizenfx/fivem/blob/cfed16afb4ba2d920cfd31adb0c27d758988aac3/code/components/citizen-server-impl/src/state/ServerGameState_Scripting.cpp#L1675C1-L1686C25}
|
|
58
|
+
*/
|
|
59
|
+
set RoutingBucket(routingBucket: number);
|
|
54
60
|
get Team(): number;
|
|
55
61
|
get WantedPosition(): Vector3;
|
|
56
62
|
get WantedLevel(): number;
|
package/entities/Player.js
CHANGED
|
@@ -106,6 +106,14 @@ class Player {
|
|
|
106
106
|
get RoutingBucket() {
|
|
107
107
|
return GetPlayerRoutingBucket(this.Src);
|
|
108
108
|
}
|
|
109
|
+
/**
|
|
110
|
+
* Sets the players routing bucket to {@see routingBucket}
|
|
111
|
+
* You can use onPlayerBucketChange to listen for routing bucket changes
|
|
112
|
+
* {@link https://github.com/citizenfx/fivem/blob/cfed16afb4ba2d920cfd31adb0c27d758988aac3/code/components/citizen-server-impl/src/state/ServerGameState_Scripting.cpp#L1675C1-L1686C25}
|
|
113
|
+
*/
|
|
114
|
+
set RoutingBucket(routingBucket) {
|
|
115
|
+
SetPlayerRoutingBucket(this.Handle, routingBucket);
|
|
116
|
+
}
|
|
109
117
|
get Team() {
|
|
110
118
|
return GetPlayerTeam(this.Src);
|
|
111
119
|
}
|