Merge
--HG-- branch : trunk
This commit is contained in:
@@ -265,19 +265,17 @@ struct TRINITY_DLL_DECL boss_svala_sorrowgraveAI : public ScriptedAI
|
|||||||
if (uiCallFlamesTimer < diff)
|
if (uiCallFlamesTimer < diff)
|
||||||
{
|
{
|
||||||
Unit* pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0);
|
Unit* pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0);
|
||||||
while (pTarget && pTarget->GetTypeId() != TYPEID_PLAYER)
|
if (pTarget && pTarget->GetTypeId() != TYPEID_PLAYER)
|
||||||
pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0);
|
{
|
||||||
if (pTarget)
|
|
||||||
DoCast(pTarget, SPELL_CALL_FLAMES);
|
DoCast(pTarget, SPELL_CALL_FLAMES);
|
||||||
uiCallFlamesTimer = 8000 + rand()%4000;
|
uiCallFlamesTimer = 8000 + rand()%4000;
|
||||||
|
}
|
||||||
} else uiCallFlamesTimer -= diff;
|
} else uiCallFlamesTimer -= diff;
|
||||||
|
|
||||||
if (uiRitualOfSwordTimer < diff)
|
if (uiRitualOfSwordTimer < diff)
|
||||||
{
|
{
|
||||||
pSacrificeTarget = SelectUnit(SELECT_TARGET_RANDOM, 0);
|
pSacrificeTarget = SelectUnit(SELECT_TARGET_RANDOM, 0);
|
||||||
while (pSacrificeTarget && pSacrificeTarget->GetTypeId() != TYPEID_PLAYER)
|
if (pSacrificeTarget && pSacrificeTarget->GetTypeId() != TYPEID_PLAYER)
|
||||||
pSacrificeTarget = SelectUnit(SELECT_TARGET_RANDOM, 0);
|
|
||||||
if (pSacrificeTarget)
|
|
||||||
{
|
{
|
||||||
DoScriptText(RAND(SAY_SACRIFICE_PLAYER_1,SAY_SACRIFICE_PLAYER_2,SAY_SACRIFICE_PLAYER_3,SAY_SACRIFICE_PLAYER_4,SAY_SACRIFICE_PLAYER_5),m_creature);
|
DoScriptText(RAND(SAY_SACRIFICE_PLAYER_1,SAY_SACRIFICE_PLAYER_2,SAY_SACRIFICE_PLAYER_3,SAY_SACRIFICE_PLAYER_4,SAY_SACRIFICE_PLAYER_5),m_creature);
|
||||||
DoCast(pSacrificeTarget,SPELL_RITUAL_OF_THE_SWORD);
|
DoCast(pSacrificeTarget,SPELL_RITUAL_OF_THE_SWORD);
|
||||||
@@ -289,8 +287,9 @@ struct TRINITY_DLL_DECL boss_svala_sorrowgraveAI : public ScriptedAI
|
|||||||
if (pRitualChanneler[i] = m_creature->SummonCreature(CREATURE_RITUAL_CHANNELER, RitualChannelerLocations[i].x, RitualChannelerLocations[i].y, RitualChannelerLocations[i].z, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 360000))
|
if (pRitualChanneler[i] = m_creature->SummonCreature(CREATURE_RITUAL_CHANNELER, RitualChannelerLocations[i].x, RitualChannelerLocations[i].y, RitualChannelerLocations[i].z, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 360000))
|
||||||
if (mob_ritual_channelerAI *pChannelerAI = CAST_AI(mob_ritual_channelerAI,pRitualChanneler[i]))
|
if (mob_ritual_channelerAI *pChannelerAI = CAST_AI(mob_ritual_channelerAI,pRitualChanneler[i]))
|
||||||
pChannelerAI->AttackStartNoMove(pSacrificeTarget);
|
pChannelerAI->AttackStartNoMove(pSacrificeTarget);
|
||||||
}
|
|
||||||
uiRitualOfSwordTimer = 18000 + rand()%4000;
|
uiRitualOfSwordTimer = 18000 + rand()%4000;
|
||||||
|
}
|
||||||
} else uiRitualOfSwordTimer -= diff;
|
} else uiRitualOfSwordTimer -= diff;
|
||||||
|
|
||||||
DoMeleeAttackIfReady();
|
DoMeleeAttackIfReady();
|
||||||
|
|||||||
+2
-2
@@ -11972,8 +11972,8 @@ void Unit::SetHealth(uint32 val)
|
|||||||
if(getDeathState() == JUST_DIED)
|
if(getDeathState() == JUST_DIED)
|
||||||
val = 0;
|
val = 0;
|
||||||
// causes instant permadeath if you exit game while in combat?! :-|
|
// causes instant permadeath if you exit game while in combat?! :-|
|
||||||
//else if((getDeathState() & (DEAD | DEAD_FALLING)) != 0)
|
else if((GetTypeId() == TYPEID_PLAYER) && (getDeathState() & (DEAD | DEAD_FALLING)) != 0)
|
||||||
// val = 1;
|
val = 1;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
uint32 maxHealth = GetMaxHealth();
|
uint32 maxHealth = GetMaxHealth();
|
||||||
|
|||||||
Reference in New Issue
Block a user