I made this mod call script which sends a complaint, the player's name and user id, and the server ID to discord. Here's that script:
local webhookURL = "This is not the real webhook, but I just didn't want people using that webhook." -- Enter webhook ID
local filteringFunction = game.ReplicatedStorage.FilteringFunction
local Players = game:GetService("Players")
local HttpService = game:GetService("HttpService")
function filteringFunction.OnServerInvoke(player, msg)
local thumbnail = Players:GetUserThumbnailAsync(player.UserId, Enum.ThumbnailType.AvatarBust, Enum.ThumbnailSize.Size420x420)
if game.JobId == "" then
serverId = "N/A"
else
serverId = tostring(game.JobId)
end
local data =
{
["content"] = "",
["embeds"] = {{
["title"] = "",
["type"] = "rich",
["color"] = tonumber(0xFF0000),
["thumbnail"] = {
["url"] = tostring(thumbnail)
},
["fields"] = {
{
["name"] = "**Player**",
["value"] = string.format("%s | %s", player.Name, player.UserId)
},
{
["name"] = "**Complaint**",
["value"] = msg
},
{
["name"] = "**Server ID**",
["value"] = serverId,
}
}
}}
}
local jsonData = HttpService:JSONEncode(data)
HttpService:PostAsync(webhookURL, jsonData)
return ""
end
Here's the result: https://prnt.sc/tnj5om (Copy and paste into a browser.)
I want the mods to be able to teleport to their server and assist them. Can anyone tell me how to do this? Here's also the GUI I have: https://prnt.sc/tnj7ks (Copy and paste into a browser.)
