ResetVehicleAudioSettings: Difference between revisions
Jump to navigation
Jump to search
(Created page with "{{client function}} __NOTOC__ {{New feature/item|3.0161|1.6.0|23140|This function resets the audio properties of a specific vehicle instance back to its model's default settings. Any custom audio settings that were applied to the vehicle using setVehicleAudioSetting will be removed, restoring the original sound characteristics.}} ==Syntax== <syntaxhighlight lang="lua"> bool resetVehicleAudioSettings ( vehicle theVehicle ) </syntaxhighlight> ===Required Arguments===...") |
(No difference)
|
Revision as of 17:51, 25 July 2025
Syntax
bool resetVehicleAudioSettings ( vehicle theVehicle )
Required Arguments
- theVehicle: The vehicle element to reset audio settings for
Returns
Returns true if the vehicle audio settings were successfully reset, false otherwise.
Example
-- Reset audio settings for the player's current vehicle local player = getLocalPlayer() local vehicle = getPedOccupiedVehicle(player) if vehicle then local success = resetVehicleAudioSettings(vehicle) if success then outputChatBox("Vehicle audio settings have been reset to default.") else outputChatBox("Failed to reset vehicle audio settings.") end else outputChatBox("You must be in a vehicle to use this command.") end