-- Clientside
addEventHandler("onClientRender",root,
function()
local fala = getElementData('falando') or false
if fala == true then
dxDrawText("Ativado", x*500, y*100, x*1132, y*37, tocolor(0, 255, 0, 221), 1.00, font, "left", "top", false, false, false, true, false)
else
dxDrawText("Desativado", x*500, y*100, x*1132, y*37, tocolor(255, 0, 0, 221), 1.00, font, "left", "top", false, false, false, true, false)
end
end
)
addEventHandler ( "onClientPlayerVoiceStart", root, function()
if (source and isElement(source) and getElementType(source) == "player") and localPlayer == source then
setElementData(source, "falando", true);
end
end );
addEventHandler ( "onClientPlayerVoiceStop", root,function()
if (source and isElement(source) and getElementType(source) == "player") and localPlayer == source then
setElementData(source, "falando", false);
end
end);