VehicleClient

transformToSubmarine

TRANSFORM_TO_SUBMARINE0xBE4C854FFDB6EEBE

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

SignatureJavaScript
transformToSubmarine(vehicle: Vehicle, noAnimation: boolean): boolean
SignatureLua
transformToSubmarine(vehicle: Vehicle, noAnimation: boolean): boolean

Usage

JavaScript
const result = transformToSubmarine(vehicle, noAnimation);
Lua
local result = transformToSubmarine(vehicle, noAnimation)

Parameters

ParameterTypeJavaScriptLua
vehicleVehiclenumberinteger
noAnimationBOOLbooleanboolean

Returns

BOOL JavaScript boolean, Lua boolean

Notes

From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.

Transforms the stormberg/toreador to its "submarine" variant. If the vehicle is already in that state then the vehicle transformation audio will still play, but the vehicle won't change at all.

Reference

Namespace
Vehicle VEHICLE
In the game
BOOL TRANSFORM_TO_SUBMARINE(Vehicle vehicle, BOOL noAnimation)
Hash
0xBE4C854FFDB6EEBE
Introduced
Game build 1365 legacy numbering
Formerly
_TRANSFORM_STORMBERG_TO_WATER_VEHICLE _TRANSFORM_VEHICLE_TO_SUBMARINE

Open in the interactive natives reference