All pastes #733891 Raw Edit

Miscellany

public text v1 · immutable
·published 2007-10-12 04:54 UTC
rendered paste body
local SCAN_RANGE = 350
function ENT:Scan( )
	local scan_ents = ents.FindInSphere(self.Entity:GetPos(), SCAN_RANGE)

        local LHP = 10 ^ 63
	for k, v in pairs(scan_ents) do
		if v:Health() < LHP then
			LHP = v:Health()
			return v
		end
	end
end