All pastes #441324 Raw Edit

SteveUK

public lua v1 · immutable
·published 2007-04-15 16:58 UTC
rendered paste body
function SWEP:PrimaryAttack()	ent_trace = self.Owner:GetEyeTrace()	ent_hit = ent_trace.Entity		if( ent_hit:IsValid() and ent_hit:IsPlayer() ) then		health = ent_hit:GetHealth()		heal_max = ent_hit:GetMaxHealth()				newhealth = health + 10 -- change value here				if( newhealth > heal_max ) then			ent_hit:SetHealth( heal_max )		else			ent_hit:SetHealth( newhealth )		end	end	end