Update tf_weapon_bottle.cpp

This commit is contained in:
Bitl 2025-07-27 09:48:48 -07:00 committed by EricS-Valve
parent 23e6b735a8
commit bae343a336
1 changed files with 10 additions and 3 deletions

View File

@ -254,12 +254,19 @@ void CTFStickBomb::Smack( void )
TE_TFExplosion( filter, 0.0f, explosion, Vector(0,0,1), TF_WEAPON_GRENADELAUNCHER, pTFPlayer->entindex(), -1, SPECIAL1, iCustomParticleIndex );
int dmgType = DMG_BLAST | DMG_USEDISTANCEMOD;
int dmgType = DMG_BLAST | DMG_USEDISTANCEMOD | DMG_MELEE;
if ( IsCurrentAttackACrit() )
dmgType |= DMG_CRITICAL;
float flDamage = 75.0f;
CALL_ATTRIB_HOOK_FLOAT( flDamage, mult_dmg );
CTakeDamageInfo info( pTFPlayer, pTFPlayer, this, explosion, explosion, 75.0f, dmgType, TF_DMG_CUSTOM_STICKBOMB_EXPLOSION, &explosion );
CTFRadiusDamageInfo radiusinfo( &info, explosion, 100.f );
CTakeDamageInfo info( pTFPlayer, pTFPlayer, this, explosion, explosion, flDamage, dmgType, TF_DMG_CUSTOM_STICKBOMB_EXPLOSION, &explosion );
float flRadius = 100.f;
CALL_ATTRIB_HOOK_FLOAT( flRadius, mult_explosion_radius );
CTFRadiusDamageInfo radiusinfo( &info, explosion, flRadius );
TFGameRules()->RadiusDamage( radiusinfo );
}
#endif