setPlayerCanDoDriveBy
SET_PLAYER_CAN_DO_DRIVE_BY0x6E8834B52EC20C77The GTA V native SET_PLAYER_CAN_DO_DRIVE_BY of the PLAYER namespace, as LS:MP client scripts call it: the global function setPlayerCanDoDriveBy, in JavaScript and in Lua.
setPlayerCanDoDriveBy(player: Player, toggle: boolean): voidsetPlayerCanDoDriveBy(player: Player, toggle: boolean)Usage
JavaScript
setPlayerCanDoDriveBy(player, toggle);Lua
setPlayerCanDoDriveBy(player, toggle)Parameters
| Parameter | Type | JavaScript | Lua |
|---|---|---|---|
player | Player | number | integer |
toggle | BOOL | boolean | boolean |
Returns
Nothing. In JavaScript the call evaluates to undefined.
Notes
From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.
Set whether this player should be able to do drive-bys.
"A drive-by is when a ped is aiming/shooting from vehicle. This includes middle finger taunts. By setting this value to false I confirm the player is unable to do all that. Tested on tick."
Reference
- Namespace
- Player PLAYER
- In the game
void SET_PLAYER_CAN_DO_DRIVE_BY(Player player, BOOL toggle)- Hash
0x6E8834B52EC20C77