setVehicleLoadCollisionFlag
Persists GTA's mission-car collision-loading and physics-to-ghost policy independently from ordinary element collisions.
Syntax
bool setVehicleLoadCollisionFlag(vehicle theVehicle, bool loadCollision)GTA task mapping
0587 SCM equivalent: SET_LOAD_COLLISION_FOR_CAR_FLAG
This does not create a CTask. GTA stores the inverse argument in physical flag 0x4000; mission-car AI uses it when switching between physics and ghost simulation over unloaded world collision.
Arguments
theVehiclevehicleVehicle whose local mission-collision policy should change.
loadCollisionboolSCM-compatible value; false sets native physical mask 0x4000 and allows ghost physics where world collision is absent.
Returns
true when the valid vehicle accepted the policy; false for an invalid element or argument.
Ownership and lifecycle
Door-lock, tyre-burst, physical-proof, and load-collision policies live on the MTA vehicle, apply immediately when its GTA instance is streamed, and are reapplied after local native recreation. They are client-local, last-writer-wins policies rather than resource-owned leases.
- The value survives stream-out and native vehicle recreation on this client.
- There is no getter, captured prior value, or automatic resource-stop restoration. Callers remain responsible for the later vehicle lifecycle.
- This does not disable contact collisions like setElementCollisionsEnabled.
Example
setVehicleLoadCollisionFlag(voodoo, false)Where this comes from
Continue exploring
← Back to the Neon Lua API · How Native story vehicle state works →