Kick reason

This commit is contained in:
Vortrex
2022-06-12 09:20:18 -05:00
parent 519928bf6b
commit 230a623210

View File

@@ -394,30 +394,6 @@ function getClientFromSyncerId(syncerId) {
// ===========================================================================
function triggerWebHook(messageString, serverId = getServerId(), type = VRR_DISCORD_WEBHOOK_LOG) {
if(!getGlobalConfig().discord.webhook.enabled) {
return false;
}
let tempURL = getGlobalConfig().discord.webhook.webhookBaseURL;
tempURL = tempURL.replace("{0}", encodeURI(messageString));
tempURL = tempURL.replace("{1}", serverId);
tempURL = tempURL.replace("{2}", type);
tempURL = tempURL.replace("{3}", getGlobalConfig().discord.webhook.pass);
httpGet(
tempURL,
"",
function(data) {
},
function(data) {
}
);
}
// ===========================================================================
function clearTemporaryVehicles() {
let vehicles = getElementsByType(ELEMENT_VEHICLE);
for (let i in vehicles) {
@@ -452,6 +428,7 @@ function clearTemporaryPeds() {
function kickAllClients() {
getClients().forEach((client) => {
getPlayerData(client).customDisconnectReason = `Kicked - All clients are being disconnected`;
disconnectPlayer(client);
})
}