Eai rapaziada, eu estou tentando colocar o CHAT ANONIMO no meu servidor e que apareça o
nome do player somente para quem está na ACL "Staff", mas quando algum player manda
mesnagem, o nick dele não aparece para mim, me ajuda ai porfavor.
function adminchat4 ( thePlayer, _, ... )
local message = table.concat ( { ... }, " " )
if ( isPlayerOnGroup ( thePlayer ) ) then
for _, player in ipairs ( getElementsByType ( "player" ) ) do
if ( isPlayerOnGroup ( player ) ) then
if getElementData (thePlayer, "ChatGlobal:Delay1", true) then
outputChatBox ( MensagemFalandoRapidoDemaisGlobal, thePlayer, 255, 255, 255, true ) return end
conta = getAccountName(getPlayerAccount(thePlayer))
if isObjectInACLGroup ("user."..conta, aclGetGroup ( "Console" ) ) then
outputChatBox("* #bfbfbfDeep Web - #ffffff"..getPlayerName(thePlayer).. " ("..getPlayerID(thePlayer)..") #bfbfbf- "..message, player, 255, 255, 255, true)
elseif isObjectInACLGroup ("user."..conta, aclGetGroup ( "Staff" ) ) then
outputChatBox("* #bfbfbfDeep Web - #ffffff"..getPlayerName(thePlayer).. " ("..getPlayerID(thePlayer)..") #bfbfbf- "..message, player, 255, 255, 255, true)
elseif isObjectInACLGroup ("user."..conta, aclGetGroup ( "Everyone" ) ) then
outputChatBox("* #bfbfbfDeep Web - "..message, player, 255, 255, 255, true)
end
end
end
end
setElementData ( thePlayer, "ChatGlobal:Delay2",true )
setTimer ( setElementData, 100, 1, thePlayer, "ChatGlobal:Delay2", false )
end
addCommandHandler ( ComandoDoChatGlobal4, adminchat4 )