void DamageTaken(Unit* pDoneBy, uint32& uiDamage) { if (uiDamage > me->GetHealth() && !phase3){ uiDamage = 0; if (phase2) StartPhase3(); if (phase1) StartPhase2(); } }
void DamageTaken(Unit* pDoneBy, uint32& uiDamage) { if ((uiDamage > m_creature->GetHealth() || m_creature->GetHealth()/m_creature->GetHealth() <= 0.1 ) && !phase3){ uiDamage = 0; if (phase2) StartPhase3(); if (phase1) StartPhase2(); } }
void JustDied(Unit* pKiller) { if (!m_pInstance) return; if (phase3) { m_pInstance->SetData(TYPE_BLACK_KNIGHT, DONE); } if (phase2) if (!m_creature->isAlive()) { m_creature->Respawn(); StartPhase3(); } if (phase1) if (!m_creature->isAlive()) { m_creature->Respawn(); StartPhase2(); } }
void JustDied(Unit* pKiller) { if (!pInstance) return; if (phase3) { SetInstanceData(TYPE_BLACK_KNIGHT, DONE); GiveEmblemsToGroup(m_bIsRegularMode ? CONQUETE : 0,1,true); GiveRandomReward(); } if (phase2) if (!me->isAlive()) { me->Respawn(); StartPhase3(); } if (phase1) if (!me->isAlive()) { me->Respawn(); StartPhase2(); } }