onClientPlayerVoiceStop | Multi Theft Auto: Wiki Skip to content

onClientPlayerVoiceStop

Client-side
Server-side
Shared

This event is triggered when a player stops talking through voice chat.

This event triggers inconsistently ( https://github.com/multitheftauto/mtasa-blue/issues/1700 ). You should use onPlayerVoiceStart and trigger a custom client-sided event to get similar results, minus the cancelEvent effect.

This event should only be used as a low-level function for advanced users. For typical Voice scripting, please see the Voice Resource

Parameters

This event does not pass any parameters to the handler function.

Source

element: The source of this event is the player element that just stopped talking through voice chat.

Canceling

This example outputs to the console the player that stopped talking.

Code Examples

client

This example outputs to the console the player that stopped talking.

addEventHandler("onClientPlayerVoiceStop",root,function()
outputConsole(getPlayerName(source)..." has stopped talking.")
end)

See Also