diff options
Diffstat (limited to 'src/decblupi.cxx')
-rw-r--r-- | src/decblupi.cxx | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/src/decblupi.cxx b/src/decblupi.cxx index e29513a..1475e4a 100644 --- a/src/decblupi.cxx +++ b/src/decblupi.cxx @@ -200,7 +200,7 @@ void CDecor::BlupiDelete (Sint32 rank) { m_blupi[rank].bExist = false; - this->m_pSound->StopSound(true, rank); + this->m_pSound->StopSound (true, rank); if ( !m_bBuild && // phase de jeu ? @@ -237,7 +237,7 @@ CDecor::BlupiKill (Sint32 exRank, Point cel, Sint32 type) if (type == 0) // explosion ? { m_blupi[rank].bExist = false; // mort instantannée - this->m_pSound->StopSound(true, rank); + this->m_pSound->StopSound (true, rank); } if (type == 1) // électro ? @@ -2477,26 +2477,26 @@ CDecor::BlupiNextAction (Sint32 rank) * direction and a second from the other direction. Without this check, the * object is duplicated. */ - for (int i = 0; i < MAXBLUPI; ++i) - { - if (rank == i || !m_blupi[i].bExist) - continue; - - if ( - (m_blupi[rank].goalAction == EV_ACTION_CARRY || + if ((m_blupi[rank].goalAction == EV_ACTION_CARRY || m_blupi[rank].goalAction == EV_ACTION_EAT || - m_blupi[rank].goalAction == EV_ACTION_DRINK) && - (m_blupi[i].goalAction == EV_ACTION_CARRY2 || - m_blupi[i].goalAction == EV_ACTION_EAT2 || - m_blupi[i].goalAction == EV_ACTION_DRINK2) && - m_blupi[rank].goalHili.x == m_blupi[i].goalHili.x && - m_blupi[rank].goalHili.y == m_blupi[i].goalHili.y) + m_blupi[rank].goalAction == EV_ACTION_DRINK)) + for (int i = 0; i < MAXBLUPI; ++i) { - BlupiInitAction (i, ACTION_STOP); - GoalStop (i, true); - return false; + if (rank == i || !m_blupi[i].bExist) + continue; + + if ( + (m_blupi[i].goalAction == EV_ACTION_CARRY2 || + m_blupi[i].goalAction == EV_ACTION_EAT2 || + m_blupi[i].goalAction == EV_ACTION_DRINK2) && + m_blupi[rank].goalHili.x == m_blupi[i].goalHili.x && + m_blupi[rank].goalHili.y == m_blupi[i].goalHili.y) + { + BlupiInitAction (i, ACTION_STOP); + GoalStop (i, true); + return false; + } } - } /* Prevent Blupi to take a trap when an enemy is already captured. */ if (m_blupi[rank].perso == 0 && m_blupi[rank].action == ACTION_CARRY) |