I recently got a FiveM server(■■■■■■■ Servers). I would like some help on how to add a role in the chat of my server. Instead of my name(in game) being Aaron Burr, it would be Owner | Aaron Burr, Owner being the role.
You require to modify the chat resource so that you append it in front of your name.
no?
AddEventHandler('chatMessage', function(s, n, m)
if GetPlayerIdentifiers(s)[1] == 'steam:110000112345678' then
TriggerClientEvent('chatMessage', -1, 'Snail | ' .. n, { 255, 0, 255 }, m)
CancelEvent()
end
end)
modify as needed for ignoring any commands you cancel
1 Like
Thanks Man. Really appreciate it