VehicleClient

setVehicleModelIsSuppressed

SET_VEHICLE_MODEL_IS_SUPPRESSED0x0FC2D89AC25A5814

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

SignatureJavaScript
setVehicleModelIsSuppressed(model: Hash, suppressed: boolean): void
SignatureLua
setVehicleModelIsSuppressed(model: Hash, suppressed: boolean)

Usage

JavaScript
setVehicleModelIsSuppressed(model, suppressed);
Lua
setVehicleModelIsSuppressed(model, suppressed)

Parameters

ParameterTypeJavaScriptLua
modelHashnumberinteger
suppressedBOOLbooleanboolean

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.

Makes the vehicle stop spawning naturally in traffic. Here's an essential example:

setVehicleModelIsSuppressed(getHashKey("taco"), true);

Full list of vehicles by DurtyFree: https://github.com/DurtyFree/gta-v-data-dumps/blob/master/vehicles.json

Reference

Namespace
Vehicle VEHICLE
In the game
void SET_VEHICLE_MODEL_IS_SUPPRESSED(Hash model, BOOL suppressed)
Hash
0x0FC2D89AC25A5814

Open in the interactive natives reference