This forum is a public forum so you can't always control everybody.
I'm guessing Emp probably assumed you "didn't know what you were doing" because you completely ignored wrecked's post about not needing that variable (or even most of the code given). The example given was just that, an example, and can not be taken completely as a working function for your specific case. You have to use only parts of the examples given.
The part that actually does the damage is this:
PHP Code:
for (new i=0; i < numfound; i++)
{
new pid = entlist[i];
if (!is_user_alive(pid) || get_user_team(attacker) == get_user_team(pid))
continue;
ExecuteHam(Ham_TakeDamage, pid, ent, attacker, 350.0, 1);
}
It does not affect teammates and any damage delt will be as if it was coming from the player "attacker" using the weapon "ent".
__________________