View Single Post
Author Message
MolaMASTER999
Junior Member
Join Date: Nov 2021
Location: Aceh, Indonesia
Old 11-23-2021 , 12:51   Weapon damage won't multiplier, Ham_TakeDamage, SetHamParamFloat
Reply With Quote #1

May anyone help me? This code won't multiplier the damage of weapon when I choose human class on CS 1.6 Zombie Plague. Is there anything wrong?

Code:
public Ham_PlayerTakeDamage(iVictim, iInflictor, iAttacker, Float:flDamage, iDmgBits)
{        
	if (iDmgBits & DMG_FALL) 
	{
	if (g_nofalldamage[iVictim] == true)
		{
			return HAM_SUPERCEDE
		}
	}
	if(g_dmgx[iAttacker])
		{
		SetHamParamFloat(4,(flDamage*1.1)) 
		return HAM_HANDLED  
		}
	if(g_samurai[iAttacker] && g_iCurrentWeapon[iAttacker] == CSW_KNIFE)
		{
		SetHamParamFloat(4,(flDamage*2.0)) 
		return HAM_HANDLED  
		}
	if(g_snip[iAttacker] && g_iCurrentWeapon[iAttacker] == CSW_AWP || g_iCurrentWeapon[iAttacker] == CSW_SCOUT)
		{
		SetHamParamFloat(4,(flDamage*2.0)) 
		return HAM_HANDLED  
		}
	return HAM_IGNORED
}

Last edited by MolaMASTER999; 12-02-2021 at 02:47.
MolaMASTER999 is offline
Send a message via Skype™ to MolaMASTER999