26 lines
1.3 KiB
Lua
26 lines
1.3 KiB
Lua
-- SteakScan, a independent T-Test
|
|
hook.Add("PostDrawOpaqueRenderables", "wire_animations_idle", function()
|
|
if GAMEMODE.round_state != ROUND_ACTIVE then
|
|
for _,v in pairs(player.GetAll()) do
|
|
v.HatTraitor = nil
|
|
end
|
|
return
|
|
end
|
|
for _,v in pairs( ents.GetAll() ) do
|
|
if v and IsValid(v) then
|
|
if table.HasValue(v.CanBuy, 1) then
|
|
local pl = v.Owner
|
|
if pl and IsValid(pl) and pl:IsTerror() and not pl.HatTraitor then
|
|
if not pl:IsDetective() then
|
|
if not pl.HatTraitor then
|
|
-- This server has a halo-effect, so lets trigger it.
|
|
pl.sb_tag = {txt = "sb_tag_kill", color = Color(255, 0, 0, 255)}
|
|
pl.HatTraitor = true
|
|
chat.AddText( pl, Color(255,125,0), " is a ",Color(255,0,0), "TRAITOR",Color(255,125,0), " with a ",Color(255,0,0),v:GetClass().."!")
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end) |