fix: crash when enabling hitbox aiming between rounds
This commit is contained in:
parent
1684da81cd
commit
40dc667e03
3 changed files with 9 additions and 4 deletions
|
|
@ -1562,7 +1562,12 @@ void Bot::newRound () {
|
|||
m_hostages.clear ();
|
||||
|
||||
if (cv_use_hitbox_enemy_targeting) {
|
||||
m_hitboxEnumerator->reset ();
|
||||
if (m_hitboxEnumerator) {
|
||||
m_hitboxEnumerator->reset ();
|
||||
}
|
||||
else {
|
||||
m_hitboxEnumerator = cr::makeUnique <PlayerHitboxEnumerator> ();
|
||||
}
|
||||
}
|
||||
|
||||
m_approachingLadderTimer.invalidate ();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue