An ingame staff chat script, which automatically sends the text to its own discord. Perfect for team chats etc.
ESX. A Discord Webhook.
Add the following things to your server.cfg:
start esx_webhookstaffchat
Just go to main.lua copy the code after line 25 here an example:
if xPlayer.getGroup() == 'yourrankhere' then
xPlayer.showNotification("~r~STAFF-CHAT ~g~RANK ~s~(".. GetPlayerName(source).. "): " .. args)
sendToDiscord("(RANK) " .. name, nachricht)
end
Edit Line 17:
if xPlayer.getGroup() == 'mod' or xPlayer.getGroup() == 'admin' or xPlayer.getGroup() == 'yourrank' then
Have fun!