This commit is contained in:
2026-03-31 10:59:30 +03:00
parent 0301242716
commit f457aa2a11
4 changed files with 180 additions and 9 deletions

View File

@@ -102,4 +102,24 @@ net.Receive("ixWhitelistMenuApply", function(_, client)
client:Notify("Роль назначена: " .. target:Name())
target:Notify("Вам назначена новая роль!")
-- Логирование в систему серверных логов
local serverlogs = ix.plugin.list["serverlogs"]
if serverlogs then
local factionName = faction.name or "Неизвестно"
local podrName = faction.Podr[podrID] and faction.Podr[podrID].name or tostring(podrID)
local specName = faction.Spec[specID] and faction.Spec[specID].name or tostring(specID)
local rankName = targetRanks[rankID] and targetRanks[rankID].name or tostring(rankID)
local message = string.format("%s изменил роль игроку %s: Фракция: %s, Подразделение: %s, Спец: %s, Ранг: %s",
client:Nick(), target:Nick(), factionName, podrName, specName, rankName)
serverlogs:AddLog("CHARACTER_WHITELIST", message, target, {
admin = client:SteamID(),
faction = factionName,
podr = podrName,
spec = specName,
rank = rankName
})
end
end)