Skip to content

Commit

Permalink
Merge pull request #903 from gtasnail/master
Browse files Browse the repository at this point in the history
Update SetWantedLevel Natives p3
  • Loading branch information
thorium-cfx authored Oct 30, 2023
2 parents 4a1da2a + c0d0e1b commit 500dad9
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 18 deletions.
19 changes: 9 additions & 10 deletions PLAYER/SetPlayerWantedLevel.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,16 @@ ns: PLAYER

```c
// 0x39FF19C64EF7DA5B 0xB7A0914B
void SET_PLAYER_WANTED_LEVEL(Player player, int wantedLevel, BOOL disableNoMission);
```
```
Call SET_PLAYER_WANTED_LEVEL_NOW for immediate effect
wantedLevel is an integer value representing 0 to 5 stars even though the game supports the 6th wanted level but no police will appear since no definitions are present for it in the game files
disableNoMission- Disables When Off Mission- appears to always be false
void SET_PLAYER_WANTED_LEVEL(Player player, int wantedLevel, BOOL delayedResponse);
```
## Parameters
* **player**:
* **wantedLevel**:
* **disableNoMission**:
* **player**: the target player
* **wantedLevel**: the wanted level 1-5
* **delayedResponse**: false = 0-10sec police spawn response time, true = 10-20sec police spawn response time
## Examples
```lua
local player = PlayerId()
SetPlayerWantedLevel(player, 5, false) -- 5 star wanted level
```
17 changes: 9 additions & 8 deletions PLAYER/SetPlayerWantedLevelNoDrop.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,16 @@ ns: PLAYER

```c
// 0x340E61DE7F471565 0xED6F44F5
void SET_PLAYER_WANTED_LEVEL_NO_DROP(Player player, int wantedLevel, BOOL p2);
```
```
p2 is always false in R* scripts
void SET_PLAYER_WANTED_LEVEL_NO_DROP(Player player, int wantedLevel, BOOL delayedResponse);
```
## Parameters
* **player**:
* **wantedLevel**:
* **p2**:
* **player**: the target player
* **wantedLevel**: the wanted level 1-5
* **delayedResponse**: false = 0-10sec police spawn response time, true = 10-20sec police spawn response time
## Examples
```lua
local player = PlayerId()
SetPlayerWantedLevelNoDrop(player, 5, false) -- 5 star wanted level
```

0 comments on commit 500dad9

Please sign in to comment.