#
Flashing lights
#
Get flashing lights state
SHARED
if veh:SV_GetFlashingLightsState() then
-- Flashing lights are enabled.
end
#
Set flashing lights state
CLIENT
SetFlashingLightsState sets the state of the flashing lights of the vehicle driven by the player.
-- Disables flashing lights
SVMOD:SetFlashingLightsState(false)
-- Enables flashing lights
SVMOD:SetFlashingLightsState(true)
#
Enable flashing lights
SERVER
SV_TurnOnFlashingLights turns on the flashing lights of a vehicle.
Returns true if the flashing lights have been switched on, false otherwise. The operation will fail if the flashing lights are already on, if the vehicle has no flashing lights, or if the flashing lights have been disabled.
if veh:SV_TurnOnFlashingLights() then
-- Flashing lights enabled.
else
-- Oops, operation failed!
end
#
Disable flashing lights
SERVER
SV_TurnOffFlashingLights turns off the flashing lights of a vehicle.
Returns true if the flashing lights have been switched off, false otherwise. The operation will fail if the flashing lights are already switched off.
if veh:SV_TurnOffFlashingLights() then
-- Flashing lights disabled.
else
-- Oops, operation failed!
end