diff --git a/AUDIO/DoesPlayerVehHaveRadio.md b/AUDIO/DoesPlayerVehHaveRadio.md index de0ff5cf6..90e7c3002 100644 --- a/AUDIO/DoesPlayerVehHaveRadio.md +++ b/AUDIO/DoesPlayerVehHaveRadio.md @@ -9,4 +9,8 @@ aliases: ["0x109697E2FFBAC8A1"] BOOL DOES_PLAYER_VEH_HAVE_RADIO(); ``` +Checks if the vehicle the local player is currently in has a radio. + ## Return value + +Returns `true` if the player's current vehicle has a radio. Returns `false` if it does not, or if the player is not in any vehicle. diff --git a/VEHICLE/IsVehicleSirenAudioOn.md b/VEHICLE/IsVehicleSirenAudioOn.md index 7b5d0a2ff..c2873118b 100644 --- a/VEHICLE/IsVehicleSirenAudioOn.md +++ b/VEHICLE/IsVehicleSirenAudioOn.md @@ -9,8 +9,32 @@ aliases: ["0xB5CC40FBCB586380","_IS_VEHICLE_SIREN_SOUND_ON"] BOOL IS_VEHICLE_SIREN_AUDIO_ON(Vehicle vehicle); ``` +Checks if the siren audio is currently playing on the given vehicle. + +This only checks the sound not the lights. A vehicle can have its siren lights active while the audio is silent, for example when [`SET_VEHICLE_HAS_MUTED_SIRENS`](#_0xD8050E0EB60CF274) has been used to suppress the sound. ## Parameters -* **vehicle**: + +* **vehicle**: The vehicle to check. ## Return value + +Returns `true` if the siren audio is currently playing, `false` if it is silent or the vehicle does not have a siren. + +## Examples + +```lua +local vehicle = GetVehiclePedIsIn(PlayerPedId(), false) + +if IsVehicleSirenAudioOn(vehicle) then + print("Siren is audible") +end +``` + +```js +const vehicle = GetVehiclePedIsIn(PlayerPedId(), false); + +if (IsVehicleSirenAudioOn(vehicle)) { + console.log("Siren is audible"); +} +``` \ No newline at end of file