• game addon needed
    2 replies, posted
Does anyone know where I can get an addon so that whenever a person is godded, they cannot kill anyone else? (extras) this part is not needed, but would be nice. I'd like it so that if they DO try to kill someone else, it punishes them and lets everyone else know what they tried to do.
You could do something like this, not sure if my code is entirely accurate [code] function GM:ScalePlayerDamage( ply, hitgroup, dmginfo ) local _attacker = dmginfo:GetAttacker() if(_attacker:IsPlayer() && _attacker:HasGodMode()) then dmginfo:SetDamage(0) _attacker:ViewPunch( Angle( -10, 0, 0 ) ) --PrintMessage(HUD_PRINTTALK, _attacker:Name() .. " attacked somebody with God Mode enabled") end end [/code]
[url]https://dl.dropboxusercontent.com/u/26074909/tutoring/_systems/simple_godmode_system/sv_godmode.lua.html[/url] [url]https://dl.dropboxusercontent.com/u/26074909/tutoring/_systems/simple_godmode_system/sv_godmode_prevent_godded_from_damaging_others.lua[/url]
Sorry, you need to Log In to post a reply to this thread.