Hi, here I am again.
I really didn't think I would have any other problem, but I didn't expect to have a problem with something stupid I can't resolve:
(This whole code is in ham_takedamage PRE)
PHP Code:
if(farpiece[attacker])
{
if(get_user_weapon(attacker) == CSW_AK47 && damagetype & DMG_BULLET)
{
if(get_pdata_int(victim, 75) == HIT_HEAD)
{
SetHamParamFloat(4, get_pcvar_float(farpiece_damagehs))
}
else
{
SetHamParamFloat(4, get_pcvar_float(farpiece_damage))
}
}
}
if(level[id] >= 1)
{
SetHamParamFloat(4, damage*leveldamage)
}
So basically I have a weapon that deals 67dmg, called farpiece, and when player reaches level one, all dmg he deals will be increased by 10%. The problem is that I thought the Float:damage receives the damage the farpiece does, and increases it by 10%, however it doesn't take farpiece's damage, it only takes damage that the original gun makes and totally ignores the farpiece... I thought this is going to be easy to resolve, but... it's ripping my guts out. Yeah I can add the damage right in the farpiece damage, but I also need the damage to be increased for other casual guns, but I'd have to add SetHamParamFloat that receives damage, but again, it totally disables farpiece's damage, I couldn't find any solution for this queer issue, so how do I fix it?