From 6956e9680ef7be88df1c94fefab640c44c48b365 Mon Sep 17 00:00:00 2001 From: John Kvalevog Date: Thu, 27 Feb 2025 16:44:01 -0800 Subject: [PATCH] Fix Spy bots using human voice lines in MvM Spy bots should use Spy.MVM_TeaseVictim instead of Spy.TeaseVictim. The soundscript Spy.MVM_TeaseVictim will also need to be corrected as some of the sound paths are incorrect. Fixes: https://github.com/ValveSoftware/Source-1-Games/issues/4794 --- src/game/server/tf/bot/behavior/spy/tf_bot_spy_hide.cpp | 9 ++++++++- src/game/server/tf/tf_player.cpp | 1 + 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/game/server/tf/bot/behavior/spy/tf_bot_spy_hide.cpp b/src/game/server/tf/bot/behavior/spy/tf_bot_spy_hide.cpp index 2a35b3138..914b2d959 100644 --- a/src/game/server/tf/bot/behavior/spy/tf_bot_spy_hide.cpp +++ b/src/game/server/tf/bot/behavior/spy/tf_bot_spy_hide.cpp @@ -70,7 +70,14 @@ ActionResult< CTFBot > CTFBotSpyHide::Update( CTFBot *me, float interval ) if ( m_talkTimer.IsElapsed() ) { m_talkTimer.Start( RandomFloat( 5.0f, 10.0f ) ); - me->EmitSound( "Spy.TeaseVictim" ); + if ( TFGameRules()->IsMannVsMachineMode() && me->GetTeamNumber() == TF_TEAM_PVE_INVADERS ) + { + me->EmitSound( "Spy.MVM_TeaseVictim" ); + } + else + { + me->EmitSound( "Spy.TeaseVictim" ); + } } if ( m_isAtGoal ) diff --git a/src/game/server/tf/tf_player.cpp b/src/game/server/tf/tf_player.cpp index 6864fd442..0881d2491 100644 --- a/src/game/server/tf/tf_player.cpp +++ b/src/game/server/tf/tf_player.cpp @@ -2802,6 +2802,7 @@ void CTFPlayer::PrecacheMvM() PrecacheScriptSound( "MVM.DeployBombGiant" ); PrecacheScriptSound( "Weapon_Upgrade.ExplosiveHeadshot" ); PrecacheScriptSound( "Spy.MVM_Chuckle" ); + PrecacheScriptSound( "Spy.MVM_TeaseVictim" ); PrecacheScriptSound( "MVM.Robot_Engineer_Spawn" ); PrecacheScriptSound( "MVM.Robot_Teleporter_Deliver" ); PrecacheScriptSound( "MVM.MoneyPickup" );