I figured out another way to use this and after some time I also found out how to use this for purpose, thanks for helping me out though!
For the other interested people:
Code:
public monk_heal(id)
{
new MaxHealth = race_heal[player_class[id]]+player_strength[id]*2
new healRadius=get_cvar_num("diablo_monk_distance")
new specialHeal=get_cvar_num("diablo_monk_heal")
new location[3], allyOrigin[3], distanceBetween
if (is_user_alive(id)) {
get_user_origin(id, location) // Find out where Medic is
for(new i = 0; i < 33; i++) {
if ( (is_user_alive(i) && get_user_team(id)==get_user_team(i)) ) {
get_user_origin(i, allyOrigin)
// Check to see if any ally are within radius
distanceBetween=get_distance(location, allyOrigin)
if ( distanceBetween < healRadius && get_user_health(id) <= MaxHealth ) {
set_user_health(i, get_user_health(i)+specialHeal )
}
}
}
}
}