From fd613ebed70e123bc016d3cf1060b752b2b7b1fd Mon Sep 17 00:00:00 2001 From: Roman Chistokhodov Date: Sat, 29 Apr 2023 17:13:56 +0300 Subject: [PATCH] Fix missing breaks. Fix #370 (#371) --- dlls/gearbox/fgrunt.cpp | 2 +- dlls/gearbox/strooper.cpp | 2 +- dlls/gearbox/voltigore.cpp | 19 +++++++++++-------- 3 files changed, 13 insertions(+), 10 deletions(-) diff --git a/dlls/gearbox/fgrunt.cpp b/dlls/gearbox/fgrunt.cpp index c4a28fd4..4582f67b 100644 --- a/dlls/gearbox/fgrunt.cpp +++ b/dlls/gearbox/fgrunt.cpp @@ -1946,7 +1946,7 @@ void CHFGrunt :: HandleAnimEvent( MonsterEvent_t *pEvent ) SENTENCEG_PlayRndSz(ENT(pev), SentenceByNumber(FGRUNT_SENT_ALERT), FGRUNT_SENTENCE_VOLUME, ATTN_NORM, 0, m_voicePitch); JustSpoke(); } - + break; } default: diff --git a/dlls/gearbox/strooper.cpp b/dlls/gearbox/strooper.cpp index e06a6b99..e9a0660f 100644 --- a/dlls/gearbox/strooper.cpp +++ b/dlls/gearbox/strooper.cpp @@ -390,7 +390,7 @@ void CStrooper::HandleAnimEvent(MonsterEvent_t *pEvent) SENTENCEG_PlayRndSz(ENT(pev), "ST_ALERT", STROOPER_SENTENCE_VOLUME, STROOPER_ATTN, 0, m_voicePitch); JustSpoke(); } - + break; } default: diff --git a/dlls/gearbox/voltigore.cpp b/dlls/gearbox/voltigore.cpp index b728ea62..fdb12aad 100644 --- a/dlls/gearbox/voltigore.cpp +++ b/dlls/gearbox/voltigore.cpp @@ -1010,16 +1010,19 @@ void CVoltigore::StartTask(Task_t *pTask) } break; case TASK_VOLTIGORE_GET_PATH_TO_ENEMY_CORPSE: - UTIL_MakeVectors( pev->angles ); - if( BuildRoute( m_vecEnemyLKP - gpGlobals->v_forward * 50, bits_MF_TO_LOCATION, NULL ) ) { - TaskComplete(); - } - else - { - ALERT( at_aiconsole, "VoltigoreGetPathToEnemyCorpse failed!!\n" ); - TaskFail(); + UTIL_MakeVectors( pev->angles ); + if( BuildRoute( m_vecEnemyLKP - gpGlobals->v_forward * 50, bits_MF_TO_LOCATION, NULL ) ) + { + TaskComplete(); + } + else + { + ALERT( at_aiconsole, "VoltigoreGetPathToEnemyCorpse failed!!\n" ); + TaskFail(); + } } + break; default: CBaseMonster::StartTask(pTask); break;