This webhook is sending too many requests at once, and showing Https 429 (Too many Request)
It is apart of the anti-exploit system. It’s only happening for this part.
Part of the script that is causing this;
NOTE: Teleport Detection part wasn’t made by me, I added remote event and kick part onto it.
function AntiTeleport()
local FirstPos = root.Position
delay(1, function()
local SecPos = root.Position
if (FirstPos - SecPos).magnitude > 140 then
if plr.Backpack.Teleport.Value ~= true then
if plr.Backpack.Sprint.Value ~= true then
local reason = "Teleporting"
game.ReplicatedStorage.ExploitLog:FireServer(plr,ID,reason)
wait(1)
plr:kick("Exploit Detection: "..reason.." CLASSIFIED INFORMATION!")
end
end
end
end)
end
while wait() do
AntiTeleport()
end
REMOTE EVENT FUNCTION!
local ReplicatedStorage = game.ReplicatedStorage
wait(1)
ReplicatedStorage.ExploitLog.OnServerEvent:Connect(function(plr,ID,reason,reason)
local webhook = 'HIDDEN'
local HttpService = game:GetService("HttpService")
local data = {
["username"] = "Exploit logs",
["content"] = "",
["embeds"] = {{
["title"] = "__**Exploit log!**__",
["description"] = "HIDDEN",
["type"] = "rich",
["color"] = tonumber(0xffffff),
["fields"] = {
{
["name"] = "__Exploiter Player Information:__",
["value"] = "Below",
["inline"] = false
},
{
["name"] = "__Exploiter Player Username:__",
["value"] = tostring(plr),
["inline"] = true
},
{
["name"] = "__Exploiter Player ID (UserId)__",
["value"] = ID.UserId,
["inline"] = true
},
{
["name"] = "__Reason:__",
["value"] = reason,
["inline"] = false
}
}
}}
}
local newdata1 = HttpService:JSONEncode(data)
HttpService:PostAsync(webhook, newdata1)
end)
OUTPOT LOG
NOTE: I did clear up a lot of script from useless notes made by me.
game.ReplicatedStorage.ExploitLog:FireServer(plr,ID,reason)
The same thing functions for every other part of the script, and it only sends a request once. Any ideas on how to fix it?
It sending ~50 requests and only 5 go through to disco. But, it should only send one, so I am confused.
It works perfectly for every other request it’s only this one.