ShootPos and SearchInSphere

Hello i am currently coding a SWEP that halos illegals entities such as printers etc but i have not coded that part it should just give halo out the radius of the sphere.i tried this it gives this error;


[ERROR] addons/scanner/lua/weapons/shared.lua:31: attempt to index global 'halo'
 (a nil value)
  1. unknown - addons/scanner/lua/weapons/shared.lua:31

My code is here ( the halo part)


	local usr = self.Owner:GetShootPos()
print(usr)
	  halo.Add( ents.FindInSphere(usr, 500), Color( 255, 0, 0 ), 0, 0, 2, true, true )
	self.Weapon:SetNextPrimaryFire( CurTime() + 5 )


halo.Add is clientside only

So how can i do this ?
whats wrong if its cs only all my codes comepononets are shared ?

if ( CLIENT ) then
– do client code
end

solved by my self but thanks mate !