Last night i also searching for radius damage stock and i found this 1 by OT:
PHP Code:
stock HamRadiusDamage(ent, Float:radius, Float:damage, bits)
{
new target = -1, Float:origin[3]
pev(ent, pev_origin, origin)
while(( target = find_ent_in_sphere(target, origin, radius) ))
{
static Float:o[3]
pev(target, pev_origin, o)
xs_vec_sub(origin, o, o)
// Recheck if the entity is in radius
if (xs_vec_len(o) > radius)
continue
Ham_ExecDamageB(target, ent, pev(ent, pev_owner), damage * (xs_vec_len(o) / radius), HIT_GENERIC, bits)
}
}
remember to define these 2 include in your sma:
PHP Code:
#include <hamsandwich>
#include <xs>
Didn't test yet but i think it working.
__________________