Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/game/client/tf/c_tf_player.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1301,6 +1301,7 @@ bool C_TFRagdoll::IsDecapitation()
{
return (cl_ragdoll_fade_time.GetFloat() > 5.f) &&
((m_iDamageCustom == TF_DMG_CUSTOM_DECAPITATION)
|| (m_iDamageCustom == TF_DMG_CUSTOM_HONORBOUND)
|| (m_iDamageCustom == TF_DMG_CUSTOM_TAUNTATK_BARBARIAN_SWING)
|| (m_iDamageCustom == TF_DMG_CUSTOM_DECAPITATION_BOSS)
|| (m_iDamageCustom == TF_DMG_CUSTOM_HEADSHOT_DECAPITATION)
Expand Down Expand Up @@ -10118,6 +10119,7 @@ bool C_TFPlayer::InSameDisguisedTeam( CBaseEntity *pEnt )
static bool IsDecapitationCustomDamageType( int iCustomDamageType )
{
return iCustomDamageType == TF_DMG_CUSTOM_DECAPITATION
|| iCustomDamageType == TF_DMG_CUSTOM_HONORBOUND
|| iCustomDamageType == TF_DMG_CUSTOM_TAUNTATK_BARBARIAN_SWING
|| iCustomDamageType == TF_DMG_CUSTOM_DECAPITATION_BOSS
|| iCustomDamageType == TF_DMG_CUSTOM_MERASMUS_DECAPITATION;
Expand Down
1 change: 1 addition & 0 deletions src/game/server/vscript_server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3370,6 +3370,7 @@ DECLARE_SCRIPT_CONST( ETFDmgCustom, TF_DMG_CUSTOM_SLAP_KILL )
DECLARE_SCRIPT_CONST( ETFDmgCustom, TF_DMG_CUSTOM_CROC )
DECLARE_SCRIPT_CONST( ETFDmgCustom, TF_DMG_CUSTOM_TAUNTATK_GASBLAST )
DECLARE_SCRIPT_CONST( ETFDmgCustom, TF_DMG_CUSTOM_AXTINGUISHER_BOOSTED )
DECLARE_SCRIPT_CONST( ETFDmgCustom, TF_DMG_CUSTOM_HONORBOUND )
DECLARE_SCRIPT_CONST( ETFDmgCustom, TF_DMG_CUSTOM_TAUNTATK_TRICKSHOT )
DECLARE_SCRIPT_CONST( ETFDmgCustom, TF_DMG_CUSTOM_END )
REGISTER_SCRIPT_CONST_TABLE( ETFDmgCustom )
Expand Down
14 changes: 7 additions & 7 deletions src/game/shared/tf/achievements_tf_demoman.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ class CAchievementTFDemoman_DecapitateCloakedSpy : public CBaseTFAchievement
if ( pTFVictim && pTFVictim->IsPlayerClass( TF_CLASS_SPY ) && pTFVictim->m_Shared.InCond( TF_COND_STEALTHED ) )
{
int customdmg = event->GetInt( "customkill" );
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION )
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION || customdmg == TF_DMG_CUSTOM_HONORBOUND )
{
IncrementCount();
}
Expand Down Expand Up @@ -270,7 +270,7 @@ class CAchievementTFDemoman_DecapitatePlayers : public CBaseTFAchievement
return;

int customdmg = event->GetInt( "customkill" );
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION )
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION || customdmg == TF_DMG_CUSTOM_HONORBOUND )
{
IncrementCount();
}
Expand Down Expand Up @@ -313,7 +313,7 @@ class CAchievementTFDemoman_DecapitatePlayersFast : public CBaseTFAchievement
return;

int customdmg = event->GetInt( "customkill" );
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION )
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION || customdmg == TF_DMG_CUSTOM_HONORBOUND )
{
if ( (m_iTimelyDecapitations == 0) || ((m_iTimelyDecapitations > 0) && (gpGlobals->curtime < m_flLastDecapTime + 10.f)) )
{
Expand Down Expand Up @@ -805,7 +805,7 @@ class CAchievementTFDemoman_DecapitateEqualizer : public CBaseTFAchievement
if ( pShovel && (pShovel->GetShovelType() == SHOVEL_DAMAGE_BOOST) )
{
int customdmg = event->GetInt( "customkill" );
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION )
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION || customdmg == TF_DMG_CUSTOM_HONORBOUND )
{
IncrementCount();
}
Expand Down Expand Up @@ -833,7 +833,7 @@ class CAchievementTFDemoman_DecapitateNemesis : public CBaseTFAchievement
if ( pTFVictim && pTFVictim->IsNemesisOfLocalPlayer() )
{
int customdmg = event->GetInt( "customkill" );
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION )
if ( customdmg == TF_DMG_CUSTOM_DECAPITATION || customdmg == TF_DMG_CUSTOM_HONORBOUND )
{
IncrementCount();
}
Expand Down Expand Up @@ -1035,7 +1035,8 @@ class CAchievementTFDemoman_CritSwordKill : public CBaseTFAchievement
{
// was this a charge kill with the sword?
int nDamageBits = event->GetInt( "damagebits" );
if ( (nDamageBits & DMG_CRITICAL) && (event->GetInt( "customkill" ) == TF_DMG_CUSTOM_DECAPITATION) )
int customdmg = event->GetInt( "customkill" );
if ( (nDamageBits & DMG_CRITICAL) && ( customdmg == TF_DMG_CUSTOM_DECAPITATION || customdmg == TF_DMG_CUSTOM_HONORBOUND ) )
{
IncrementCount();
}
Expand Down Expand Up @@ -1883,4 +1884,3 @@ DECLARE_ACHIEVEMENT( CAchievementTFDemoman_ChargeKillChargingDemo, ACHIEVEMENT_T
#endif // CLIENT_DLL



4 changes: 2 additions & 2 deletions src/game/shared/tf/tf_gamerules.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7283,8 +7283,8 @@ float CTFGameRules::ApplyOnDamageAliveModifyRules( const CTakeDamageInfo &info,
// Stomp flRealDamage with resist adjusted values
flRealDamage = flDamageBase + flDamageBonus;

// Some Powerups apply a damage multiplier. Backstabs are immune to resist protection
if ( ( pVictim && info.GetDamageCustom() != TF_DMG_CUSTOM_BACKSTAB ) )
// Some Powerups apply a damage multiplier. Backstabs and honor-bound kills are immune to resist protection
if ( pVictim && info.GetDamageCustom() != TF_DMG_CUSTOM_BACKSTAB && info.GetDamageCustom() != TF_DMG_CUSTOM_HONORBOUND )
{
// Plague bleed damage is immune from resist calculation
if ( ( !pVictim->m_Shared.InCond( TF_COND_PLAGUE ) && info.GetDamageCustom() != TF_DMG_CUSTOM_BLEEDING ) )
Expand Down
2 changes: 1 addition & 1 deletion src/game/shared/tf/tf_player_shared.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13383,6 +13383,7 @@ int CTFPlayerShared::GetSequenceForDeath( CBaseAnimating* pRagdoll, bool bBurnin
{
case TF_DMG_CUSTOM_HEADSHOT_DECAPITATION:
case TF_DMG_CUSTOM_TAUNTATK_BARBARIAN_SWING:
case TF_DMG_CUSTOM_HONORBOUND:
case TF_DMG_CUSTOM_DECAPITATION:
case TF_DMG_CUSTOM_HEADSHOT:
iDeathSeq = pRagdoll->LookupSequence( "primary_death_headshot" );
Expand Down Expand Up @@ -14731,4 +14732,3 @@ bool CTFPlayer::IsHelpmeButtonPressed() const
{
return m_flHelpmeButtonPressTime != 0.f;
}

3 changes: 2 additions & 1 deletion src/game/shared/tf/tf_shareddefs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -913,6 +913,7 @@ const char *g_szSpecialDamageNames[] =
"TF_DMG_CUSTOM_CROC",
"TF_DMG_CUSTOM_TAUNTATK_GASBLAST",
"TF_DMG_CUSTOM_AXTINGUISHER_BOOSTED",
"TF_DMG_CUSTOM_HONORBOUND",
"TF_DMG_CUSTOM_KRAMPUS_MELEE",
"TF_DMG_CUSTOM_KRAMPUS_RANGED",
"TF_DMG_CUSTOM_TAUNTATK_TRICKSHOT",
Expand Down Expand Up @@ -1462,7 +1463,7 @@ void LoadObjectInfos( IBaseFileSystem *pFileSystem )
// Does it make sense to call the below Steam API so it'll force a validation next startup time?
// Need to verify it's real corruption and not someone dorking around with their objects.txt file...
//
// From Martin Otten: If you have a file on disc and you�re 100% sure it�s
// From Martin Otten: If you have a file on disc and you�re 100% sure it�s
// corrupt, call ISteamApps::MarkContentCorrupt( false ), before you shutdown
// the game. This will cause a content validation in Steam.

Expand Down
1 change: 1 addition & 0 deletions src/game/shared/tf/tf_shareddefs.h
Original file line number Diff line number Diff line change
Expand Up @@ -1262,6 +1262,7 @@ enum ETFDmgCustom
TF_DMG_CUSTOM_CROC,
TF_DMG_CUSTOM_TAUNTATK_GASBLAST,
TF_DMG_CUSTOM_AXTINGUISHER_BOOSTED,
TF_DMG_CUSTOM_HONORBOUND,
TF_DMG_CUSTOM_KRAMPUS_MELEE,
TF_DMG_CUSTOM_KRAMPUS_RANGED,
TF_DMG_CUSTOM_TAUNTATK_TRICKSHOT,
Expand Down
1 change: 1 addition & 0 deletions src/game/shared/tf/tf_weapon_sword.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -562,6 +562,7 @@ float CTFKatana::GetMeleeDamage( CBaseEntity *pTarget, int* piDamageType, int* p
if ( pTFPlayerTarget->GetActiveTFWeapon() && pTFPlayerTarget->GetActiveTFWeapon()->IsHonorBound() )
{
fDamage = MAX( fDamage, pTFPlayerTarget->GetHealth() * 3 );
*piCustomDamage = TF_DMG_CUSTOM_HONORBOUND;
*piDamageType |= DMG_DONT_COUNT_DAMAGE_TOWARDS_CRIT_RATE;
}
}
Expand Down