VehicleClient

setPlaybackToUseAi

SET_PLAYBACK_TO_USE_AI0xA549C3B37EA28131

The GTA V native SET_PLAYBACK_TO_USE_AI of the VEHICLE namespace, as LS:MP client scripts call it: the global function setPlaybackToUseAi, in JavaScript and in Lua.

SignatureJavaScript
setPlaybackToUseAi(vehicle: Vehicle, drivingStyle: number): void
SignatureLua
setPlaybackToUseAi(vehicle: Vehicle, drivingStyle: integer)

Usage

JavaScript
setPlaybackToUseAi(vehicle, drivingStyle);
Lua
setPlaybackToUseAi(vehicle, drivingStyle)

Parameters

ParameterTypeJavaScriptLua
vehicleVehiclenumberinteger
drivingStyleintnumberinteger

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.

Identical to setPlaybackToUseAiTryToRevertBackLater with 0 as arguments for p1 and p3.

Reference

Namespace
Vehicle VEHICLE
In the game
void SET_PLAYBACK_TO_USE_AI(Vehicle vehicle, int drivingStyle)
Hash
0xA549C3B37EA28131

Open in the interactive natives reference