-- This example sets the transform rate for the submarine car conversion animations to 2.5
-- Retrieve the player ped
local playerPed = PlayerPedId()
-- Retrieve the vehicle in which the player is currently seated
local vehicle = GetVehiclePedIsIn(playerPed, false) -- Get the vehicle in which the player is currently seated
-- Retrieve the vehicle model hash
local vehicleHash = GetEntityModel(vehicle)
-- Check if the vehicle exists in the game world and if it is a Stromberg.
if not DoesEntityExist(vehicle) or not vehicleHash == GetHashKey("stromberg") then
-- If the vehicle does not exist or it's not a stromberg, end the execution of the code here.
return
end
-- Set the transform rate for the submarine car conversion animations to 2.5
SetTransformRateForAnimation(vehicle, 2.5)