refactor: split very long statements [skip ci]

This commit is contained in:
jeefo 2025-02-28 05:44:52 +03:00
commit f9aa608a6a
No known key found for this signature in database
GPG key ID: D696786B81B667C8
6 changed files with 38 additions and 8 deletions

View file

@ -586,7 +586,12 @@ void Bot::setAimDirection () {
}
const bool horizontalMovement = (m_pathFlags & NodeFlag::Ladder) || isOnLadder ();
if (m_numEnemiesLeft > 0 && m_canChooseAimDirection && m_seeEnemyTime + 4.0f < game.time () && m_currentNodeIndex != kInvalidNodeIndex && !horizontalMovement) {
if (m_numEnemiesLeft > 0
&& m_canChooseAimDirection
&& m_seeEnemyTime + 4.0f < game.time ()
&& m_currentNodeIndex != kInvalidNodeIndex
&& !horizontalMovement) {
const auto dangerIndex = practice.getIndex (m_team, m_currentNodeIndex, m_currentNodeIndex);
if (graph.exists (dangerIndex)