attacker is a clientID right? When I shoot a bot in CS: S (me being the attacker in this case), GetClientWeapon reports an invalid client id = 0. I don't see how *my* client id could equal 0. Is there a way to get the weapon name from inflictor? I've tried GetEntityNetClass() and GetEdictClassname() to no avail.
Code:
public Action:TakeDamageFunction(client, &inflictor, &attacker, &Float:Damage, &DamageType, &AmmoType)
{
new String:WeaponName[256];
GetClientWeapon(attacker, WeaponName, sizeof(WeaponName));
PrintToChatAll("Weapon is %s", WeaponName);
return Plugin_Changed; // tells the extension something was changed use the new value!
}