change "IN_MILISECONDS" to proper english "IN_MILLISECONDS"
--HG-- branch : trunk
This commit is contained in:
@@ -231,7 +231,7 @@ void PetAI::UpdateAllies()
|
||||
Unit* owner = me->GetCharmerOrOwner();
|
||||
Group *pGroup = NULL;
|
||||
|
||||
m_updateAlliesTimer = 10*IN_MILISECONDS; //update friendly targets every 10 seconds, lesser checks increase performance
|
||||
m_updateAlliesTimer = 10*IN_MILLISECONDS; //update friendly targets every 10 seconds, lesser checks increase performance
|
||||
|
||||
if (!owner)
|
||||
return;
|
||||
|
||||
@@ -1797,7 +1797,7 @@ void AchievementMgr::SetCriteriaProgress(AchievementCriteriaEntry const* entry,
|
||||
//has to exist else we wouldn't be here
|
||||
timedCompleted = IsCompletedCriteria(entry, sAchievementStore.LookupEntry(entry->referredAchievement));
|
||||
// Client expects this in packet
|
||||
timeElapsed = entry->timeLimit - (timedIter->second/IN_MILISECONDS);
|
||||
timeElapsed = entry->timeLimit - (timedIter->second/IN_MILLISECONDS);
|
||||
|
||||
// Remove the timer, we wont need it anymore
|
||||
if (timedCompleted)
|
||||
@@ -1841,7 +1841,7 @@ void AchievementMgr::StartTimedAchievement(AchievementCriteriaTimedTypes type, u
|
||||
if (m_timedAchievements.find((*i)->ID) == m_timedAchievements.end() && !IsCompletedCriteria(*i, achievement))
|
||||
{
|
||||
// Start the timer
|
||||
m_timedAchievements[(*i)->ID] = (*i)->timeLimit * IN_MILISECONDS;
|
||||
m_timedAchievements[(*i)->ID] = (*i)->timeLimit * IN_MILLISECONDS;
|
||||
|
||||
// and at client too
|
||||
SetCriteriaProgress(*i, 0, PROGRESS_SET);
|
||||
|
||||
@@ -713,7 +713,7 @@ bool AuctionEntry::BuildAuctionInfo(WorldPacket & data) const
|
||||
data << uint32(bid ? GetAuctionOutBid() : 0);
|
||||
//minimal outbid
|
||||
data << uint32(buyout); //auction->buyout
|
||||
data << uint32((expire_time-time(NULL))*IN_MILISECONDS);//time left
|
||||
data << uint32((expire_time-time(NULL))*IN_MILLISECONDS);//time left
|
||||
data << uint64(bidder) ; //auction->bidder current
|
||||
data << uint32(bid); //current bid
|
||||
return true;
|
||||
|
||||
@@ -356,16 +356,16 @@ void BattleGround::Update(uint32 diff)
|
||||
{
|
||||
uint32 newtime = m_PrematureCountDownTimer - diff;
|
||||
// announce every minute
|
||||
if (newtime > (MINUTE * IN_MILISECONDS))
|
||||
if (newtime > (MINUTE * IN_MILLISECONDS))
|
||||
{
|
||||
if (newtime / (MINUTE * IN_MILISECONDS) != m_PrematureCountDownTimer / (MINUTE * IN_MILISECONDS))
|
||||
PSendMessageToAll(LANG_BATTLEGROUND_PREMATURE_FINISH_WARNING, CHAT_MSG_SYSTEM, NULL, (uint32)(m_PrematureCountDownTimer / (MINUTE * IN_MILISECONDS)));
|
||||
if (newtime / (MINUTE * IN_MILLISECONDS) != m_PrematureCountDownTimer / (MINUTE * IN_MILLISECONDS))
|
||||
PSendMessageToAll(LANG_BATTLEGROUND_PREMATURE_FINISH_WARNING, CHAT_MSG_SYSTEM, NULL, (uint32)(m_PrematureCountDownTimer / (MINUTE * IN_MILLISECONDS)));
|
||||
}
|
||||
else
|
||||
{
|
||||
//announce every 15 seconds
|
||||
if (newtime / (15 * IN_MILISECONDS) != m_PrematureCountDownTimer / (15 * IN_MILISECONDS))
|
||||
PSendMessageToAll(LANG_BATTLEGROUND_PREMATURE_FINISH_WARNING_SECS, CHAT_MSG_SYSTEM, NULL, (uint32)(m_PrematureCountDownTimer / IN_MILISECONDS));
|
||||
if (newtime / (15 * IN_MILLISECONDS) != m_PrematureCountDownTimer / (15 * IN_MILLISECONDS))
|
||||
PSendMessageToAll(LANG_BATTLEGROUND_PREMATURE_FINISH_WARNING_SECS, CHAT_MSG_SYSTEM, NULL, (uint32)(m_PrematureCountDownTimer / IN_MILLISECONDS));
|
||||
}
|
||||
m_PrematureCountDownTimer = newtime;
|
||||
}
|
||||
@@ -436,7 +436,7 @@ void BattleGround::Update(uint32 diff)
|
||||
AuraApplication * aurApp = iter->second;
|
||||
Aura * aura = aurApp->GetBase();
|
||||
if (!aura->IsPermanent()
|
||||
&& aura->GetDuration() <= 30*IN_MILISECONDS
|
||||
&& aura->GetDuration() <= 30*IN_MILLISECONDS
|
||||
&& aurApp->IsPositive()
|
||||
&& (!(aura->GetSpellProto()->Attributes & SPELL_ATTR_UNAFFECTED_BY_INVULNERABILITY))
|
||||
&& (!aura->HasEffectType(SPELL_AURA_MOD_INVISIBILITY)))
|
||||
|
||||
@@ -25,8 +25,8 @@
|
||||
|
||||
class BattleGround;
|
||||
|
||||
#define BG_EY_FLAG_RESPAWN_TIME (8*IN_MILISECONDS) //8 seconds
|
||||
#define BG_EY_FPOINTS_TICK_TIME (2*IN_MILISECONDS) //2 seconds
|
||||
#define BG_EY_FLAG_RESPAWN_TIME (8*IN_MILLISECONDS) //8 seconds
|
||||
#define BG_EY_FPOINTS_TICK_TIME (2*IN_MILLISECONDS) //2 seconds
|
||||
|
||||
enum BG_EY_WorldStates
|
||||
{
|
||||
|
||||
@@ -70,7 +70,7 @@ void BattleGroundWS::Update(uint32 diff)
|
||||
|
||||
if (GetStatus() == STATUS_IN_PROGRESS)
|
||||
{
|
||||
if (GetStartTime() >= 25*MINUTE*IN_MILISECONDS) // Òàéìåð òèêàòü íà÷èíàåò ïîñëå 25 ìèíóò
|
||||
if (GetStartTime() >= 25*MINUTE*IN_MILLISECONDS) // Òàéìåð òèêàòü íà÷èíàåò ïîñëå 25 ìèíóò
|
||||
{
|
||||
if (GetTeamScore(ALLIANCE) == 0)
|
||||
{
|
||||
@@ -91,7 +91,7 @@ void BattleGroundWS::Update(uint32 diff)
|
||||
else
|
||||
EndBattleGround(ALLIANCE);
|
||||
}
|
||||
else if (GetStartTime() > m_minutesElapsed*MINUTE*IN_MILISECONDS)
|
||||
else if (GetStartTime() > m_minutesElapsed*MINUTE*IN_MILLISECONDS)
|
||||
{
|
||||
++m_minutesElapsed;
|
||||
UpdateWorldState(BG_WS_STATE_TIMER, 25-m_minutesElapsed);
|
||||
|
||||
@@ -155,7 +155,7 @@ bool ChatHandler::HandleSaveCommand(const char* /*args*/)
|
||||
|
||||
// save or plan save after 20 sec (logout delay) if current next save time more this value and _not_ output any messages to prevent cheat planning
|
||||
uint32 save_interval = sWorld.getConfig(CONFIG_INTERVAL_SAVE);
|
||||
if ((save_interval == 0 || save_interval > 20*IN_MILISECONDS && player->GetSaveTimer() <= save_interval - 20*IN_MILISECONDS))
|
||||
if ((save_interval == 0 || save_interval > 20*IN_MILLISECONDS && player->GetSaveTimer() <= save_interval - 20*IN_MILLISECONDS))
|
||||
player->SaveToDB();
|
||||
|
||||
return true;
|
||||
|
||||
@@ -35,7 +35,7 @@ class Creature;
|
||||
class ThreatManager;
|
||||
struct SpellEntry;
|
||||
|
||||
#define THREAT_UPDATE_INTERVAL 1 * IN_MILISECONDS // Server should send threat update to client periodically each second
|
||||
#define THREAT_UPDATE_INTERVAL 1 * IN_MILLISECONDS // Server should send threat update to client periodically each second
|
||||
|
||||
//==============================================================
|
||||
// Class to calculate the real threat based
|
||||
|
||||
@@ -620,7 +620,7 @@ void Creature::RegenerateMana()
|
||||
if ((*i)->GetMiscValue() == POWER_MANA)
|
||||
addvalue *= ((*i)->GetAmount() + 100) / 100.0f;
|
||||
|
||||
addvalue += GetTotalAuraModifierByMiscValue(SPELL_AURA_MOD_POWER_REGEN, POWER_MANA) * CREATURE_REGEN_INTERVAL / (5 * IN_MILISECONDS);
|
||||
addvalue += GetTotalAuraModifierByMiscValue(SPELL_AURA_MOD_POWER_REGEN, POWER_MANA) * CREATURE_REGEN_INTERVAL / (5 * IN_MILLISECONDS);
|
||||
|
||||
ModifyPower(POWER_MANA, addvalue);
|
||||
}
|
||||
@@ -657,7 +657,7 @@ void Creature::RegenerateHealth()
|
||||
for (AuraEffectList::const_iterator i = ModPowerRegenPCTAuras.begin(); i != ModPowerRegenPCTAuras.end(); ++i)
|
||||
addvalue *= ((*i)->GetAmount() + 100) / 100.0f;
|
||||
|
||||
addvalue += GetTotalAuraModifier(SPELL_AURA_MOD_REGEN) * CREATURE_REGEN_INTERVAL / (5 * IN_MILISECONDS);
|
||||
addvalue += GetTotalAuraModifier(SPELL_AURA_MOD_REGEN) * CREATURE_REGEN_INTERVAL / (5 * IN_MILLISECONDS);
|
||||
|
||||
ModifyHealth(addvalue);
|
||||
}
|
||||
@@ -1473,7 +1473,7 @@ void Creature::setDeathState(DeathState s)
|
||||
{
|
||||
if ((s == JUST_DIED && !m_isDeadByDefault)||(s == JUST_ALIVED && m_isDeadByDefault))
|
||||
{
|
||||
m_deathTimer = m_corpseDelay*IN_MILISECONDS;
|
||||
m_deathTimer = m_corpseDelay*IN_MILLISECONDS;
|
||||
|
||||
// always save boss respawn time at death to prevent crash cheating
|
||||
if (sWorld.getConfig(CONFIG_SAVE_RESPAWN_TIME_IMMEDIATELY) || isWorldBoss())
|
||||
@@ -1987,7 +1987,7 @@ void Creature::SaveRespawnTime()
|
||||
if (m_respawnTime > time(NULL)) // dead (no corpse)
|
||||
objmgr.SaveCreatureRespawnTime(m_DBTableGuid,GetInstanceId(),m_respawnTime);
|
||||
else if (m_deathTimer > 0) // dead (corpse)
|
||||
objmgr.SaveCreatureRespawnTime(m_DBTableGuid,GetInstanceId(),time(NULL)+m_respawnDelay+m_deathTimer/IN_MILISECONDS);
|
||||
objmgr.SaveCreatureRespawnTime(m_DBTableGuid,GetInstanceId(),time(NULL)+m_respawnDelay+m_deathTimer/IN_MILLISECONDS);
|
||||
}
|
||||
|
||||
// this should not be called by petAI or
|
||||
@@ -2170,7 +2170,7 @@ void Creature::AddCreatureSpellCooldown(uint32 spellid)
|
||||
modOwner->ApplySpellMod(spellid, SPELLMOD_COOLDOWN, cooldown);
|
||||
|
||||
if (cooldown)
|
||||
_AddCreatureSpellCooldown(spellid, time(NULL) + cooldown/IN_MILISECONDS);
|
||||
_AddCreatureSpellCooldown(spellid, time(NULL) + cooldown/IN_MILLISECONDS);
|
||||
|
||||
if (spellInfo->Category)
|
||||
_AddCreatureCategoryCooldown(spellInfo->Category, time(NULL));
|
||||
@@ -2189,7 +2189,7 @@ bool Creature::HasCategoryCooldown(uint32 spell_id) const
|
||||
return true;
|
||||
|
||||
CreatureSpellCooldowns::const_iterator itr = m_CreatureCategoryCooldowns.find(spellInfo->Category);
|
||||
return(itr != m_CreatureCategoryCooldowns.end() && time_t(itr->second + (spellInfo->CategoryRecoveryTime / IN_MILISECONDS)) > time(NULL));
|
||||
return(itr != m_CreatureCategoryCooldowns.end() && time_t(itr->second + (spellInfo->CategoryRecoveryTime / IN_MILLISECONDS)) > time(NULL));
|
||||
}
|
||||
|
||||
bool Creature::HasSpellCooldown(uint32 spell_id) const
|
||||
@@ -2213,7 +2213,7 @@ time_t Creature::GetRespawnTimeEx() const
|
||||
if (m_respawnTime > now) // dead (no corpse)
|
||||
return m_respawnTime;
|
||||
else if (m_deathTimer > 0) // dead (corpse)
|
||||
return now+m_respawnDelay+m_deathTimer/IN_MILISECONDS;
|
||||
return now+m_respawnDelay+m_deathTimer/IN_MILLISECONDS;
|
||||
else
|
||||
return now;
|
||||
}
|
||||
@@ -2255,7 +2255,7 @@ void Creature::AllLootRemovedFromCorpse()
|
||||
|
||||
// corpse was not skinnable -> apply corpse looted timer
|
||||
if (!cinfo || !cinfo->SkinLootId)
|
||||
nDeathTimer = (uint32)((m_corpseDelay * IN_MILISECONDS) * sWorld.getRate(RATE_CORPSE_DECAY_LOOTED));
|
||||
nDeathTimer = (uint32)((m_corpseDelay * IN_MILLISECONDS) * sWorld.getRate(RATE_CORPSE_DECAY_LOOTED));
|
||||
// corpse skinnable, but without skinning flag, and then skinned, corpse will despawn next update
|
||||
else
|
||||
nDeathTimer = 0;
|
||||
|
||||
@@ -66,7 +66,7 @@ enum CreatureFlagsExtra
|
||||
#endif
|
||||
|
||||
#define MAX_KILL_CREDIT 2
|
||||
#define CREATURE_REGEN_INTERVAL 2 * IN_MILISECONDS
|
||||
#define CREATURE_REGEN_INTERVAL 2 * IN_MILLISECONDS
|
||||
|
||||
// from `creature_template` table
|
||||
struct CreatureInfo
|
||||
|
||||
@@ -479,7 +479,7 @@ struct GameObjectInfo
|
||||
case GAMEOBJECT_TYPE_AREADAMAGE: autoCloseTime = areadamage.autoCloseTime; break;
|
||||
default: break;
|
||||
}
|
||||
return autoCloseTime / IN_MILISECONDS; // prior to 3.0.3, conversion was / 0x10000;
|
||||
return autoCloseTime / IN_MILLISECONDS; // prior to 3.0.3, conversion was / 0x10000;
|
||||
}
|
||||
|
||||
uint32 GetLootId() const
|
||||
|
||||
@@ -619,7 +619,7 @@ void Creature::Regenerate(Powers power)
|
||||
if ((*i)->GetMiscValue() == power)
|
||||
addvalue *= ((*i)->GetAmount() + 100) / 100.0f;
|
||||
|
||||
addvalue += GetTotalAuraModifierByMiscValue(SPELL_AURA_MOD_POWER_REGEN, power) * (isHunterPet()? PET_FOCUS_REGEN_INTERVAL : CREATURE_REGEN_INTERVAL) / (5 * IN_MILISECONDS);
|
||||
addvalue += GetTotalAuraModifierByMiscValue(SPELL_AURA_MOD_POWER_REGEN, power) * (isHunterPet()? PET_FOCUS_REGEN_INTERVAL : CREATURE_REGEN_INTERVAL) / (5 * IN_MILLISECONDS);
|
||||
|
||||
ModifyPower(power, (int32)addvalue);
|
||||
}
|
||||
@@ -1112,7 +1112,7 @@ void Pet::_LoadSpellCooldowns()
|
||||
continue;
|
||||
|
||||
data << uint32(spell_id);
|
||||
data << uint32(uint32(db_time-curTime)*IN_MILISECONDS);
|
||||
data << uint32(uint32(db_time-curTime)*IN_MILLISECONDS);
|
||||
|
||||
_AddCreatureSpellCooldown(spell_id,db_time);
|
||||
|
||||
@@ -1229,10 +1229,10 @@ void Pet::_LoadAuras(uint32 timediff)
|
||||
// negative effects should continue counting down after logout
|
||||
if (remaintime != -1 && !IsPositiveSpell(spellid))
|
||||
{
|
||||
if (remaintime/IN_MILISECONDS <= int32(timediff))
|
||||
if (remaintime/IN_MILLISECONDS <= int32(timediff))
|
||||
continue;
|
||||
|
||||
remaintime -= timediff*IN_MILISECONDS;
|
||||
remaintime -= timediff*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
// prevent wrong values of remaincharges
|
||||
|
||||
@@ -118,7 +118,7 @@ typedef std::vector<uint32> AutoSpellList;
|
||||
|
||||
#define PET_FOLLOW_DIST 1
|
||||
#define PET_FOLLOW_ANGLE (M_PI/2)
|
||||
#define PET_FOCUS_REGEN_INTERVAL 4 * IN_MILISECONDS
|
||||
#define PET_FOCUS_REGEN_INTERVAL 4 * IN_MILLISECONDS
|
||||
|
||||
class Player;
|
||||
|
||||
|
||||
@@ -69,7 +69,7 @@
|
||||
#include "ConditionMgr.h"
|
||||
#include <cmath>
|
||||
|
||||
#define ZONE_UPDATE_INTERVAL (1*IN_MILISECONDS)
|
||||
#define ZONE_UPDATE_INTERVAL (1*IN_MILLISECONDS)
|
||||
|
||||
#define PLAYER_SKILL_INDEX(x) (PLAYER_SKILL_INFO_1_1 + ((x)*3))
|
||||
#define PLAYER_SKILL_VALUE_INDEX(x) (PLAYER_SKILL_INDEX(x)+1)
|
||||
@@ -477,7 +477,7 @@ Player::Player (WorldSession *session): Unit(), m_achievementMgr(this), m_reputa
|
||||
|
||||
m_swingErrorMsg = 0;
|
||||
|
||||
m_DetectInvTimer = 1*IN_MILISECONDS;
|
||||
m_DetectInvTimer = 1*IN_MILLISECONDS;
|
||||
|
||||
for (uint8 j = 0; j < PLAYER_MAX_BATTLEGROUND_QUEUES; ++j)
|
||||
{
|
||||
@@ -1037,12 +1037,12 @@ int32 Player::getMaxTimer(MirrorTimerType timer)
|
||||
switch (timer)
|
||||
{
|
||||
case FATIGUE_TIMER:
|
||||
return MINUTE*IN_MILISECONDS;
|
||||
return MINUTE*IN_MILLISECONDS;
|
||||
case BREATH_TIMER:
|
||||
{
|
||||
if (!isAlive() || HasAuraType(SPELL_AURA_WATER_BREATHING) || GetSession()->GetSecurity() >= sWorld.getConfig(CONFIG_DISABLE_BREATHING))
|
||||
return DISABLED_MIRROR_TIMER;
|
||||
int32 UnderWaterTime = 3*MINUTE*IN_MILISECONDS;
|
||||
int32 UnderWaterTime = 3*MINUTE*IN_MILLISECONDS;
|
||||
AuraEffectList const& mModWaterBreathing = GetAuraEffectsByType(SPELL_AURA_MOD_WATER_BREATHING);
|
||||
for (AuraEffectList::const_iterator i = mModWaterBreathing.begin(); i != mModWaterBreathing.end(); ++i)
|
||||
UnderWaterTime = uint32(UnderWaterTime * (100.0f + (*i)->GetAmount()) / 100.0f);
|
||||
@@ -1052,7 +1052,7 @@ int32 Player::getMaxTimer(MirrorTimerType timer)
|
||||
{
|
||||
if (!isAlive())
|
||||
return DISABLED_MIRROR_TIMER;
|
||||
return 1*IN_MILISECONDS;
|
||||
return 1*IN_MILLISECONDS;
|
||||
}
|
||||
default:
|
||||
return 0;
|
||||
@@ -1086,7 +1086,7 @@ void Player::HandleDrowning(uint32 time_diff)
|
||||
// Timer limit - need deal damage
|
||||
if (m_MirrorTimer[BREATH_TIMER] < 0)
|
||||
{
|
||||
m_MirrorTimer[BREATH_TIMER]+= 1*IN_MILISECONDS;
|
||||
m_MirrorTimer[BREATH_TIMER]+= 1*IN_MILLISECONDS;
|
||||
// Calculate and deal damage
|
||||
// TODO: Check this formula
|
||||
uint32 damage = GetMaxHealth() / 5 + urand(0, getLevel()-1);
|
||||
@@ -1122,7 +1122,7 @@ void Player::HandleDrowning(uint32 time_diff)
|
||||
// Timer limit - need deal damage or teleport ghost to graveyard
|
||||
if (m_MirrorTimer[FATIGUE_TIMER] < 0)
|
||||
{
|
||||
m_MirrorTimer[FATIGUE_TIMER]+= 1*IN_MILISECONDS;
|
||||
m_MirrorTimer[FATIGUE_TIMER]+= 1*IN_MILLISECONDS;
|
||||
if (isAlive()) // Calculate and deal damage
|
||||
{
|
||||
uint32 damage = GetMaxHealth() / 5 + urand(0, getLevel()-1);
|
||||
@@ -1155,7 +1155,7 @@ void Player::HandleDrowning(uint32 time_diff)
|
||||
m_MirrorTimer[FIRE_TIMER]-=time_diff;
|
||||
if (m_MirrorTimer[FIRE_TIMER] < 0)
|
||||
{
|
||||
m_MirrorTimer[FIRE_TIMER]+= 1*IN_MILISECONDS;
|
||||
m_MirrorTimer[FIRE_TIMER]+= 1*IN_MILLISECONDS;
|
||||
// Calculate and deal damage
|
||||
// TODO: Check this formula
|
||||
uint32 damage = urand(600, 700);
|
||||
@@ -1490,7 +1490,7 @@ void Player::Update(uint32 p_time)
|
||||
{
|
||||
m_drunkTimer += p_time;
|
||||
|
||||
if (m_drunkTimer > 10*IN_MILISECONDS)
|
||||
if (m_drunkTimer > 10*IN_MILLISECONDS)
|
||||
HandleSobering();
|
||||
}
|
||||
|
||||
@@ -2243,7 +2243,7 @@ void Player::Regenerate(Powers power)
|
||||
|
||||
// Butchery requires combat for this effect
|
||||
if (power != POWER_RUNIC_POWER || isInCombat())
|
||||
addvalue += GetTotalAuraModifierByMiscValue(SPELL_AURA_MOD_POWER_REGEN, power) * ((power != POWER_ENERGY) ? m_regenTimerCount : m_regenTimer) / (5 * IN_MILISECONDS);
|
||||
addvalue += GetTotalAuraModifierByMiscValue(SPELL_AURA_MOD_POWER_REGEN, power) * ((power != POWER_ENERGY) ? m_regenTimerCount : m_regenTimer) / (5 * IN_MILLISECONDS);
|
||||
}
|
||||
|
||||
if (addvalue < 0.0f)
|
||||
@@ -2321,7 +2321,7 @@ void Player::RegenerateHealth()
|
||||
for (AuraEffectList::const_iterator i = mModHealthRegenPct.begin(); i != mModHealthRegenPct.end(); ++i)
|
||||
addvalue *= (100.0f + (*i)->GetAmount()) / 100.0f;
|
||||
|
||||
addvalue += GetTotalAuraModifier(SPELL_AURA_MOD_REGEN) * 2 * IN_MILISECONDS / (5 * IN_MILISECONDS);
|
||||
addvalue += GetTotalAuraModifier(SPELL_AURA_MOD_REGEN) * 2 * IN_MILLISECONDS / (5 * IN_MILLISECONDS);
|
||||
}
|
||||
else if (HasAuraType(SPELL_AURA_MOD_REGEN_DURING_COMBAT))
|
||||
addvalue *= GetTotalAuraModifier(SPELL_AURA_MOD_REGEN_DURING_COMBAT) / 100.0f;
|
||||
@@ -2978,7 +2978,7 @@ void Player::SendInitialSpells()
|
||||
continue;
|
||||
}
|
||||
|
||||
time_t cooldown = itr->second.end > curTime ? (itr->second.end-curTime)*IN_MILISECONDS : 0;
|
||||
time_t cooldown = itr->second.end > curTime ? (itr->second.end-curTime)*IN_MILLISECONDS : 0;
|
||||
|
||||
if (sEntry->Category) // may be wrong, but anyway better than nothing...
|
||||
{
|
||||
@@ -3856,8 +3856,8 @@ void Player::RemoveArenaSpellCooldowns()
|
||||
SpellEntry const * entry = sSpellStore.LookupEntry(itr->first);
|
||||
// check if spellentry is present and if the cooldown is less than 10 mins
|
||||
if (entry &&
|
||||
entry->RecoveryTime <= 10 * MINUTE * IN_MILISECONDS &&
|
||||
entry->CategoryRecoveryTime <= 10 * MINUTE * IN_MILISECONDS)
|
||||
entry->RecoveryTime <= 10 * MINUTE * IN_MILLISECONDS &&
|
||||
entry->CategoryRecoveryTime <= 10 * MINUTE * IN_MILLISECONDS)
|
||||
{
|
||||
// remove & notify
|
||||
RemoveSpellCooldown(itr->first, true);
|
||||
@@ -4645,7 +4645,7 @@ void Player::ResurrectPlayer(float restore_percent, bool applySickness)
|
||||
|
||||
if (Aura * aur = GetAura(15007, GetGUID()))
|
||||
{
|
||||
aur->SetDuration(delta*IN_MILISECONDS);
|
||||
aur->SetDuration(delta*IN_MILLISECONDS);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -4698,7 +4698,7 @@ void Player::KillPlayer()
|
||||
ApplyModFlag(PLAYER_FIELD_BYTES, PLAYER_FIELD_BYTE_RELEASE_TIMER, !sMapStore.LookupEntry(GetMapId())->Instanceable());
|
||||
|
||||
// 6 minutes until repop at graveyard
|
||||
m_deathTimer = 6*MINUTE*IN_MILISECONDS;
|
||||
m_deathTimer = 6*MINUTE*IN_MILLISECONDS;
|
||||
|
||||
UpdateCorpseReclaimDelay(); // dependent at use SetDeathPvP() call before kill
|
||||
SendCorpseReclaimDelay();
|
||||
@@ -14213,10 +14213,10 @@ void Player::AddQuest(Quest const *pQuest, Object *questGiver)
|
||||
|
||||
// shared timed quest
|
||||
if (questGiver && questGiver->GetTypeId() == TYPEID_PLAYER)
|
||||
limittime = questGiver->ToPlayer()->getQuestStatusMap()[quest_id].m_timer / IN_MILISECONDS;
|
||||
limittime = questGiver->ToPlayer()->getQuestStatusMap()[quest_id].m_timer / IN_MILLISECONDS;
|
||||
|
||||
AddTimedQuest(quest_id);
|
||||
questStatusData.m_timer = limittime * IN_MILISECONDS;
|
||||
questStatusData.m_timer = limittime * IN_MILLISECONDS;
|
||||
qtime = static_cast<uint32>(time(NULL)) + limittime;
|
||||
}
|
||||
else
|
||||
@@ -16550,10 +16550,10 @@ void Player::_LoadAuras(QueryResult_AutoPtr result, uint32 timediff)
|
||||
// negative effects should continue counting down after logout
|
||||
if (remaintime != -1 && !IsPositiveSpell(spellid))
|
||||
{
|
||||
if (remaintime/IN_MILISECONDS <= int32(timediff))
|
||||
if (remaintime/IN_MILLISECONDS <= int32(timediff))
|
||||
continue;
|
||||
|
||||
remaintime -= timediff*IN_MILISECONDS;
|
||||
remaintime -= timediff*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
// prevent wrong values of remaincharges
|
||||
@@ -16979,7 +16979,7 @@ void Player::_LoadQuestStatus(QueryResult_AutoPtr result)
|
||||
if (quest_time <= sWorld.GetGameTime())
|
||||
questStatusData.m_timer = 1;
|
||||
else
|
||||
questStatusData.m_timer = (quest_time - sWorld.GetGameTime()) * IN_MILISECONDS;
|
||||
questStatusData.m_timer = (quest_time - sWorld.GetGameTime()) * IN_MILLISECONDS;
|
||||
}
|
||||
else
|
||||
quest_time = 0;
|
||||
@@ -18023,11 +18023,11 @@ void Player::_SaveQuestStatus()
|
||||
case QUEST_NEW :
|
||||
CharacterDatabase.PExecute("INSERT INTO character_queststatus (guid,quest,status,rewarded,explored,timer,mobcount1,mobcount2,mobcount3,mobcount4,itemcount1,itemcount2,itemcount3,itemcount4) "
|
||||
"VALUES ('%u', '%u', '%u', '%u', '%u', '" UI64FMTD "', '%u', '%u', '%u', '%u', '%u', '%u', '%u', '%u')",
|
||||
GetGUIDLow(), i->first, i->second.m_status, i->second.m_rewarded, i->second.m_explored, uint64(i->second.m_timer / IN_MILISECONDS+ sWorld.GetGameTime()), i->second.m_creatureOrGOcount[0], i->second.m_creatureOrGOcount[1], i->second.m_creatureOrGOcount[2], i->second.m_creatureOrGOcount[3], i->second.m_itemcount[0], i->second.m_itemcount[1], i->second.m_itemcount[2], i->second.m_itemcount[3]);
|
||||
GetGUIDLow(), i->first, i->second.m_status, i->second.m_rewarded, i->second.m_explored, uint64(i->second.m_timer / IN_MILLISECONDS+ sWorld.GetGameTime()), i->second.m_creatureOrGOcount[0], i->second.m_creatureOrGOcount[1], i->second.m_creatureOrGOcount[2], i->second.m_creatureOrGOcount[3], i->second.m_itemcount[0], i->second.m_itemcount[1], i->second.m_itemcount[2], i->second.m_itemcount[3]);
|
||||
break;
|
||||
case QUEST_CHANGED :
|
||||
CharacterDatabase.PExecute("UPDATE character_queststatus SET status = '%u',rewarded = '%u',explored = '%u',timer = '" UI64FMTD "',mobcount1 = '%u',mobcount2 = '%u',mobcount3 = '%u',mobcount4 = '%u',itemcount1 = '%u',itemcount2 = '%u',itemcount3 = '%u',itemcount4 = '%u' WHERE guid = '%u' AND quest = '%u' ",
|
||||
i->second.m_status, i->second.m_rewarded, i->second.m_explored, uint64(i->second.m_timer / IN_MILISECONDS + sWorld.GetGameTime()), i->second.m_creatureOrGOcount[0], i->second.m_creatureOrGOcount[1], i->second.m_creatureOrGOcount[2], i->second.m_creatureOrGOcount[3], i->second.m_itemcount[0], i->second.m_itemcount[1], i->second.m_itemcount[2], i->second.m_itemcount[3], GetGUIDLow(), i->first);
|
||||
i->second.m_status, i->second.m_rewarded, i->second.m_explored, uint64(i->second.m_timer / IN_MILLISECONDS + sWorld.GetGameTime()), i->second.m_creatureOrGOcount[0], i->second.m_creatureOrGOcount[1], i->second.m_creatureOrGOcount[2], i->second.m_creatureOrGOcount[3], i->second.m_itemcount[0], i->second.m_itemcount[1], i->second.m_itemcount[2], i->second.m_itemcount[3], GetGUIDLow(), i->first);
|
||||
break;
|
||||
case QUEST_UNCHANGED:
|
||||
break;
|
||||
@@ -18725,7 +18725,7 @@ void Player::PetSpellInitialize()
|
||||
|
||||
for (CreatureSpellCooldowns::const_iterator itr = pet->m_CreatureSpellCooldowns.begin(); itr != pet->m_CreatureSpellCooldowns.end(); ++itr)
|
||||
{
|
||||
time_t cooldown = (itr->second > curTime) ? (itr->second - curTime) * IN_MILISECONDS : 0;
|
||||
time_t cooldown = (itr->second > curTime) ? (itr->second - curTime) * IN_MILLISECONDS : 0;
|
||||
|
||||
data << uint32(itr->first); // spellid
|
||||
data << uint16(0); // spell category?
|
||||
@@ -18735,7 +18735,7 @@ void Player::PetSpellInitialize()
|
||||
|
||||
for (CreatureSpellCooldowns::const_iterator itr = pet->m_CreatureCategoryCooldowns.begin(); itr != pet->m_CreatureCategoryCooldowns.end(); ++itr)
|
||||
{
|
||||
time_t cooldown = (itr->second > curTime) ? (itr->second - curTime) * IN_MILISECONDS : 0;
|
||||
time_t cooldown = (itr->second > curTime) ? (itr->second - curTime) * IN_MILLISECONDS : 0;
|
||||
|
||||
data << uint32(itr->first); // spellid
|
||||
data << uint16(0); // spell category?
|
||||
@@ -19513,7 +19513,7 @@ void Player::ProhibitSpellScholl(SpellSchoolMask idSchoolMask, uint32 unTimeMs)
|
||||
{
|
||||
data << uint32(unSpellId);
|
||||
data << uint32(unTimeMs); // in m.secs
|
||||
AddSpellCooldown(unSpellId, 0, curTime + unTimeMs/IN_MILISECONDS);
|
||||
AddSpellCooldown(unSpellId, 0, curTime + unTimeMs/IN_MILLISECONDS);
|
||||
}
|
||||
}
|
||||
GetSession()->SendPacket(&data);
|
||||
@@ -20009,8 +20009,8 @@ void Player::AddSpellAndCategoryCooldowns(SpellEntry const* spellInfo, uint32 it
|
||||
if (rec == 0 && catrec == 0)
|
||||
return;
|
||||
|
||||
catrecTime = catrec ? curTime+catrec/IN_MILISECONDS : 0;
|
||||
recTime = rec ? curTime+rec/IN_MILISECONDS : catrecTime;
|
||||
catrecTime = catrec ? curTime+catrec/IN_MILLISECONDS : 0;
|
||||
recTime = rec ? curTime+rec/IN_MILLISECONDS : catrecTime;
|
||||
}
|
||||
|
||||
// self spell cooldown
|
||||
@@ -22024,7 +22024,7 @@ void Player::SendCorpseReclaimDelay(bool load)
|
||||
|
||||
//! corpse reclaim delay 30 * 1000ms or longer at often deaths
|
||||
WorldPacket data(SMSG_CORPSE_RECLAIM_DELAY, 4);
|
||||
data << uint32(delay*IN_MILISECONDS);
|
||||
data << uint32(delay*IN_MILLISECONDS);
|
||||
GetSession()->SendPacket(&data);
|
||||
}
|
||||
|
||||
|
||||
@@ -2118,7 +2118,7 @@ class Player : public Unit, public GridObject<Player>
|
||||
/*** REST SYSTEM ***/
|
||||
/*********************************************************/
|
||||
|
||||
bool isRested() const { return GetRestTime() >= 10*IN_MILISECONDS; }
|
||||
bool isRested() const { return GetRestTime() >= 10*IN_MILLISECONDS; }
|
||||
uint32 GetXPRestBonus(uint32 xp);
|
||||
uint32 GetRestTime() const { return m_restTime;}
|
||||
void SetRestTime(uint32 v) { m_restTime = v;}
|
||||
|
||||
@@ -4176,7 +4176,7 @@ void Unit::RemoveAurasDueToSpellBySteal(uint32 spellId, uint64 casterGUID, Unit
|
||||
}
|
||||
else
|
||||
{
|
||||
int32 dur = 2*MINUTE*IN_MILISECONDS < aura->GetDuration() ? 2*MINUTE*IN_MILISECONDS : aura->GetDuration();
|
||||
int32 dur = 2*MINUTE*IN_MILLISECONDS < aura->GetDuration() ? 2*MINUTE*IN_MILLISECONDS : aura->GetDuration();
|
||||
|
||||
newAura = Aura::TryCreate(aura->GetSpellProto(), effMask, stealer, NULL, &baseDamage[0], NULL, aura->GetCasterGUID());
|
||||
if (!newAura)
|
||||
@@ -12671,7 +12671,7 @@ int32 Unit::ModSpellDuration(SpellEntry const* spellProto, Unit const* target, i
|
||||
{
|
||||
// Glyph of Thorns
|
||||
if (AuraEffect * aurEff = GetAuraEffect(57862, 0))
|
||||
duration += aurEff->GetAmount() * MINUTE * IN_MILISECONDS;
|
||||
duration += aurEff->GetAmount() * MINUTE * IN_MILLISECONDS;
|
||||
}
|
||||
break;
|
||||
case SPELLFAMILY_PALADIN:
|
||||
@@ -12679,13 +12679,13 @@ int32 Unit::ModSpellDuration(SpellEntry const* spellProto, Unit const* target, i
|
||||
{
|
||||
// Glyph of Blessing of Might
|
||||
if (AuraEffect * aurEff = GetAuraEffect(57958, 0))
|
||||
duration += aurEff->GetAmount() * MINUTE * IN_MILISECONDS;
|
||||
duration += aurEff->GetAmount() * MINUTE * IN_MILLISECONDS;
|
||||
}
|
||||
else if (spellProto->SpellFamilyFlags[0] & 0x00010000)
|
||||
{
|
||||
// Glyph of Blessing of Wisdom
|
||||
if (AuraEffect * aurEff = GetAuraEffect(57979, 0))
|
||||
duration += aurEff->GetAmount() * MINUTE * IN_MILISECONDS;
|
||||
duration += aurEff->GetAmount() * MINUTE * IN_MILLISECONDS;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -1151,7 +1151,7 @@ uint32 GameEventMgr::Update() // return the next e
|
||||
for (std::set<uint16>::iterator itr = deactivate.begin(); itr != deactivate.end(); ++itr)
|
||||
StopEvent(*itr);
|
||||
sLog.outDetail("Next game event check in %u seconds.", nextEventDelay + 1);
|
||||
return (nextEventDelay + 1) * IN_MILISECONDS; // Add 1 second to be sure event has started/stopped at next call
|
||||
return (nextEventDelay + 1) * IN_MILLISECONDS; // Add 1 second to be sure event has started/stopped at next call
|
||||
}
|
||||
|
||||
void GameEventMgr::UnApplyEvent(uint16 event_id)
|
||||
|
||||
@@ -42,7 +42,7 @@ class Player;
|
||||
|
||||
#define CENTER_GRID_OFFSET (SIZE_OF_GRIDS/2)
|
||||
|
||||
#define MIN_GRID_DELAY (MINUTE*IN_MILISECONDS)
|
||||
#define MIN_GRID_DELAY (MINUTE*IN_MILLISECONDS)
|
||||
#define MIN_MAP_UPDATE_DELAY 50
|
||||
|
||||
#define SIZE_OF_GRID_CELL (SIZE_OF_GRIDS/MAX_NUMBER_OF_CELLS)
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
#include <set>
|
||||
|
||||
#define FLIGHT_TRAVEL_UPDATE 100
|
||||
#define STOP_TIME_FOR_PLAYER 3 * MINUTE * IN_MILISECONDS // 3 Minutes
|
||||
#define STOP_TIME_FOR_PLAYER 3 * MINUTE * IN_MILLISECONDS // 3 Minutes
|
||||
#define TIMEDIFF_NEXT_WP 250
|
||||
|
||||
template<class T, class P>
|
||||
|
||||
@@ -198,7 +198,7 @@ void WorldSession::HandleMoveTeleportAck(WorldPacket& recv_data)
|
||||
uint32 flags, time;
|
||||
recv_data >> flags >> time;
|
||||
DEBUG_LOG("Guid " UI64FMTD, guid);
|
||||
DEBUG_LOG("Flags %u, time %u", flags, time/IN_MILISECONDS);
|
||||
DEBUG_LOG("Flags %u, time %u", flags, time/IN_MILLISECONDS);
|
||||
|
||||
Unit *mover = _player->m_mover;
|
||||
Player *plMover = mover->GetTypeId() == TYPEID_PLAYER ? (Player*)mover : NULL;
|
||||
|
||||
@@ -733,7 +733,7 @@ void AuraEffect::CalculatePeriodic(Unit * caster, bool create)
|
||||
case SPELL_AURA_OBS_MOD_POWER:
|
||||
// 3 spells have no amplitude set
|
||||
if (!m_amplitude)
|
||||
m_amplitude = 1 * IN_MILISECONDS;
|
||||
m_amplitude = 1 * IN_MILLISECONDS;
|
||||
case SPELL_AURA_PERIODIC_DAMAGE:
|
||||
case SPELL_AURA_PERIODIC_HEAL:
|
||||
case SPELL_AURA_PERIODIC_ENERGIZE:
|
||||
@@ -762,7 +762,7 @@ void AuraEffect::CalculatePeriodic(Unit * caster, bool create)
|
||||
{
|
||||
m_isPeriodic = true;
|
||||
m_amplitude = irand (0, 60) + 30;
|
||||
m_amplitude *= IN_MILISECONDS;
|
||||
m_amplitude *= IN_MILLISECONDS;
|
||||
}
|
||||
break;
|
||||
}
|
||||
@@ -1047,7 +1047,7 @@ void AuraEffect::UpdatePeriodic(Unit * caster)
|
||||
if (GetId() == 7057)
|
||||
{
|
||||
m_amplitude = irand (0 , 60) + 30;
|
||||
m_amplitude *= IN_MILISECONDS;
|
||||
m_amplitude *= IN_MILLISECONDS;
|
||||
}
|
||||
break;
|
||||
case SPELL_AURA_PERIODIC_TRIGGER_SPELL:
|
||||
@@ -3125,7 +3125,7 @@ void AuraEffect::HandleAuraTransform(AuraApplication const * aurApp, uint8 mode,
|
||||
// for players, start regeneration after 1s (in polymorph fast regeneration case)
|
||||
// only if caster is Player (after patch 2.4.2)
|
||||
if (IS_PLAYER_GUID(GetCasterGUID()))
|
||||
target->ToPlayer()->setRegenTimerCount(1*IN_MILISECONDS);
|
||||
target->ToPlayer()->setRegenTimerCount(1*IN_MILLISECONDS);
|
||||
|
||||
//dismount polymorphed target (after patch 2.4.2)
|
||||
if (target->IsMounted())
|
||||
|
||||
@@ -306,7 +306,7 @@ m_spellProto(spellproto), m_owner(owner), m_casterGuid(casterGUID ? casterGUID :
|
||||
m_procCharges(0), m_stackAmount(1), m_isRemoved(false), m_casterLevel(caster ? caster->getLevel() : m_spellProto->spellLevel)
|
||||
{
|
||||
if (m_spellProto->manaPerSecond || m_spellProto->manaPerSecondPerLevel)
|
||||
m_timeCla = 1 * IN_MILISECONDS;
|
||||
m_timeCla = 1 * IN_MILLISECONDS;
|
||||
|
||||
Player* modOwner = NULL;
|
||||
|
||||
@@ -699,7 +699,7 @@ void Aura::RefreshDuration()
|
||||
m_effects[i]->ResetPeriodic();
|
||||
|
||||
if (m_spellProto->manaPerSecond || m_spellProto->manaPerSecondPerLevel)
|
||||
m_timeCla = 1 * IN_MILISECONDS;
|
||||
m_timeCla = 1 * IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void Aura::SetCharges(uint8 charges)
|
||||
@@ -1290,7 +1290,7 @@ void Aura::HandleAuraSpecificMods(AuraApplication const * aurApp, Unit * caster,
|
||||
data << uint64(player->GetGUID());
|
||||
data << uint8(0x0); // flags (0x1, 0x2)
|
||||
data << uint32(GetSpellProto()->Id);
|
||||
data << uint32(aurEff->GetAmount()*IN_MILISECONDS);
|
||||
data << uint32(aurEff->GetAmount()*IN_MILLISECONDS);
|
||||
player->SendDirectMessage(&data);
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -727,7 +727,7 @@ void Spell::SpellDamageSchoolDmg(uint32 effect_idx)
|
||||
// Add main hand dps * effect[2] amount
|
||||
float average = (m_caster->GetFloatValue(UNIT_FIELD_MINDAMAGE) + m_caster->GetFloatValue(UNIT_FIELD_MAXDAMAGE)) / 2;
|
||||
int32 count = m_caster->CalculateSpellDamage(unitTarget, m_spellInfo, 2);
|
||||
damage += count * int32(average * IN_MILISECONDS) / m_caster->GetAttackTime(BASE_ATTACK);
|
||||
damage += count * int32(average * IN_MILLISECONDS) / m_caster->GetAttackTime(BASE_ATTACK);
|
||||
}
|
||||
// Shield of Righteousness
|
||||
else if (m_spellInfo->SpellFamilyFlags[1]&0x00100000)
|
||||
@@ -3946,7 +3946,7 @@ void Spell::EffectDistract(uint32 /*i*/)
|
||||
// Set creature Distracted, Stop it, And turn it
|
||||
unitTarget->SetOrientation(angle);
|
||||
unitTarget->StopMoving();
|
||||
unitTarget->GetMotionMaster()->MoveDistract(damage * IN_MILISECONDS);
|
||||
unitTarget->GetMotionMaster()->MoveDistract(damage * IN_MILLISECONDS);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4873,7 +4873,7 @@ void Spell::EffectSummonObjectWild(uint32 i)
|
||||
|
||||
int32 duration = GetSpellDuration(m_spellInfo);
|
||||
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
|
||||
pGameObj->SetSpellId(m_spellInfo->Id);
|
||||
|
||||
// Wild object not have owner and check clickable by players
|
||||
@@ -4916,7 +4916,7 @@ void Spell::EffectSummonObjectWild(uint32 i)
|
||||
if (linkedGO->Create(objmgr.GenerateLowGuid(HIGHGUID_GAMEOBJECT), linkedEntry, map,
|
||||
m_caster->GetPhaseMask(), x, y, z, target->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 100, GO_STATE_READY))
|
||||
{
|
||||
linkedGO->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
|
||||
linkedGO->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
|
||||
linkedGO->SetSpellId(m_spellInfo->Id);
|
||||
|
||||
// Wild object not have owner and check clickable by players
|
||||
@@ -6507,7 +6507,7 @@ void Spell::EffectDuel(uint32 i)
|
||||
pGameObj->SetUInt32Value(GAMEOBJECT_FACTION, m_caster->getFaction());
|
||||
pGameObj->SetUInt32Value(GAMEOBJECT_LEVEL, m_caster->getLevel()+1);
|
||||
int32 duration = GetSpellDuration(m_spellInfo);
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
|
||||
pGameObj->SetSpellId(m_spellInfo->Id);
|
||||
|
||||
m_caster->AddGameObject(pGameObj);
|
||||
@@ -6585,7 +6585,7 @@ void Spell::EffectSummonPlayer(uint32 /*i*/)
|
||||
WorldPacket data(SMSG_SUMMON_REQUEST, 8+4+4);
|
||||
data << uint64(m_caster->GetGUID()); // summoner guid
|
||||
data << uint32(m_caster->GetZoneId()); // summoner zone
|
||||
data << uint32(MAX_PLAYER_SUMMON_DELAY*IN_MILISECONDS); // auto decline after msecs
|
||||
data << uint32(MAX_PLAYER_SUMMON_DELAY*IN_MILLISECONDS); // auto decline after msecs
|
||||
unitTarget->ToPlayer()->GetSession()->SendPacket(&data);
|
||||
}
|
||||
|
||||
@@ -6683,7 +6683,7 @@ void Spell::EffectEnchantHeldItem(uint32 i)
|
||||
return;
|
||||
|
||||
// Apply the temporary enchantment
|
||||
item->SetEnchantment(slot, enchant_id, duration*IN_MILISECONDS, 0);
|
||||
item->SetEnchantment(slot, enchant_id, duration*IN_MILLISECONDS, 0);
|
||||
item_owner->ApplyEnchantment(item, slot, true);
|
||||
}
|
||||
}
|
||||
@@ -6813,7 +6813,7 @@ void Spell::EffectSummonObject(uint32 i)
|
||||
|
||||
//pGameObj->SetUInt32Value(GAMEOBJECT_LEVEL,m_caster->getLevel());
|
||||
int32 duration = GetSpellDuration(m_spellInfo);
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
|
||||
pGameObj->SetSpellId(m_spellInfo->Id);
|
||||
m_caster->AddGameObject(pGameObj);
|
||||
|
||||
@@ -7445,7 +7445,7 @@ void Spell::EffectTransmitted(uint32 effIndex)
|
||||
case 3: lastSec = 17; break;
|
||||
}
|
||||
|
||||
duration = duration - lastSec*IN_MILISECONDS + FISHING_BOBBER_READY_TIME*IN_MILISECONDS;
|
||||
duration = duration - lastSec*IN_MILLISECONDS + FISHING_BOBBER_READY_TIME*IN_MILLISECONDS;
|
||||
break;
|
||||
}
|
||||
case GAMEOBJECT_TYPE_SUMMONING_RITUAL:
|
||||
@@ -7466,7 +7466,7 @@ void Spell::EffectTransmitted(uint32 effIndex)
|
||||
break;
|
||||
}
|
||||
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
|
||||
|
||||
pGameObj->SetOwnerGUID(m_caster->GetGUID());
|
||||
|
||||
@@ -7485,7 +7485,7 @@ void Spell::EffectTransmitted(uint32 effIndex)
|
||||
if (linkedGO->Create(objmgr.GenerateLowGuid(HIGHGUID_GAMEOBJECT), linkedEntry, cMap,
|
||||
m_caster->GetPhaseMask(), fx, fy, fz, m_caster->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 100, GO_STATE_READY))
|
||||
{
|
||||
linkedGO->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
|
||||
linkedGO->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
|
||||
//linkedGO->SetUInt32Value(GAMEOBJECT_LEVEL, m_caster->getLevel());
|
||||
linkedGO->SetSpellId(m_spellInfo->Id);
|
||||
linkedGO->SetOwnerGUID(m_caster->GetGUID());
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
#include "ScriptMgr.h"
|
||||
#include "ConditionMgr.h"
|
||||
|
||||
#define SPELL_CHANNEL_UPDATE_INTERVAL (1 * IN_MILISECONDS)
|
||||
#define SPELL_CHANNEL_UPDATE_INTERVAL (1 * IN_MILLISECONDS)
|
||||
|
||||
extern pEffect SpellEffects[TOTAL_SPELL_EFFECTS];
|
||||
|
||||
@@ -4772,7 +4772,7 @@ SpellCastResult Spell::CheckCast(bool strict)
|
||||
// - with greater than 10 min CD without SPELL_ATTR_EX4_USABLE_IN_ARENA flag
|
||||
// - with SPELL_ATTR_EX4_NOT_USABLE_IN_ARENA flag
|
||||
if ((m_spellInfo->AttributesEx4 & SPELL_ATTR_EX4_NOT_USABLE_IN_ARENA) ||
|
||||
GetSpellRecoveryTime(m_spellInfo) > 10 * MINUTE * IN_MILISECONDS && !(m_spellInfo->AttributesEx4 & SPELL_ATTR_EX4_USABLE_IN_ARENA))
|
||||
GetSpellRecoveryTime(m_spellInfo) > 10 * MINUTE * IN_MILLISECONDS && !(m_spellInfo->AttributesEx4 & SPELL_ATTR_EX4_USABLE_IN_ARENA))
|
||||
if (MapEntry const* mapEntry = sMapStore.LookupEntry(m_caster->GetMapId()))
|
||||
if (mapEntry->IsBattleArena())
|
||||
return SPELL_FAILED_NOT_IN_ARENA;
|
||||
|
||||
@@ -2876,38 +2876,38 @@ int32 GetDiminishingReturnsLimitDuration(DiminishingGroup group, SpellEntry cons
|
||||
{
|
||||
// Wyvern Sting
|
||||
if (spellproto->SpellFamilyFlags[1] & 0x1000)
|
||||
return 6 * IN_MILISECONDS;
|
||||
return 6 * IN_MILLISECONDS;
|
||||
// Hunter's Mark
|
||||
if (spellproto->SpellFamilyFlags[0] & 0x400)
|
||||
return 120 * IN_MILISECONDS;
|
||||
return 120 * IN_MILLISECONDS;
|
||||
break;
|
||||
}
|
||||
case SPELLFAMILY_PALADIN:
|
||||
{
|
||||
// Repentance - limit to 6 seconds in PvP
|
||||
if (spellproto->SpellFamilyFlags[0] & 0x4)
|
||||
return 6 * IN_MILISECONDS;
|
||||
return 6 * IN_MILLISECONDS;
|
||||
break;
|
||||
}
|
||||
case SPELLFAMILY_DRUID:
|
||||
{
|
||||
// Faerie Fire - limit to 40 seconds in PvP (3.1)
|
||||
if (spellproto->SpellFamilyFlags[0] & 0x400)
|
||||
return 40 * IN_MILISECONDS;
|
||||
return 40 * IN_MILLISECONDS;
|
||||
break;
|
||||
}
|
||||
case SPELLFAMILY_PRIEST:
|
||||
{
|
||||
// Vampiric Embrace - limit to 60 seconds in PvP (3.1)
|
||||
if ((spellproto->SpellFamilyFlags[0] & 0x4) && spellproto->SpellIconID == 150)
|
||||
return 60 * IN_MILISECONDS;
|
||||
return 60 * IN_MILLISECONDS;
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
return 10 * IN_MILISECONDS;
|
||||
return 10 * IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
bool IsDiminishingReturnsGroupDurationLimited(DiminishingGroup group)
|
||||
|
||||
@@ -37,7 +37,7 @@ Weather::Weather(uint32 zone, WeatherZoneChances const* weatherChances) : m_zone
|
||||
m_type = WEATHER_TYPE_FINE;
|
||||
m_grade = 0;
|
||||
|
||||
sLog.outDetail("WORLD: Starting weather system for zone %u (change every %u minutes).", m_zone, (uint32)(m_timer.GetInterval() / (MINUTE*IN_MILISECONDS)));
|
||||
sLog.outDetail("WORLD: Starting weather system for zone %u (change every %u minutes).", m_zone, (uint32)(m_timer.GetInterval() / (MINUTE*IN_MILLISECONDS)));
|
||||
}
|
||||
|
||||
/// Launch a weather update
|
||||
|
||||
@@ -614,7 +614,7 @@ void World::LoadConfigSettings(bool reload)
|
||||
m_configs[CONFIG_MAIL_LEVEL_REQ] = sConfig.GetIntDefault("LevelReq.Mail", 1);
|
||||
m_configs[CONFIG_ALLOW_PLAYER_COMMANDS] = sConfig.GetBoolDefault("AllowPlayerCommands", 1);
|
||||
m_configs[CONFIG_GRID_UNLOAD] = sConfig.GetBoolDefault("GridUnload", true);
|
||||
m_configs[CONFIG_INTERVAL_SAVE] = sConfig.GetIntDefault("PlayerSaveInterval", 15 * MINUTE * IN_MILISECONDS);
|
||||
m_configs[CONFIG_INTERVAL_SAVE] = sConfig.GetIntDefault("PlayerSaveInterval", 15 * MINUTE * IN_MILLISECONDS);
|
||||
m_configs[CONFIG_INTERVAL_DISCONNECT_TOLERANCE] = sConfig.GetIntDefault("DisconnectToleranceInterval", 0);
|
||||
m_configs[CONFIG_STATS_SAVE_ONLY_ON_LOGOUT] = sConfig.GetBoolDefault("PlayerSave.Stats.SaveOnlyOnLogout", true);
|
||||
|
||||
@@ -625,7 +625,7 @@ void World::LoadConfigSettings(bool reload)
|
||||
m_configs[CONFIG_MIN_LEVEL_STAT_SAVE] = 0;
|
||||
}
|
||||
|
||||
m_configs[CONFIG_INTERVAL_GRIDCLEAN] = sConfig.GetIntDefault("GridCleanUpDelay", 5 * MINUTE * IN_MILISECONDS);
|
||||
m_configs[CONFIG_INTERVAL_GRIDCLEAN] = sConfig.GetIntDefault("GridCleanUpDelay", 5 * MINUTE * IN_MILLISECONDS);
|
||||
if (m_configs[CONFIG_INTERVAL_GRIDCLEAN] < MIN_GRID_DELAY)
|
||||
{
|
||||
sLog.outError("GridCleanUpDelay (%i) must be greater %u. Use this minimal value.",m_configs[CONFIG_INTERVAL_GRIDCLEAN],MIN_GRID_DELAY);
|
||||
@@ -643,7 +643,7 @@ void World::LoadConfigSettings(bool reload)
|
||||
if (reload)
|
||||
sMapMgr.SetMapUpdateInterval(m_configs[CONFIG_INTERVAL_MAPUPDATE]);
|
||||
|
||||
m_configs[CONFIG_INTERVAL_CHANGEWEATHER] = sConfig.GetIntDefault("ChangeWeatherInterval", 10 * MINUTE * IN_MILISECONDS);
|
||||
m_configs[CONFIG_INTERVAL_CHANGEWEATHER] = sConfig.GetIntDefault("ChangeWeatherInterval", 10 * MINUTE * IN_MILLISECONDS);
|
||||
|
||||
if (reload)
|
||||
{
|
||||
@@ -863,7 +863,7 @@ void World::LoadConfigSettings(bool reload)
|
||||
|
||||
m_configs[CONFIG_CAST_UNSTUCK] = sConfig.GetBoolDefault("CastUnstuck", true);
|
||||
m_configs[CONFIG_INSTANCE_RESET_TIME_HOUR] = sConfig.GetIntDefault("Instance.ResetTimeHour", 4);
|
||||
m_configs[CONFIG_INSTANCE_UNLOAD_DELAY] = sConfig.GetIntDefault("Instance.UnloadDelay", 30 * MINUTE * IN_MILISECONDS);
|
||||
m_configs[CONFIG_INSTANCE_UNLOAD_DELAY] = sConfig.GetIntDefault("Instance.UnloadDelay", 30 * MINUTE * IN_MILLISECONDS);
|
||||
|
||||
m_configs[CONFIG_MAX_PRIMARY_TRADE_SKILL] = sConfig.GetIntDefault("MaxPrimaryTradeSkill", 2);
|
||||
m_configs[CONFIG_MIN_PETITION_SIGNS] = sConfig.GetIntDefault("MinPetitionSigns", 9);
|
||||
@@ -911,7 +911,7 @@ void World::LoadConfigSettings(bool reload)
|
||||
}
|
||||
if (reload)
|
||||
{
|
||||
m_timers[WUPDATE_UPTIME].SetInterval(m_configs[CONFIG_UPTIME_UPDATE]*MINUTE*IN_MILISECONDS);
|
||||
m_timers[WUPDATE_UPTIME].SetInterval(m_configs[CONFIG_UPTIME_UPDATE]*MINUTE*IN_MILLISECONDS);
|
||||
m_timers[WUPDATE_UPTIME].Reset();
|
||||
}
|
||||
|
||||
@@ -924,7 +924,7 @@ void World::LoadConfigSettings(bool reload)
|
||||
}
|
||||
if (reload)
|
||||
{
|
||||
m_timers[WUPDATE_CLEANDB].SetInterval(m_configs[CONFIG_LOGDB_CLEARINTERVAL] * MINUTE * IN_MILISECONDS);
|
||||
m_timers[WUPDATE_CLEANDB].SetInterval(m_configs[CONFIG_LOGDB_CLEARINTERVAL] * MINUTE * IN_MILLISECONDS);
|
||||
m_timers[WUPDATE_CLEANDB].Reset();
|
||||
}
|
||||
m_configs[CONFIG_LOGDB_CLEARTIME] = sConfig.GetIntDefault("LogDB.Opt.ClearTime", 1209600); // 14 days default
|
||||
@@ -1059,11 +1059,11 @@ void World::LoadConfigSettings(bool reload)
|
||||
m_configs[CONFIG_BATTLEGROUND_QUEUE_ANNOUNCER_ENABLE] = sConfig.GetBoolDefault("Battleground.QueueAnnouncer.Enable", false);
|
||||
m_configs[CONFIG_BATTLEGROUND_QUEUE_ANNOUNCER_PLAYERONLY] = sConfig.GetBoolDefault("Battleground.QueueAnnouncer.PlayerOnly", false);
|
||||
m_configs[CONFIG_BATTLEGROUND_INVITATION_TYPE] = sConfig.GetIntDefault ("Battleground.InvitationType", 0);
|
||||
m_configs[CONFIG_BATTLEGROUND_PREMATURE_FINISH_TIMER] = sConfig.GetIntDefault ("BattleGround.PrematureFinishTimer", 5 * MINUTE * IN_MILISECONDS);
|
||||
m_configs[CONFIG_BATTLEGROUND_PREMADE_GROUP_WAIT_FOR_MATCH] = sConfig.GetIntDefault ("BattleGround.PremadeGroupWaitForMatch", 30 * MINUTE * IN_MILISECONDS);
|
||||
m_configs[CONFIG_BATTLEGROUND_PREMATURE_FINISH_TIMER] = sConfig.GetIntDefault ("BattleGround.PrematureFinishTimer", 5 * MINUTE * IN_MILLISECONDS);
|
||||
m_configs[CONFIG_BATTLEGROUND_PREMADE_GROUP_WAIT_FOR_MATCH] = sConfig.GetIntDefault ("BattleGround.PremadeGroupWaitForMatch", 30 * MINUTE * IN_MILLISECONDS);
|
||||
m_configs[CONFIG_BG_XP_FOR_KILL] = sConfig.GetBoolDefault("Battleground.GiveXPForKills", false);
|
||||
m_configs[CONFIG_ARENA_MAX_RATING_DIFFERENCE] = sConfig.GetIntDefault ("Arena.MaxRatingDifference", 150);
|
||||
m_configs[CONFIG_ARENA_RATING_DISCARD_TIMER] = sConfig.GetIntDefault ("Arena.RatingDiscardTimer", 10 * MINUTE * IN_MILISECONDS);
|
||||
m_configs[CONFIG_ARENA_RATING_DISCARD_TIMER] = sConfig.GetIntDefault ("Arena.RatingDiscardTimer", 10 * MINUTE * IN_MILLISECONDS);
|
||||
m_configs[CONFIG_ARENA_AUTO_DISTRIBUTE_POINTS] = sConfig.GetBoolDefault("Arena.AutoDistributePoints", false);
|
||||
m_configs[CONFIG_ARENA_AUTO_DISTRIBUTE_INTERVAL_DAYS] = sConfig.GetIntDefault ("Arena.AutoDistributeInterval", 7);
|
||||
m_configs[CONFIG_ARENA_QUEUE_ANNOUNCER_ENABLE] = sConfig.GetBoolDefault("Arena.QueueAnnouncer.Enable", false);
|
||||
@@ -1637,24 +1637,24 @@ void World::SetInitialWorldSettings()
|
||||
|
||||
static uint32 abtimer = 0;
|
||||
abtimer = sConfig.GetIntDefault("AutoBroadcast.Timer", 60000);
|
||||
m_timers[WUPDATE_OBJECTS].SetInterval(IN_MILISECONDS/2);
|
||||
m_timers[WUPDATE_OBJECTS].SetInterval(IN_MILLISECONDS/2);
|
||||
m_timers[WUPDATE_SESSIONS].SetInterval(0);
|
||||
m_timers[WUPDATE_WEATHERS].SetInterval(1*IN_MILISECONDS);
|
||||
m_timers[WUPDATE_AUCTIONS].SetInterval(MINUTE*IN_MILISECONDS);
|
||||
m_timers[WUPDATE_UPTIME].SetInterval(m_configs[CONFIG_UPTIME_UPDATE]*MINUTE*IN_MILISECONDS);
|
||||
m_timers[WUPDATE_WEATHERS].SetInterval(1*IN_MILLISECONDS);
|
||||
m_timers[WUPDATE_AUCTIONS].SetInterval(MINUTE*IN_MILLISECONDS);
|
||||
m_timers[WUPDATE_UPTIME].SetInterval(m_configs[CONFIG_UPTIME_UPDATE]*MINUTE*IN_MILLISECONDS);
|
||||
//Update "uptime" table based on configuration entry in minutes.
|
||||
m_timers[WUPDATE_CORPSES].SetInterval(20*MINUTE*IN_MILISECONDS);
|
||||
m_timers[WUPDATE_CORPSES].SetInterval(20*MINUTE*IN_MILLISECONDS);
|
||||
//erase corpses every 20 minutes
|
||||
m_timers[WUPDATE_CLEANDB].SetInterval(m_configs[CONFIG_LOGDB_CLEARINTERVAL]*MINUTE*IN_MILISECONDS);
|
||||
m_timers[WUPDATE_CLEANDB].SetInterval(m_configs[CONFIG_LOGDB_CLEARINTERVAL]*MINUTE*IN_MILLISECONDS);
|
||||
// clean logs table every 14 days by default
|
||||
m_timers[WUPDATE_AUTOBROADCAST].SetInterval(abtimer);
|
||||
|
||||
//to set mailtimer to return mails every day between 4 and 5 am
|
||||
//mailtimer is increased when updating auctions
|
||||
//one second is 1000 -(tested on win system)
|
||||
mail_timer = ((((localtime(&m_gameTime)->tm_hour + 20) % 24)* HOUR * IN_MILISECONDS) / m_timers[WUPDATE_AUCTIONS].GetInterval());
|
||||
mail_timer = ((((localtime(&m_gameTime)->tm_hour + 20) % 24)* HOUR * IN_MILLISECONDS) / m_timers[WUPDATE_AUCTIONS].GetInterval());
|
||||
//1440
|
||||
mail_timer_expires = ((DAY * IN_MILISECONDS) / (m_timers[WUPDATE_AUCTIONS].GetInterval()));
|
||||
mail_timer_expires = ((DAY * IN_MILLISECONDS) / (m_timers[WUPDATE_AUCTIONS].GetInterval()));
|
||||
sLog.outDebug("Mail timer set to: %u, mail return is called every %u minutes", mail_timer, mail_timer_expires);
|
||||
|
||||
///- Initilize static helper structures
|
||||
|
||||
@@ -63,13 +63,13 @@ struct mob_av_marshal_or_warmasterAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiChargeTimer = urand(2*IN_MILISECONDS,12*IN_MILISECONDS);
|
||||
uiCleaveTimer = urand(1*IN_MILISECONDS,11*IN_MILISECONDS);
|
||||
uiDemoralizingShoutTimer = urand(2*IN_MILISECONDS,2*IN_MILISECONDS);
|
||||
uiWhirlwind1Timer = urand(1*IN_MILISECONDS,12*IN_MILISECONDS);
|
||||
uiWhirlwind2Timer = urand(5*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiEnrageTimer = urand(5*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiChargeTimer = urand(2*IN_MILLISECONDS,12*IN_MILLISECONDS);
|
||||
uiCleaveTimer = urand(1*IN_MILLISECONDS,11*IN_MILLISECONDS);
|
||||
uiDemoralizingShoutTimer = urand(2*IN_MILLISECONDS,2*IN_MILLISECONDS);
|
||||
uiWhirlwind1Timer = urand(1*IN_MILLISECONDS,12*IN_MILLISECONDS);
|
||||
uiWhirlwind2Timer = urand(5*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
uiEnrageTimer = urand(5*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
|
||||
bHasAura = false;
|
||||
}
|
||||
@@ -120,37 +120,37 @@ struct mob_av_marshal_or_warmasterAI : public ScriptedAI
|
||||
if (uiChargeTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_CHARGE);
|
||||
uiChargeTimer = urand(10*IN_MILISECONDS,25*IN_MILISECONDS);
|
||||
uiChargeTimer = urand(10*IN_MILLISECONDS,25*IN_MILLISECONDS);
|
||||
} else uiChargeTimer -= diff;
|
||||
|
||||
if (uiCleaveTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_CLEAVE);
|
||||
uiCleaveTimer = urand(10*IN_MILISECONDS,16*IN_MILISECONDS);
|
||||
uiCleaveTimer = urand(10*IN_MILLISECONDS,16*IN_MILLISECONDS);
|
||||
} else uiCleaveTimer -= diff;
|
||||
|
||||
if (uiDemoralizingShoutTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_DEMORALIZING_SHOUT);
|
||||
uiDemoralizingShoutTimer = urand(10*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiDemoralizingShoutTimer = urand(10*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
} else uiDemoralizingShoutTimer -= diff;
|
||||
|
||||
if (uiWhirlwind1Timer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_WHIRLWIND1);
|
||||
uiWhirlwind1Timer = urand(6*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiWhirlwind1Timer = urand(6*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
} else uiWhirlwind1Timer -= diff;
|
||||
|
||||
if (uiWhirlwind2Timer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_WHIRLWIND2);
|
||||
uiWhirlwind2Timer = urand(10*IN_MILISECONDS,25*IN_MILISECONDS);
|
||||
uiWhirlwind2Timer = urand(10*IN_MILLISECONDS,25*IN_MILLISECONDS);
|
||||
} else uiWhirlwind2Timer -= diff;
|
||||
|
||||
if (uiEnrageTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_ENRAGE);
|
||||
uiEnrageTimer = urand(10*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiEnrageTimer = urand(10*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
}else uiEnrageTimer -= diff;
|
||||
|
||||
|
||||
@@ -159,7 +159,7 @@ struct mob_av_marshal_or_warmasterAI : public ScriptedAI
|
||||
{
|
||||
if (me->GetDistance2d(me->GetHomePosition().GetPositionX(), me->GetHomePosition().GetPositionY()) > 50)
|
||||
EnterEvadeMode();
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
} else uiResetTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -51,8 +51,8 @@ struct mob_water_elementalAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiWaterBoltTimer = 3*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiWaterBoltTimer = 3*IN_MILLISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -63,7 +63,7 @@ struct mob_water_elementalAI : public ScriptedAI
|
||||
if (uiWaterBoltTimer < diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_WATERBOLT);
|
||||
uiWaterBoltTimer = 5*IN_MILISECONDS;
|
||||
uiWaterBoltTimer = 5*IN_MILLISECONDS;
|
||||
} else uiWaterBoltTimer -= diff;
|
||||
|
||||
// check if creature is not outside of building
|
||||
@@ -72,7 +72,7 @@ struct mob_water_elementalAI : public ScriptedAI
|
||||
if (Creature *pBalinda = Unit::GetCreature(*me, uiBalindaGUID))
|
||||
if (me->GetDistance2d(pBalinda->GetHomePosition().GetPositionX(), pBalinda->GetHomePosition().GetPositionY()) > 50)
|
||||
EnterEvadeMode();
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
} else uiResetTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -94,11 +94,11 @@ struct boss_balindaAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiArcaneExplosionTimer = urand(5*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiConeOfColdTimer = 8*IN_MILISECONDS;
|
||||
uiFireBoltTimer = 1*IN_MILISECONDS;
|
||||
uiFrostboltTimer = 4*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiArcaneExplosionTimer = urand(5*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
uiConeOfColdTimer = 8*IN_MILLISECONDS;
|
||||
uiFireBoltTimer = 1*IN_MILLISECONDS;
|
||||
uiFrostboltTimer = 4*IN_MILLISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
uiWaterElementalTimer = 0;
|
||||
|
||||
Summons.DespawnAll();
|
||||
@@ -135,32 +135,32 @@ struct boss_balindaAI : public ScriptedAI
|
||||
if (uiWaterElementalTimer < diff)
|
||||
{
|
||||
if (Summons.empty())
|
||||
me->SummonCreature(NPC_WATER_ELEMENTAL, 0, 0, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 45*IN_MILISECONDS);
|
||||
uiWaterElementalTimer = 50*IN_MILISECONDS;
|
||||
me->SummonCreature(NPC_WATER_ELEMENTAL, 0, 0, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 45*IN_MILLISECONDS);
|
||||
uiWaterElementalTimer = 50*IN_MILLISECONDS;
|
||||
} else uiWaterElementalTimer -= diff;
|
||||
|
||||
if (uiArcaneExplosionTimer < diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_ARCANE_EXPLOSION);
|
||||
uiArcaneExplosionTimer = urand(5*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiArcaneExplosionTimer = urand(5*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
} else uiArcaneExplosionTimer -= diff;
|
||||
|
||||
if (uiConeOfColdTimer < diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_CONE_OF_COLD);
|
||||
uiConeOfColdTimer = urand(10*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiConeOfColdTimer = urand(10*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
} else uiConeOfColdTimer -= diff;
|
||||
|
||||
if (uiFireBoltTimer < diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_FIREBALL);
|
||||
uiFireBoltTimer = urand(5*IN_MILISECONDS,9*IN_MILISECONDS);
|
||||
uiFireBoltTimer = urand(5*IN_MILLISECONDS,9*IN_MILLISECONDS);
|
||||
} else uiFireBoltTimer -= diff;
|
||||
|
||||
if (uiFrostboltTimer < diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_FROSTBOLT);
|
||||
uiFrostboltTimer = urand(4*IN_MILISECONDS,12*IN_MILISECONDS);
|
||||
uiFrostboltTimer = urand(4*IN_MILLISECONDS,12*IN_MILLISECONDS);
|
||||
} else uiFrostboltTimer -= diff;
|
||||
|
||||
|
||||
@@ -172,7 +172,7 @@ struct boss_balindaAI : public ScriptedAI
|
||||
EnterEvadeMode();
|
||||
DoScriptText(YELL_EVADE, me);
|
||||
}
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
} else uiResetTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -54,12 +54,12 @@ struct boss_drektharAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiWhirlwindTimer = urand(1*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiWhirlwind2Timer = urand(1*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiKnockdownTimer = 12*IN_MILISECONDS;
|
||||
uiFrenzyTimer = 6*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiYellTimer = urand(20*IN_MILISECONDS,30*IN_MILISECONDS); //20 to 30 seconds
|
||||
uiWhirlwindTimer = urand(1*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
uiWhirlwind2Timer = urand(1*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
uiKnockdownTimer = 12*IN_MILLISECONDS;
|
||||
uiFrenzyTimer = 6*IN_MILLISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
uiYellTimer = urand(20*IN_MILLISECONDS,30*IN_MILLISECONDS); //20 to 30 seconds
|
||||
}
|
||||
|
||||
void Aggro(Unit * /*who*/)
|
||||
@@ -81,31 +81,31 @@ struct boss_drektharAI : public ScriptedAI
|
||||
if (uiWhirlwindTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_WHIRLWIND);
|
||||
uiWhirlwindTimer = urand(8*IN_MILISECONDS,18*IN_MILISECONDS);
|
||||
uiWhirlwindTimer = urand(8*IN_MILLISECONDS,18*IN_MILLISECONDS);
|
||||
} else uiWhirlwindTimer -= diff;
|
||||
|
||||
if (uiWhirlwind2Timer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_WHIRLWIND2);
|
||||
uiWhirlwind2Timer = urand(7*IN_MILISECONDS,25*IN_MILISECONDS);
|
||||
uiWhirlwind2Timer = urand(7*IN_MILLISECONDS,25*IN_MILLISECONDS);
|
||||
} else uiWhirlwind2Timer -= diff;
|
||||
|
||||
if (uiKnockdownTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_KNOCKDOWN);
|
||||
uiKnockdownTimer = urand(10*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiKnockdownTimer = urand(10*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
} else uiKnockdownTimer -= diff;
|
||||
|
||||
if (uiFrenzyTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_FRENZY);
|
||||
uiFrenzyTimer = urand(20*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiFrenzyTimer = urand(20*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiFrenzyTimer -= diff;
|
||||
|
||||
if (uiYellTimer <= diff)
|
||||
{
|
||||
DoScriptText(RAND(YELL_RANDOM1,YELL_RANDOM2,YELL_RANDOM3,YELL_RANDOM4,YELL_RANDOM5), me);
|
||||
uiYellTimer = urand(20*IN_MILISECONDS,30*IN_MILISECONDS); //20 to 30 seconds
|
||||
uiYellTimer = urand(20*IN_MILLISECONDS,30*IN_MILLISECONDS); //20 to 30 seconds
|
||||
} else uiYellTimer -= diff;
|
||||
|
||||
// check if creature is not outside of building
|
||||
@@ -116,7 +116,7 @@ struct boss_drektharAI : public ScriptedAI
|
||||
EnterEvadeMode();
|
||||
DoScriptText(YELL_EVADE, me);
|
||||
}
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
} else uiResetTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -47,12 +47,12 @@ struct boss_galvangarAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiCleaveTimer = urand(1*IN_MILISECONDS,9*IN_MILISECONDS);
|
||||
uiFrighteningShoutTimer = urand(2*IN_MILISECONDS,19*IN_MILISECONDS);
|
||||
uiWhirlwind1Timer = urand(1*IN_MILISECONDS,13*IN_MILISECONDS);
|
||||
uiWhirlwind2Timer = urand(5*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiMortalStrikeTimer = urand(5*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiCleaveTimer = urand(1*IN_MILLISECONDS,9*IN_MILLISECONDS);
|
||||
uiFrighteningShoutTimer = urand(2*IN_MILLISECONDS,19*IN_MILLISECONDS);
|
||||
uiWhirlwind1Timer = urand(1*IN_MILLISECONDS,13*IN_MILLISECONDS);
|
||||
uiWhirlwind2Timer = urand(5*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
uiMortalStrikeTimer = urand(5*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void Aggro(Unit * /*who*/)
|
||||
@@ -73,31 +73,31 @@ struct boss_galvangarAI : public ScriptedAI
|
||||
if (uiCleaveTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_CLEAVE);
|
||||
uiCleaveTimer = urand(10*IN_MILISECONDS,16*IN_MILISECONDS);
|
||||
uiCleaveTimer = urand(10*IN_MILLISECONDS,16*IN_MILLISECONDS);
|
||||
} else uiCleaveTimer -= diff;
|
||||
|
||||
if (uiFrighteningShoutTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_FRIGHTENING_SHOUT);
|
||||
uiFrighteningShoutTimer = urand(10*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiFrighteningShoutTimer = urand(10*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
} else uiFrighteningShoutTimer -= diff;
|
||||
|
||||
if (uiWhirlwind1Timer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_WHIRLWIND1);
|
||||
uiWhirlwind1Timer = urand(6*IN_MILISECONDS,10*IN_MILISECONDS);
|
||||
uiWhirlwind1Timer = urand(6*IN_MILLISECONDS,10*IN_MILLISECONDS);
|
||||
} else uiWhirlwind1Timer -= diff;
|
||||
|
||||
if (uiWhirlwind2Timer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_WHIRLWIND2);
|
||||
uiWhirlwind2Timer = urand(10*IN_MILISECONDS,25*IN_MILISECONDS);
|
||||
uiWhirlwind2Timer = urand(10*IN_MILLISECONDS,25*IN_MILLISECONDS);
|
||||
} else uiWhirlwind2Timer -= diff;
|
||||
|
||||
if (uiMortalStrikeTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_MORTAL_STRIKE);
|
||||
uiMortalStrikeTimer = urand(10*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiMortalStrikeTimer = urand(10*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiMortalStrikeTimer -= diff;
|
||||
|
||||
// check if creature is not outside of building
|
||||
@@ -108,7 +108,7 @@ struct boss_galvangarAI : public ScriptedAI
|
||||
EnterEvadeMode();
|
||||
DoScriptText(YELL_EVADE, me);
|
||||
}
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
} else uiResetTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -53,11 +53,11 @@ struct boss_vanndarAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiAvatarTimer = 3*IN_MILISECONDS;
|
||||
uiThunderclapTimer = 4*IN_MILISECONDS;
|
||||
uiStormboltTimer = 6*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiYellTimer = urand(20*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiAvatarTimer = 3*IN_MILLISECONDS;
|
||||
uiThunderclapTimer = 4*IN_MILLISECONDS;
|
||||
uiStormboltTimer = 6*IN_MILLISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
uiYellTimer = urand(20*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
}
|
||||
|
||||
void Aggro(Unit * /*who*/)
|
||||
@@ -79,25 +79,25 @@ struct boss_vanndarAI : public ScriptedAI
|
||||
if (uiAvatarTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_AVATAR);
|
||||
uiAvatarTimer = urand(15*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiAvatarTimer = urand(15*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
} else uiAvatarTimer -= diff;
|
||||
|
||||
if (uiThunderclapTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_THUNDERCLAP);
|
||||
uiThunderclapTimer = urand(5*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiThunderclapTimer = urand(5*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
} else uiThunderclapTimer -= diff;
|
||||
|
||||
if (uiStormboltTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_STORMBOLT);
|
||||
uiStormboltTimer = urand(10*IN_MILISECONDS,25*IN_MILISECONDS);
|
||||
uiStormboltTimer = urand(10*IN_MILLISECONDS,25*IN_MILLISECONDS);
|
||||
} else uiStormboltTimer -= diff;
|
||||
|
||||
if (uiYellTimer <= diff)
|
||||
{
|
||||
DoScriptText(RAND(YELL_RANDOM1,YELL_RANDOM2,YELL_RANDOM3,YELL_RANDOM4,YELL_RANDOM5,YELL_RANDOM6,YELL_RANDOM7), me);
|
||||
uiYellTimer = urand(20*IN_MILISECONDS,30*IN_MILISECONDS); //20 to 30 seconds
|
||||
uiYellTimer = urand(20*IN_MILLISECONDS,30*IN_MILLISECONDS); //20 to 30 seconds
|
||||
} else uiYellTimer -= diff;
|
||||
|
||||
// check if creature is not outside of building
|
||||
@@ -108,7 +108,7 @@ struct boss_vanndarAI : public ScriptedAI
|
||||
EnterEvadeMode();
|
||||
DoScriptText(YELL_EVADE, me);
|
||||
}
|
||||
uiResetTimer = 5*IN_MILISECONDS;
|
||||
uiResetTimer = 5*IN_MILLISECONDS;
|
||||
} else uiResetTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -56,7 +56,7 @@ bool GOHello_rookey_egg(Player *pPlayer, GameObject * /*pGO*/)
|
||||
{
|
||||
Position pos;
|
||||
pPlayer->GetPosition(&pos);
|
||||
pPlayer->SummonCreature(NPC_ROOKERY_WHELP, pos, TEMPSUMMON_TIMED_DESPAWN, 15*IN_MILISECONDS);
|
||||
pPlayer->SummonCreature(NPC_ROOKERY_WHELP, pos, TEMPSUMMON_TIMED_DESPAWN, 15*IN_MILLISECONDS);
|
||||
//destroy gobject need to be implemented
|
||||
|
||||
return true;
|
||||
|
||||
@@ -35,7 +35,7 @@ struct instance_blackrock_spire : public ScriptedInstance
|
||||
|
||||
void Initialize()
|
||||
{
|
||||
uiLeeroyTimer = 15*IN_MILISECONDS;
|
||||
uiLeeroyTimer = 15*IN_MILLISECONDS;
|
||||
uiWhelpCount = 0;
|
||||
bLeeeeeeeeroy = true;
|
||||
uiLeroyData = 0;
|
||||
|
||||
@@ -94,7 +94,7 @@ void SummonCroneIfReady(ScriptedInstance* pInstance, Creature* pCreature)
|
||||
|
||||
if (pInstance->GetData(DATA_OPERA_OZ_DEATHCOUNT) == 4)
|
||||
{
|
||||
if (Creature* pCrone = pCreature->SummonCreature(CREATURE_CRONE, -10891.96, -1755.95, pCreature->GetPositionZ(), 4.64, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILISECONDS))
|
||||
if (Creature* pCrone = pCreature->SummonCreature(CREATURE_CRONE, -10891.96, -1755.95, pCreature->GetPositionZ(), 4.64, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILLISECONDS))
|
||||
{
|
||||
if (pCreature->getVictim())
|
||||
pCrone->AI()->AttackStart(pCreature->getVictim());
|
||||
@@ -727,7 +727,7 @@ bool GossipSelect_npc_grandmother(Player* pPlayer, Creature* pCreature, uint32 /
|
||||
{
|
||||
if (uiAction == GOSSIP_ACTION_INFO_DEF)
|
||||
{
|
||||
if (Creature* pBigBadWolf = pCreature->SummonCreature(CREATURE_BIG_BAD_WOLF, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILISECONDS))
|
||||
if (Creature* pBigBadWolf = pCreature->SummonCreature(CREATURE_BIG_BAD_WOLF, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILLISECONDS))
|
||||
pBigBadWolf->AI()->AttackStart(pPlayer);
|
||||
|
||||
pCreature->ForcedDespawn();
|
||||
@@ -1285,7 +1285,7 @@ void boss_julianneAI::UpdateAI(const uint32 diff)
|
||||
{
|
||||
if (SummonRomuloTimer <= diff)
|
||||
{
|
||||
if (Creature* pRomulo = me->SummonCreature(CREATURE_ROMULO, ROMULO_X, ROMULO_Y, me->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILISECONDS))
|
||||
if (Creature* pRomulo = me->SummonCreature(CREATURE_ROMULO, ROMULO_X, ROMULO_Y, me->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILLISECONDS))
|
||||
{
|
||||
RomuloGUID = pRomulo->GetGUID();
|
||||
CAST_AI(boss_romuloAI, pRomulo->AI())->JulianneGUID = me->GetGUID();
|
||||
|
||||
@@ -247,7 +247,7 @@ struct npc_barnesAI : public npc_escortAI
|
||||
uint32 entry = ((uint32)Spawns[index][0]);
|
||||
float PosX = Spawns[index][1];
|
||||
|
||||
if (Creature* pCreature = me->SummonCreature(entry, PosX, SPAWN_Y, SPAWN_Z, SPAWN_O, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILISECONDS))
|
||||
if (Creature* pCreature = me->SummonCreature(entry, PosX, SPAWN_Y, SPAWN_Z, SPAWN_O, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, HOUR*2*IN_MILLISECONDS))
|
||||
{
|
||||
// In case database has bad flags
|
||||
pCreature->SetUInt32Value(UNIT_FIELD_FLAGS, 0);
|
||||
|
||||
@@ -72,7 +72,7 @@ struct npc_kalecgosAI : public ScriptedAI
|
||||
return;
|
||||
|
||||
if (uiPointId == POINT_ID_LAND)
|
||||
m_uiTransformTimer = MINUTE*IN_MILISECONDS;
|
||||
m_uiTransformTimer = MINUTE*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
// some targeting issues with the spell, so use this workaround as temporary solution
|
||||
|
||||
@@ -55,9 +55,9 @@ struct boss_golemaggAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
m_uiPyroblastTimer = 7*IN_MILISECONDS; // These timers are probably wrong
|
||||
m_uiEarthquakeTimer = 3*IN_MILISECONDS;
|
||||
m_uiBuffTimer = 2.5*IN_MILISECONDS;
|
||||
m_uiPyroblastTimer = 7*IN_MILLISECONDS; // These timers are probably wrong
|
||||
m_uiEarthquakeTimer = 3*IN_MILLISECONDS;
|
||||
m_uiBuffTimer = 2.5*IN_MILLISECONDS;
|
||||
m_bEnraged = false;
|
||||
|
||||
DoCast(me, SPELL_MAGMASPLASH, true);
|
||||
@@ -80,7 +80,7 @@ struct boss_golemaggAI : public ScriptedAI
|
||||
if (Unit* pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_PYROBLAST);
|
||||
|
||||
m_uiPyroblastTimer = 7*IN_MILISECONDS;
|
||||
m_uiPyroblastTimer = 7*IN_MILLISECONDS;
|
||||
}
|
||||
else
|
||||
m_uiPyroblastTimer -= uiDiff;
|
||||
@@ -98,7 +98,7 @@ struct boss_golemaggAI : public ScriptedAI
|
||||
if (m_uiEarthquakeTimer <= uiDiff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_EARTHQUAKE);
|
||||
m_uiEarthquakeTimer = 3*IN_MILISECONDS;
|
||||
m_uiEarthquakeTimer = 3*IN_MILLISECONDS;
|
||||
}
|
||||
else
|
||||
m_uiEarthquakeTimer -= uiDiff;
|
||||
@@ -109,7 +109,7 @@ struct boss_golemaggAI : public ScriptedAI
|
||||
if (m_uiBuffTimer <= uidiff)
|
||||
{
|
||||
DoCast(me, SPELL_GOLEMAGG_TRUST);
|
||||
m_uiBuffTimer = 2.5*IN_MILISECONDS;
|
||||
m_uiBuffTimer = 2.5*IN_MILLISECONDS;
|
||||
}
|
||||
else
|
||||
m_uiBuffTimer -= uiDiff;
|
||||
@@ -132,7 +132,7 @@ struct mob_core_ragerAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
m_uiMangleTimer = 7*IN_MILISECONDS; // These times are probably wrong
|
||||
m_uiMangleTimer = 7*IN_MILLISECONDS; // These times are probably wrong
|
||||
}
|
||||
|
||||
void DamageTaken(Unit* /*pDoneBy*/, uint32& uiDamage)
|
||||
@@ -164,7 +164,7 @@ struct mob_core_ragerAI : public ScriptedAI
|
||||
if (m_uiMangleTimer <= uiDiff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_MANGLE);
|
||||
m_uiMangleTimer = 10*IN_MILISECONDS;
|
||||
m_uiMangleTimer = 10*IN_MILLISECONDS;
|
||||
}
|
||||
else
|
||||
m_uiMangleTimer -= uiDiff;
|
||||
|
||||
@@ -102,7 +102,7 @@ struct boss_dathrohan_balnazzarAI : public ScriptedAI
|
||||
for (uint8 i=0; i<uiCount; ++i)
|
||||
me->SummonCreature(NPC_ZOMBIE,
|
||||
m_aSummonPoint[i].m_fX, m_aSummonPoint[i].m_fY, m_aSummonPoint[i].m_fZ, m_aSummonPoint[i].m_fOrient,
|
||||
TEMPSUMMON_TIMED_DESPAWN, HOUR*IN_MILISECONDS);
|
||||
TEMPSUMMON_TIMED_DESPAWN, HOUR*IN_MILLISECONDS);
|
||||
}
|
||||
|
||||
void EnterCombat(Unit * /*who*/)
|
||||
|
||||
@@ -96,7 +96,7 @@ struct boss_akilzonAI : public ScriptedAI
|
||||
GustOfWind_Timer = urand(20000,30000); //20 to 30 seconds(bosskillers)
|
||||
CallLighting_Timer = urand(10000,20000); //totaly random timer. can't find any info on this
|
||||
ElectricalStorm_Timer = 60000; //60 seconds(bosskillers)
|
||||
Enrage_Timer = 10*MINUTE*IN_MILISECONDS; //10 minutes till enrage(bosskillers)
|
||||
Enrage_Timer = 10*MINUTE*IN_MILLISECONDS; //10 minutes till enrage(bosskillers)
|
||||
SummonEagles_Timer = 99999;
|
||||
|
||||
TargetGUID = 0;
|
||||
|
||||
@@ -143,7 +143,7 @@ struct boss_janalaiAI : public ScriptedAI
|
||||
BombSequenceTimer = 1000;
|
||||
BombCount = 0;
|
||||
HatcherTimer = 10000;
|
||||
EnrageTimer = MINUTE*5*IN_MILISECONDS;
|
||||
EnrageTimer = MINUTE*5*IN_MILLISECONDS;
|
||||
|
||||
noeggs = false;
|
||||
isBombing =false;
|
||||
|
||||
@@ -137,7 +137,7 @@ struct instance_onyxias_lair : public ScriptedInstance
|
||||
{
|
||||
m_bAchievManyWhelpsHandleIt = false;
|
||||
m_uiManyWhelpsCounter = 0;
|
||||
m_uiOnyxiaLiftoffTimer = 10*IN_MILISECONDS;
|
||||
m_uiOnyxiaLiftoffTimer = 10*IN_MILLISECONDS;
|
||||
}
|
||||
break;
|
||||
case DATA_SHE_DEEP_BREATH_MORE:
|
||||
|
||||
@@ -117,10 +117,10 @@ struct boss_anub_arakAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiCarrionBeetlesTimer = 8*IN_MILISECONDS;
|
||||
uiLeechingSwarmTimer = 20*IN_MILISECONDS;
|
||||
uiImpaleTimer = 9*IN_MILISECONDS;
|
||||
uiPoundTimer = 15*IN_MILISECONDS;
|
||||
uiCarrionBeetlesTimer = 8*IN_MILLISECONDS;
|
||||
uiLeechingSwarmTimer = 20*IN_MILLISECONDS;
|
||||
uiImpaleTimer = 9*IN_MILLISECONDS;
|
||||
uiPoundTimer = 15*IN_MILLISECONDS;
|
||||
|
||||
uiPhase = PHASE_MELEE;
|
||||
uiUndergroundPhase = 0;
|
||||
@@ -144,7 +144,7 @@ struct boss_anub_arakAI : public ScriptedAI
|
||||
Position targetPos;
|
||||
pTarget->GetPosition(&targetPos);
|
||||
|
||||
if (TempSummon* pImpaleTarget = me->SummonCreature(CREATURE_IMPALE_TARGET, targetPos, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 6*IN_MILISECONDS))
|
||||
if (TempSummon* pImpaleTarget = me->SummonCreature(CREATURE_IMPALE_TARGET, targetPos, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 6*IN_MILLISECONDS))
|
||||
{
|
||||
uiImpaleTarget = pImpaleTarget->GetGUID();
|
||||
pImpaleTarget->SetReactState(REACT_PASSIVE);
|
||||
@@ -183,7 +183,7 @@ struct boss_anub_arakAI : public ScriptedAI
|
||||
{
|
||||
if (Creature *pImpaleTarget = DoSummonImpaleTarget(target))
|
||||
pImpaleTarget->CastSpell(pImpaleTarget, SPELL_IMPALE_SHAKEGROUND, true);
|
||||
uiImpaleTimer = 3*IN_MILISECONDS;
|
||||
uiImpaleTimer = 3*IN_MILLISECONDS;
|
||||
uiImpalePhase = IMPALE_PHASE_ATTACK;
|
||||
}
|
||||
break;
|
||||
@@ -194,13 +194,13 @@ struct boss_anub_arakAI : public ScriptedAI
|
||||
pImpaleTarget->RemoveAurasDueToSpell(SPELL_IMPALE_SHAKEGROUND);
|
||||
}
|
||||
uiImpalePhase = IMPALE_PHASE_DMG;
|
||||
uiImpaleTimer = 1*IN_MILISECONDS;
|
||||
uiImpaleTimer = 1*IN_MILLISECONDS;
|
||||
break;
|
||||
case IMPALE_PHASE_DMG:
|
||||
if (Creature* pImpaleTarget = Unit::GetCreature(*me, uiImpaleTarget))
|
||||
me->CastSpell(pImpaleTarget, DUNGEON_MODE(SPELL_IMPALE_DMG, SPELL_IMPALE_DMG_H), true);
|
||||
uiImpalePhase = IMPALE_PHASE_TARGET;
|
||||
uiImpaleTimer = 9*IN_MILISECONDS;
|
||||
uiImpaleTimer = 9*IN_MILLISECONDS;
|
||||
break;
|
||||
}
|
||||
} else uiImpaleTimer -= diff;
|
||||
@@ -274,12 +274,12 @@ struct boss_anub_arakAI : public ScriptedAI
|
||||
bVenomancerSummoned = false;
|
||||
bDatterSummoned = false;
|
||||
|
||||
uiUndergroundTimer = 40*IN_MILISECONDS;
|
||||
uiVenomancerTimer = 25*IN_MILISECONDS;
|
||||
uiDatterTimer = 32*IN_MILISECONDS;
|
||||
uiUndergroundTimer = 40*IN_MILLISECONDS;
|
||||
uiVenomancerTimer = 25*IN_MILLISECONDS;
|
||||
uiDatterTimer = 32*IN_MILLISECONDS;
|
||||
|
||||
uiImpalePhase = 0;
|
||||
uiImpaleTimer = 9*IN_MILISECONDS;
|
||||
uiImpaleTimer = 9*IN_MILLISECONDS;
|
||||
|
||||
DoCast(me, SPELL_SUBMERGE, false);
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE|UNIT_FLAG_NOT_SELECTABLE);
|
||||
@@ -298,13 +298,13 @@ struct boss_anub_arakAI : public ScriptedAI
|
||||
{
|
||||
bChanneling = true;
|
||||
DoCastVictim(SPELL_CARRION_BEETLES);
|
||||
uiCarrionBeetlesTimer = 25*IN_MILISECONDS;
|
||||
uiCarrionBeetlesTimer = 25*IN_MILLISECONDS;
|
||||
} else uiCarrionBeetlesTimer -= diff;
|
||||
|
||||
if (uiLeechingSwarmTimer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_LEECHING_SWARM, true);
|
||||
uiLeechingSwarmTimer = 19*IN_MILISECONDS;
|
||||
uiLeechingSwarmTimer = 19*IN_MILLISECONDS;
|
||||
} else uiLeechingSwarmTimer -= diff;
|
||||
|
||||
if (uiPoundTimer <= diff)
|
||||
@@ -314,7 +314,7 @@ struct boss_anub_arakAI : public ScriptedAI
|
||||
if (Creature *pImpaleTarget = DoSummonImpaleTarget(target))
|
||||
me->CastSpell(pImpaleTarget, DUNGEON_MODE(SPELL_POUND, SPELL_POUND_H), false);
|
||||
}
|
||||
uiPoundTimer = 16.5*IN_MILISECONDS;
|
||||
uiPoundTimer = 16.5*IN_MILLISECONDS;
|
||||
} else uiPoundTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -71,12 +71,12 @@ struct boss_hadronoxAI : public ScriptedAI
|
||||
me->SetFloatValue(UNIT_FIELD_BOUNDINGRADIUS, 9.0f);
|
||||
me->SetFloatValue(UNIT_FIELD_COMBATREACH, 9.0f);
|
||||
|
||||
uiAcidTimer = urand(10*IN_MILISECONDS,14*IN_MILISECONDS);
|
||||
uiLeechTimer = urand(3*IN_MILISECONDS,9*IN_MILISECONDS);
|
||||
uiPierceTimer = urand(1*IN_MILISECONDS,3*IN_MILISECONDS);
|
||||
uiGrabTimer = urand(15*IN_MILISECONDS,19*IN_MILISECONDS);
|
||||
uiDoorsTimer = urand(20*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiCheckDistanceTimer = 2*IN_MILISECONDS;
|
||||
uiAcidTimer = urand(10*IN_MILLISECONDS,14*IN_MILLISECONDS);
|
||||
uiLeechTimer = urand(3*IN_MILLISECONDS,9*IN_MILLISECONDS);
|
||||
uiPierceTimer = urand(1*IN_MILLISECONDS,3*IN_MILLISECONDS);
|
||||
uiGrabTimer = urand(15*IN_MILLISECONDS,19*IN_MILLISECONDS);
|
||||
uiDoorsTimer = urand(20*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
uiCheckDistanceTimer = 2*IN_MILLISECONDS;
|
||||
|
||||
if (pInstance && (pInstance->GetData(DATA_HADRONOX_EVENT) != DONE && !bFirstTime))
|
||||
pInstance->SetData(DATA_HADRONOX_EVENT, FAIL);
|
||||
@@ -121,7 +121,7 @@ struct boss_hadronoxAI : public ScriptedAI
|
||||
me->GetRespawnCoord(x,y,z);
|
||||
|
||||
if (uiCheckDistanceTimer <= uiDiff)
|
||||
uiCheckDistanceTimer = 5*IN_MILISECONDS;
|
||||
uiCheckDistanceTimer = 5*IN_MILLISECONDS;
|
||||
else
|
||||
{
|
||||
uiCheckDistanceTimer -= uiDiff;
|
||||
@@ -152,7 +152,7 @@ struct boss_hadronoxAI : public ScriptedAI
|
||||
if (uiPierceTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_PIERCE_ARMOR);
|
||||
uiPierceTimer = 8*IN_MILISECONDS;
|
||||
uiPierceTimer = 8*IN_MILLISECONDS;
|
||||
} else uiPierceTimer -= diff;
|
||||
|
||||
if (uiAcidTimer <= diff)
|
||||
@@ -160,7 +160,7 @@ struct boss_hadronoxAI : public ScriptedAI
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_ACID_CLOUD);
|
||||
|
||||
uiAcidTimer = urand(20*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiAcidTimer = urand(20*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiAcidTimer -= diff;
|
||||
|
||||
if (uiLeechTimer <= diff)
|
||||
@@ -168,7 +168,7 @@ struct boss_hadronoxAI : public ScriptedAI
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_LEECH_POISON);
|
||||
|
||||
uiLeechTimer = urand(11*IN_MILISECONDS,14*IN_MILISECONDS);
|
||||
uiLeechTimer = urand(11*IN_MILLISECONDS,14*IN_MILLISECONDS);
|
||||
} else uiLeechTimer -= diff;
|
||||
|
||||
if (uiGrabTimer <= diff)
|
||||
@@ -176,13 +176,13 @@ struct boss_hadronoxAI : public ScriptedAI
|
||||
if (Unit* pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0)) // Draws all players (and attacking Mobs) to itself.
|
||||
DoCast(pTarget, SPELL_WEB_GRAB);
|
||||
|
||||
uiGrabTimer = urand(15*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiGrabTimer = urand(15*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiGrabTimer -= diff;
|
||||
|
||||
if (uiDoorsTimer <= diff)
|
||||
{
|
||||
//DoCast(me, RAND(SPELL_WEB_FRONT_DOORS, SPELL_WEB_SIDE_DOORS));
|
||||
uiDoorsTimer = urand(30*IN_MILISECONDS,60*IN_MILISECONDS);
|
||||
uiDoorsTimer = urand(30*IN_MILLISECONDS,60*IN_MILLISECONDS);
|
||||
} else uiDoorsTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
+50
-50
@@ -106,8 +106,8 @@ struct boss_krik_thirAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiMindFlayTimer = 15*IN_MILISECONDS;
|
||||
uiCurseFatigueTimer = 12*IN_MILISECONDS;
|
||||
uiMindFlayTimer = 15*IN_MILLISECONDS;
|
||||
uiCurseFatigueTimer = 12*IN_MILLISECONDS;
|
||||
|
||||
if (pInstance)
|
||||
pInstance->SetData(DATA_KRIKTHIR_THE_GATEWATCHER_EVENT, NOT_STARTED);
|
||||
@@ -117,7 +117,7 @@ struct boss_krik_thirAI : public ScriptedAI
|
||||
{
|
||||
DoScriptText(SAY_AGGRO, me);
|
||||
Summon();
|
||||
uiSummonTimer = 15*IN_MILISECONDS;
|
||||
uiSummonTimer = 15*IN_MILLISECONDS;
|
||||
|
||||
if (pInstance)
|
||||
pInstance->SetData(DATA_KRIKTHIR_THE_GATEWATCHER_EVENT, IN_PROGRESS);
|
||||
@@ -125,22 +125,22 @@ struct boss_krik_thirAI : public ScriptedAI
|
||||
|
||||
void Summon()
|
||||
{
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[0],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[0],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[1],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[1],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[2],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[2],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[3],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[3],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_INFECTIOR,SpawnPoint[4],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[4],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_INFECTIOR,SpawnPoint[5],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[5],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_INFECTIOR,SpawnPoint[6],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[6],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[7],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[7],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[0],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[0],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[1],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[1],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[2],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[2],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[3],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[3],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_INFECTIOR,SpawnPoint[4],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[4],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_INFECTIOR,SpawnPoint[5],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[5],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_INFECTIOR,SpawnPoint[6],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[6],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[7],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
me->SummonCreature(MOB_SKITTERING_SWARMER,SpawnPoint[7],TEMPSUMMON_TIMED_DESPAWN,25*IN_MILLISECONDS);
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -151,13 +151,13 @@ struct boss_krik_thirAI : public ScriptedAI
|
||||
if (uiSummonTimer <= diff)
|
||||
{
|
||||
Summon();
|
||||
uiSummonTimer = 15*IN_MILISECONDS;
|
||||
uiSummonTimer = 15*IN_MILLISECONDS;
|
||||
} else uiSummonTimer -= diff;
|
||||
|
||||
if (uiMindFlayTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_MIND_FLAY);
|
||||
uiMindFlayTimer = 15*IN_MILISECONDS;
|
||||
uiMindFlayTimer = 15*IN_MILLISECONDS;
|
||||
} else uiMindFlayTimer -= diff;
|
||||
|
||||
if (uiCurseFatigueTimer <= diff)
|
||||
@@ -169,7 +169,7 @@ struct boss_krik_thirAI : public ScriptedAI
|
||||
DoCast(pTarget, SPELL_CURSE_OF_FATIGUE);
|
||||
DoCast(pTarget_1, SPELL_CURSE_OF_FATIGUE);
|
||||
|
||||
uiCurseFatigueTimer = 10*IN_MILISECONDS;
|
||||
uiCurseFatigueTimer = 10*IN_MILLISECONDS;
|
||||
} else uiCurseFatigueTimer -= diff;
|
||||
|
||||
if (!me->HasAura(SPELL_FRENZY) && HealthBelowPct(10))
|
||||
@@ -236,8 +236,8 @@ struct npc_anub_ar_skirmisherAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiChargeTimer = 11*IN_MILISECONDS;
|
||||
uiBackstabTimer = 7*IN_MILISECONDS;
|
||||
uiChargeTimer = 11*IN_MILLISECONDS;
|
||||
uiBackstabTimer = 7*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -253,13 +253,13 @@ struct npc_anub_ar_skirmisherAI : public ScriptedAI
|
||||
me->AddThreat(pTarget,1.0f);
|
||||
DoCast(pTarget, SPELL_CHARGE, true);
|
||||
}
|
||||
uiChargeTimer = 15*IN_MILISECONDS;
|
||||
uiChargeTimer = 15*IN_MILLISECONDS;
|
||||
} else uiChargeTimer -= diff;
|
||||
|
||||
if (uiBackstabTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_BACKSTAB);
|
||||
uiBackstabTimer = 12*IN_MILISECONDS;
|
||||
uiBackstabTimer = 12*IN_MILLISECONDS;
|
||||
} else uiBackstabTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -276,8 +276,8 @@ struct npc_anub_ar_shadowcasterAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiShadowBoltTimer = 6*IN_MILISECONDS;
|
||||
uiShadowNovaTimer = 15*IN_MILISECONDS;
|
||||
uiShadowBoltTimer = 6*IN_MILLISECONDS;
|
||||
uiShadowNovaTimer = 15*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -289,13 +289,13 @@ struct npc_anub_ar_shadowcasterAI : public ScriptedAI
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_SHADOW_BOLT, true);
|
||||
uiShadowBoltTimer = 15*IN_MILISECONDS;
|
||||
uiShadowBoltTimer = 15*IN_MILLISECONDS;
|
||||
} else uiShadowBoltTimer -= diff;
|
||||
|
||||
if (uiShadowNovaTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_SHADOW_NOVA, true);
|
||||
uiShadowNovaTimer = 17*IN_MILISECONDS;
|
||||
uiShadowNovaTimer = 17*IN_MILLISECONDS;
|
||||
} else uiShadowNovaTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -311,8 +311,8 @@ struct npc_anub_ar_warriorAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiCleaveTimer = 11*IN_MILISECONDS;
|
||||
uiStrikeTimer = 6*IN_MILISECONDS;
|
||||
uiCleaveTimer = 11*IN_MILLISECONDS;
|
||||
uiStrikeTimer = 6*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -323,13 +323,13 @@ struct npc_anub_ar_warriorAI : public ScriptedAI
|
||||
if (uiStrikeTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_STRIKE, true);
|
||||
uiStrikeTimer = 15*IN_MILISECONDS;
|
||||
uiStrikeTimer = 15*IN_MILLISECONDS;
|
||||
} else uiStrikeTimer -= diff;
|
||||
|
||||
if (uiCleaveTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_CLEAVE, true);
|
||||
uiCleaveTimer = 17*IN_MILISECONDS;
|
||||
uiCleaveTimer = 17*IN_MILLISECONDS;
|
||||
} else uiCleaveTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -347,8 +347,8 @@ struct npc_watcher_gashraAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiWebWrapTimer = 11*IN_MILISECONDS;
|
||||
uiInfectedBiteTimer = 4*IN_MILISECONDS;
|
||||
uiWebWrapTimer = 11*IN_MILLISECONDS;
|
||||
uiInfectedBiteTimer = 4*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* /*who*/)
|
||||
@@ -365,13 +365,13 @@ struct npc_watcher_gashraAI : public ScriptedAI
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_WEB_WRAP, true);
|
||||
uiWebWrapTimer = 17*IN_MILISECONDS;
|
||||
uiWebWrapTimer = 17*IN_MILLISECONDS;
|
||||
} else uiWebWrapTimer -= diff;
|
||||
|
||||
if (uiInfectedBiteTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_INFECTED_BITE, true);
|
||||
uiInfectedBiteTimer = 15*IN_MILISECONDS;
|
||||
uiInfectedBiteTimer = 15*IN_MILLISECONDS;
|
||||
} else uiInfectedBiteTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -388,9 +388,9 @@ struct npc_watcher_narjilAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiWebWrapTimer = 11*IN_MILISECONDS;
|
||||
uiInfectedBiteTimer = 4*IN_MILISECONDS;
|
||||
uiBindingWebsTimer = 17*IN_MILISECONDS;
|
||||
uiWebWrapTimer = 11*IN_MILLISECONDS;
|
||||
uiInfectedBiteTimer = 4*IN_MILLISECONDS;
|
||||
uiBindingWebsTimer = 17*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -402,19 +402,19 @@ struct npc_watcher_narjilAI : public ScriptedAI
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_WEB_WRAP, true);
|
||||
uiWebWrapTimer = 15*IN_MILISECONDS;
|
||||
uiWebWrapTimer = 15*IN_MILLISECONDS;
|
||||
} else uiWebWrapTimer -= diff;
|
||||
|
||||
if (uiInfectedBiteTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_INFECTED_BITE, true);
|
||||
uiInfectedBiteTimer = 11*IN_MILISECONDS;
|
||||
uiInfectedBiteTimer = 11*IN_MILLISECONDS;
|
||||
} else uiInfectedBiteTimer -= diff;
|
||||
|
||||
if (uiBindingWebsTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_BLINDING_WEBS, true);
|
||||
uiBindingWebsTimer = 17*IN_MILISECONDS;
|
||||
uiBindingWebsTimer = 17*IN_MILLISECONDS;
|
||||
} else uiBindingWebsTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -431,9 +431,9 @@ struct npc_watcher_silthikAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiWebWrapTimer = 11*IN_MILISECONDS;
|
||||
uiInfectedBiteTimer = 4*IN_MILISECONDS;
|
||||
uiPoisonSprayTimer = 15*IN_MILISECONDS;
|
||||
uiWebWrapTimer = 11*IN_MILLISECONDS;
|
||||
uiInfectedBiteTimer = 4*IN_MILLISECONDS;
|
||||
uiPoisonSprayTimer = 15*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -446,19 +446,19 @@ struct npc_watcher_silthikAI : public ScriptedAI
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_WEB_WRAP, true);
|
||||
|
||||
uiWebWrapTimer = 15*IN_MILISECONDS;
|
||||
uiWebWrapTimer = 15*IN_MILLISECONDS;
|
||||
} else uiWebWrapTimer -= diff;
|
||||
|
||||
if (uiInfectedBiteTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_INFECTED_BITE, true);
|
||||
uiInfectedBiteTimer = 15*IN_MILISECONDS;
|
||||
uiInfectedBiteTimer = 15*IN_MILLISECONDS;
|
||||
} else uiInfectedBiteTimer -= diff;
|
||||
|
||||
if (uiPoisonSprayTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_POSION_SPRAY, true);
|
||||
uiPoisonSprayTimer = 17*IN_MILISECONDS;
|
||||
uiPoisonSprayTimer = 17*IN_MILLISECONDS;
|
||||
} else uiPoisonSprayTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -60,9 +60,9 @@ struct boss_amanitarAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiRootTimer = urand(5*IN_MILISECONDS,9*IN_MILISECONDS);
|
||||
uiBashTimer = urand(10*IN_MILISECONDS,14*IN_MILISECONDS);
|
||||
uiBoltTimer = urand(15*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiRootTimer = urand(5*IN_MILLISECONDS,9*IN_MILLISECONDS);
|
||||
uiBashTimer = urand(10*IN_MILLISECONDS,14*IN_MILLISECONDS);
|
||||
uiBoltTimer = urand(15*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
uiSpawnTimer = 0;
|
||||
|
||||
me->SetMeleeDamageSchool(SPELL_SCHOOL_NATURE);
|
||||
@@ -106,9 +106,9 @@ struct boss_amanitarAI : public ScriptedAI
|
||||
Position pos;
|
||||
victim->GetPosition(&pos);
|
||||
me->GetRandomNearPosition(pos, float(urand(5,80)));
|
||||
me->SummonCreature(NPC_POISONOUS_MUSHROOM, pos, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30*IN_MILISECONDS);
|
||||
me->SummonCreature(NPC_POISONOUS_MUSHROOM, pos, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30*IN_MILLISECONDS);
|
||||
me->GetRandomNearPosition(pos, float(urand(5,80)));
|
||||
me->SummonCreature(NPC_HEALTHY_MUSHROOM, pos, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30*IN_MILISECONDS);
|
||||
me->SummonCreature(NPC_HEALTHY_MUSHROOM, pos, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30*IN_MILLISECONDS);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -122,27 +122,27 @@ struct boss_amanitarAI : public ScriptedAI
|
||||
if (uiSpawnTimer <= diff)
|
||||
{
|
||||
SpawnAdds();
|
||||
uiSpawnTimer = urand(35*IN_MILISECONDS,40*IN_MILISECONDS);
|
||||
uiSpawnTimer = urand(35*IN_MILLISECONDS,40*IN_MILLISECONDS);
|
||||
} else uiSpawnTimer -= diff;
|
||||
|
||||
if (uiRootTimer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_ENTANGLING_ROOTS);
|
||||
uiRootTimer = urand(15*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiRootTimer = urand(15*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiRootTimer -= diff;
|
||||
|
||||
if (uiBashTimer <= diff)
|
||||
{
|
||||
DoCastVictim(SPELL_BASH);
|
||||
uiBashTimer = urand(15*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiBashTimer = urand(15*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiBashTimer -= diff;
|
||||
|
||||
if (uiBoltTimer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_VENOM_BOLT_VOLLEY);
|
||||
uiBoltTimer = urand(15*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiBoltTimer = urand(15*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiBoltTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -164,7 +164,7 @@ struct mob_amanitar_mushroomsAI : public Scripted_NoMovementAI
|
||||
DoCast(me, SPELL_POISONOUS_MUSHROOM_VISUAL_AURA, true);
|
||||
|
||||
uiAuraTimer = 0;
|
||||
uiDeathTimer = 30*IN_MILISECONDS;
|
||||
uiDeathTimer = 30*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void JustDied(Unit *killer)
|
||||
@@ -190,7 +190,7 @@ struct mob_amanitar_mushroomsAI : public Scripted_NoMovementAI
|
||||
{
|
||||
DoCast(me, SPELL_POISONOUS_MUSHROOM_VISUAL_AREA, true);
|
||||
DoCast(me, SPELL_POISONOUS_MUSHROOM_POISON_CLOUD, false);
|
||||
uiAuraTimer = 7*IN_MILISECONDS;
|
||||
uiAuraTimer = 7*IN_MILLISECONDS;
|
||||
} else uiAuraTimer -= diff;
|
||||
}
|
||||
if (uiDeathTimer <= diff)
|
||||
|
||||
@@ -75,13 +75,13 @@ struct boss_elder_nadoxAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiPlagueTimer = 13*IN_MILISECONDS;
|
||||
uiRagueTimer = 20*IN_MILISECONDS;
|
||||
uiPlagueTimer = 13*IN_MILLISECONDS;
|
||||
uiRagueTimer = 20*IN_MILLISECONDS;
|
||||
|
||||
uiSwarmerSpawnTimer = 10*IN_MILISECONDS;
|
||||
uiGuardSpawnTimer = 25*IN_MILISECONDS;
|
||||
uiSwarmerSpawnTimer = 10*IN_MILLISECONDS;
|
||||
uiGuardSpawnTimer = 25*IN_MILLISECONDS;
|
||||
|
||||
uiEnragueTimer = 5*IN_MILISECONDS;
|
||||
uiEnragueTimer = 5*IN_MILLISECONDS;
|
||||
|
||||
DeadAhnkaharGuardian = false;
|
||||
bGuardSpawned = false;
|
||||
@@ -123,7 +123,7 @@ struct boss_elder_nadoxAI : public ScriptedAI
|
||||
if (uiPlagueTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_BROOD_PLAGUE);
|
||||
uiPlagueTimer = 15*IN_MILISECONDS;
|
||||
uiPlagueTimer = 15*IN_MILLISECONDS;
|
||||
} else uiPlagueTimer -= diff;
|
||||
|
||||
if (IsHeroic())
|
||||
@@ -132,7 +132,7 @@ struct boss_elder_nadoxAI : public ScriptedAI
|
||||
if (Creature *pSwarmer = me->FindNearestCreature(MOB_AHNKAHAR_SWARMER, 35))
|
||||
{
|
||||
DoCast(pSwarmer, H_SPELL_BROOD_RAGE, true);
|
||||
uiRagueTimer = 15*IN_MILISECONDS;
|
||||
uiRagueTimer = 15*IN_MILLISECONDS;
|
||||
}
|
||||
} else uiRagueTimer -= diff;
|
||||
|
||||
@@ -143,7 +143,7 @@ struct boss_elder_nadoxAI : public ScriptedAI
|
||||
if (urand(1,3) == 3) // 33% chance of dialog
|
||||
DoScriptText(RAND(SAY_EGG_SAC_1,SAY_EGG_SAC_2), me);
|
||||
|
||||
uiSwarmerSpawnTimer = 10*IN_MILISECONDS;
|
||||
uiSwarmerSpawnTimer = 10*IN_MILLISECONDS;
|
||||
} else uiSwarmerSpawnTimer -= diff;
|
||||
|
||||
if (!bGuardSpawned && uiGuardSpawnTimer <= diff)
|
||||
@@ -164,7 +164,7 @@ struct boss_elder_nadoxAI : public ScriptedAI
|
||||
if (!me->IsNonMeleeSpellCasted(false))
|
||||
DoCast(me, SPELL_ENRAGE, true);
|
||||
|
||||
uiEnragueTimer = 5*IN_MILISECONDS;
|
||||
uiEnragueTimer = 5*IN_MILLISECONDS;
|
||||
} else uiEnragueTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -196,7 +196,7 @@ struct mob_ahnkahar_nerubianAI : public ScriptedAI
|
||||
{
|
||||
if (me->GetEntry() == MOB_AHNKAHAR_GUARDIAN_ENTRY) //magic numbers are bad!
|
||||
DoCast(me, SPELL_GUARDIAN_AURA, true);
|
||||
uiSprintTimer = 10*IN_MILISECONDS;
|
||||
uiSprintTimer = 10*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void JustDied(Unit * /*killer*/)
|
||||
@@ -229,7 +229,7 @@ struct mob_ahnkahar_nerubianAI : public ScriptedAI
|
||||
if (uiSprintTimer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_SPRINT);
|
||||
uiSprintTimer = 25*IN_MILISECONDS;
|
||||
uiSprintTimer = 25*IN_MILLISECONDS;
|
||||
} else uiSprintTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -146,9 +146,9 @@ struct boss_volazjAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiMindFlayTimer = 8*IN_MILISECONDS;
|
||||
uiShadowBoltVolleyTimer = 5*IN_MILISECONDS;
|
||||
uiShiverTimer = 15*IN_MILISECONDS;
|
||||
uiMindFlayTimer = 8*IN_MILLISECONDS;
|
||||
uiShadowBoltVolleyTimer = 5*IN_MILLISECONDS;
|
||||
uiShiverTimer = 15*IN_MILLISECONDS;
|
||||
|
||||
if (pInstance)
|
||||
{
|
||||
@@ -272,20 +272,20 @@ struct boss_volazjAI : public ScriptedAI
|
||||
if (uiMindFlayTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_MIND_FLAY);
|
||||
uiMindFlayTimer = 20*IN_MILISECONDS;
|
||||
uiMindFlayTimer = 20*IN_MILLISECONDS;
|
||||
} else uiMindFlayTimer -= diff;
|
||||
|
||||
if (uiShadowBoltVolleyTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_SHADOW_BOLT_VOLLEY);
|
||||
uiShadowBoltVolleyTimer = 5*IN_MILISECONDS;
|
||||
uiShadowBoltVolleyTimer = 5*IN_MILLISECONDS;
|
||||
} else uiShadowBoltVolleyTimer -= diff;
|
||||
|
||||
if (uiShiverTimer <= diff)
|
||||
{
|
||||
if (Unit *pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_SHIVER);
|
||||
uiShiverTimer = 15*IN_MILISECONDS;
|
||||
uiShiverTimer = 15*IN_MILLISECONDS;
|
||||
} else uiShiverTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -89,11 +89,11 @@ struct boss_jedoga_shadowseekerAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiOpFerTimer = urand(15*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiOpFerTimer = urand(15*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
|
||||
uiCycloneTimer = 3*IN_MILISECONDS;
|
||||
uiBoltTimer = 7*IN_MILISECONDS;
|
||||
uiThunderTimer = 12*IN_MILISECONDS;
|
||||
uiCycloneTimer = 3*IN_MILLISECONDS;
|
||||
uiBoltTimer = 7*IN_MILLISECONDS;
|
||||
uiThunderTimer = 12*IN_MILLISECONDS;
|
||||
|
||||
bOpFerok = false;
|
||||
bOpFerokFail = false;
|
||||
@@ -247,7 +247,7 @@ struct boss_jedoga_shadowseekerAI : public ScriptedAI
|
||||
if (pInstance->GetData(DATA_JEDOGA_SHADOWSEEKER_EVENT) == IN_PROGRESS) OpferRufen();
|
||||
|
||||
bOnGround = false;
|
||||
uiOpFerTimer = urand(15*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiOpFerTimer = urand(15*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
}
|
||||
|
||||
void OpferRufen()
|
||||
@@ -303,7 +303,7 @@ struct boss_jedoga_shadowseekerAI : public ScriptedAI
|
||||
if (uiCycloneTimer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_CYCLONE_STRIKE, false);
|
||||
uiCycloneTimer = urand(15*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiCycloneTimer = urand(15*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiCycloneTimer -= diff;
|
||||
|
||||
if (uiBoltTimer <= diff)
|
||||
@@ -311,7 +311,7 @@ struct boss_jedoga_shadowseekerAI : public ScriptedAI
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
me->CastSpell(pTarget, DUNGEON_MODE(SPELL_LIGHTNING_BOLT, SPELL_LIGHTNING_BOLT_H), false);
|
||||
|
||||
uiBoltTimer = urand(15*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiBoltTimer = urand(15*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiBoltTimer -= diff;
|
||||
|
||||
if (uiThunderTimer <= diff)
|
||||
@@ -319,7 +319,7 @@ struct boss_jedoga_shadowseekerAI : public ScriptedAI
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
me->CastSpell(pTarget, DUNGEON_MODE(SPELL_THUNDERSHOCK, SPELL_THUNDERSHOCK_H), false);
|
||||
|
||||
uiThunderTimer = urand(15*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiThunderTimer = urand(15*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiThunderTimer -= diff;
|
||||
|
||||
if (uiOpFerTimer <= diff)
|
||||
@@ -351,7 +351,7 @@ struct mob_jedoga_initiandAI : public ScriptedAI
|
||||
return;
|
||||
|
||||
bWalking = false;
|
||||
bCheckTimer = 2*IN_MILISECONDS;
|
||||
bCheckTimer = 2*IN_MILLISECONDS;
|
||||
|
||||
if (pInstance->GetData(DATA_JEDOGA_SHADOWSEEKER_EVENT) != IN_PROGRESS)
|
||||
{
|
||||
@@ -466,7 +466,7 @@ struct mob_jedoga_initiandAI : public ScriptedAI
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE + UNIT_FLAG_NON_ATTACKABLE);
|
||||
}
|
||||
}
|
||||
bCheckTimer = 2*IN_MILISECONDS;
|
||||
bCheckTimer = 2*IN_MILLISECONDS;
|
||||
} else bCheckTimer -= diff;
|
||||
|
||||
//Return since we have no target
|
||||
|
||||
@@ -97,10 +97,10 @@ struct boss_taldaramAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiBloodthirstTimer = 10*IN_MILISECONDS;
|
||||
uiVanishTimer = urand(25*IN_MILISECONDS,35*IN_MILISECONDS);
|
||||
uiEmbraceTimer = 20*IN_MILISECONDS;
|
||||
uiFlamesphereTimer = 5*IN_MILISECONDS;
|
||||
uiBloodthirstTimer = 10*IN_MILLISECONDS;
|
||||
uiVanishTimer = urand(25*IN_MILLISECONDS,35*IN_MILLISECONDS);
|
||||
uiEmbraceTimer = 20*IN_MILLISECONDS;
|
||||
uiFlamesphereTimer = 5*IN_MILLISECONDS;
|
||||
uiEmbraceTakenDamage = 0;
|
||||
Phase = NORMAL;
|
||||
uiPhaseTimer = 0;
|
||||
@@ -129,7 +129,7 @@ struct boss_taldaramAI : public ScriptedAI
|
||||
Creature* pSpheres[3];
|
||||
|
||||
//DoCast(me, SPELL_FLAME_SPHERE_SUMMON_1);
|
||||
pSpheres[0] = DoSpawnCreature(CREATURE_FLAME_SPHERE, 0, 0, 5, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10*IN_MILISECONDS);
|
||||
pSpheres[0] = DoSpawnCreature(CREATURE_FLAME_SPHERE, 0, 0, 5, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10*IN_MILLISECONDS);
|
||||
Unit *pSphereTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true);
|
||||
if (pSphereTarget && pSpheres[0])
|
||||
{
|
||||
@@ -142,9 +142,9 @@ struct boss_taldaramAI : public ScriptedAI
|
||||
if (IsHeroic())
|
||||
{
|
||||
//DoCast(me, H_SPELL_FLAME_SPHERE_SUMMON_1);
|
||||
pSpheres[1] = DoSpawnCreature(H_CREATURE_FLAME_SPHERE_1, 0, 0, 5, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10*IN_MILISECONDS);
|
||||
pSpheres[1] = DoSpawnCreature(H_CREATURE_FLAME_SPHERE_1, 0, 0, 5, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10*IN_MILLISECONDS);
|
||||
//DoCast(me, H_SPELL_FLAME_SPHERE_SUMMON_2);
|
||||
pSpheres[2] = DoSpawnCreature(H_CREATURE_FLAME_SPHERE_2, 0, 0, 5, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10*IN_MILISECONDS);
|
||||
pSpheres[2] = DoSpawnCreature(H_CREATURE_FLAME_SPHERE_2, 0, 0, 5, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 10*IN_MILLISECONDS);
|
||||
if (pSphereTarget && pSpheres[1] && pSpheres[2])
|
||||
{
|
||||
float angle,x,y;
|
||||
@@ -180,7 +180,7 @@ struct boss_taldaramAI : public ScriptedAI
|
||||
me->SetSpeed(MOVE_WALK, 1.0f, true);
|
||||
me->GetMotionMaster()->MoveChase(me->getVictim());
|
||||
Phase = FEEDING;
|
||||
uiPhaseTimer = 20*IN_MILISECONDS;
|
||||
uiPhaseTimer = 20*IN_MILLISECONDS;
|
||||
break;
|
||||
case FEEDING:
|
||||
Phase = NORMAL;
|
||||
@@ -191,15 +191,15 @@ struct boss_taldaramAI : public ScriptedAI
|
||||
if (uiBloodthirstTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_BLOODTHIRST);
|
||||
uiBloodthirstTimer = 10*IN_MILISECONDS;
|
||||
uiBloodthirstTimer = 10*IN_MILLISECONDS;
|
||||
} else uiBloodthirstTimer -= diff;
|
||||
|
||||
if (uiFlamesphereTimer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_CONJURE_FLAME_SPHERE);
|
||||
Phase = CASTING_FLAME_SPHERES;
|
||||
uiPhaseTimer = 3*IN_MILISECONDS + diff;
|
||||
uiFlamesphereTimer = 15*IN_MILISECONDS;
|
||||
uiPhaseTimer = 3*IN_MILLISECONDS + diff;
|
||||
uiFlamesphereTimer = 15*IN_MILLISECONDS;
|
||||
} else uiFlamesphereTimer -= diff;
|
||||
|
||||
if (uiVanishTimer <= diff)
|
||||
@@ -227,7 +227,7 @@ struct boss_taldaramAI : public ScriptedAI
|
||||
uiEmbraceTarget = pEmbraceTarget->GetGUID();
|
||||
|
||||
}
|
||||
uiVanishTimer = urand(25*IN_MILISECONDS,35*IN_MILISECONDS);
|
||||
uiVanishTimer = urand(25*IN_MILLISECONDS,35*IN_MILLISECONDS);
|
||||
} else uiVanishTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -338,7 +338,7 @@ struct mob_taldaram_flamesphereAI : public ScriptedAI
|
||||
DoCast(me, SPELL_FLAME_SPHERE_VISUAL);
|
||||
DoCast(me, SPELL_FLAME_SPHERE_SPAWN_EFFECT);
|
||||
DoCast(me, SPELL_FLAME_SPHERE_PERIODIC);
|
||||
uiDespawnTimer = 10*IN_MILISECONDS;
|
||||
uiDespawnTimer = 10*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void EnterCombat(Unit * /*who*/) {}
|
||||
|
||||
@@ -70,12 +70,12 @@ struct boss_dredAI : public ScriptedAI
|
||||
pInstance->SetData(DATA_KING_DRED_ACHIEV, 0);
|
||||
}
|
||||
|
||||
uiBellowingRoarTimer = 33*IN_MILISECONDS;
|
||||
uiGrievousBiteTimer = 20*IN_MILISECONDS;
|
||||
uiManglingSlashTimer = 18.5*IN_MILISECONDS;
|
||||
uiFearsomeRoarTimer = urand(10*IN_MILISECONDS,20*IN_MILISECONDS);
|
||||
uiPiercingSlashTimer = 17*IN_MILISECONDS;
|
||||
uiRaptorCallTimer = urand(20*IN_MILISECONDS,25*IN_MILISECONDS);
|
||||
uiBellowingRoarTimer = 33*IN_MILLISECONDS;
|
||||
uiGrievousBiteTimer = 20*IN_MILLISECONDS;
|
||||
uiManglingSlashTimer = 18.5*IN_MILLISECONDS;
|
||||
uiFearsomeRoarTimer = urand(10*IN_MILLISECONDS,20*IN_MILLISECONDS);
|
||||
uiPiercingSlashTimer = 17*IN_MILLISECONDS;
|
||||
uiRaptorCallTimer = urand(20*IN_MILLISECONDS,25*IN_MILLISECONDS);
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* /*who*/)
|
||||
@@ -93,31 +93,31 @@ struct boss_dredAI : public ScriptedAI
|
||||
if (uiBellowingRoarTimer < diff)
|
||||
{
|
||||
DoCastAOE(SPELL_BELLOWING_ROAR, false);
|
||||
uiBellowingRoarTimer = 40*IN_MILISECONDS;
|
||||
uiBellowingRoarTimer = 40*IN_MILLISECONDS;
|
||||
} else uiBellowingRoarTimer -=diff;
|
||||
|
||||
if (uiGrievousBiteTimer < diff)
|
||||
{
|
||||
DoCastVictim(SPELL_GRIEVOUS_BITE ,false);
|
||||
uiGrievousBiteTimer = 20*IN_MILISECONDS;
|
||||
uiGrievousBiteTimer = 20*IN_MILLISECONDS;
|
||||
} else uiGrievousBiteTimer -=diff;
|
||||
|
||||
if (uiManglingSlashTimer < diff)
|
||||
{
|
||||
DoCastVictim(SPELL_MANGLING_SLASH,false);
|
||||
uiManglingSlashTimer = 20*IN_MILISECONDS;
|
||||
uiManglingSlashTimer = 20*IN_MILLISECONDS;
|
||||
} else uiManglingSlashTimer -=diff;
|
||||
|
||||
if (uiFearsomeRoarTimer < diff)
|
||||
{
|
||||
DoCastAOE(SPELL_FEARSOME_ROAR,false);
|
||||
uiFearsomeRoarTimer = urand(16*IN_MILISECONDS,18*IN_MILISECONDS);
|
||||
uiFearsomeRoarTimer = urand(16*IN_MILLISECONDS,18*IN_MILLISECONDS);
|
||||
} else uiFearsomeRoarTimer -=diff;
|
||||
|
||||
if (uiPiercingSlashTimer < diff)
|
||||
{
|
||||
DoCastVictim(SPELL_PIERCING_SLASH,false);
|
||||
uiPiercingSlashTimer = 20*IN_MILISECONDS;
|
||||
uiPiercingSlashTimer = 20*IN_MILLISECONDS;
|
||||
} else uiPiercingSlashTimer -=diff;
|
||||
|
||||
if (uiRaptorCallTimer < diff)
|
||||
@@ -127,9 +127,9 @@ struct boss_dredAI : public ScriptedAI
|
||||
float x,y,z;
|
||||
|
||||
me->GetClosePoint(x,y,z,me->GetObjectSize()/3,10.0f);
|
||||
me->SummonCreature(RAND(NPC_RAPTOR_1,NPC_RAPTOR_2),x,y,z,0,TEMPSUMMON_DEAD_DESPAWN,1*IN_MILISECONDS);
|
||||
me->SummonCreature(RAND(NPC_RAPTOR_1,NPC_RAPTOR_2),x,y,z,0,TEMPSUMMON_DEAD_DESPAWN,1*IN_MILLISECONDS);
|
||||
|
||||
uiRaptorCallTimer = urand(20*IN_MILISECONDS,25*IN_MILISECONDS);
|
||||
uiRaptorCallTimer = urand(20*IN_MILLISECONDS,25*IN_MILLISECONDS);
|
||||
} else uiRaptorCallTimer -=diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -213,7 +213,7 @@ struct npc_drakkari_scytheclawAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiRendTimer = urand(10*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiRendTimer = urand(10*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -225,7 +225,7 @@ struct npc_drakkari_scytheclawAI : public ScriptedAI
|
||||
if (uiRendTimer < diff)
|
||||
{
|
||||
DoCastVictim(SPELL_REND,false);
|
||||
uiRendTimer = urand(10*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiRendTimer = urand(10*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
}else uiRendTimer -=diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -117,8 +117,8 @@ struct boss_novosAI : public Scripted_NoMovementAI
|
||||
{
|
||||
DoScriptText(SAY_AGGRO, me);
|
||||
Phase = PHASE_1;
|
||||
uiCrystalHandlerTimer = 30*IN_MILISECONDS;
|
||||
uiTimer = 1*IN_MILISECONDS;
|
||||
uiCrystalHandlerTimer = 30*IN_MILLISECONDS;
|
||||
uiTimer = 1*IN_MILLISECONDS;
|
||||
DoCast(SPELL_ARCANE_FIELD);
|
||||
if (pInstance)
|
||||
{
|
||||
@@ -141,18 +141,18 @@ struct boss_novosAI : public Scripted_NoMovementAI
|
||||
case PHASE_1:
|
||||
if (uiTimer <= diff)
|
||||
{
|
||||
Creature *pSummon = me->SummonCreature(RAND(CREATURE_FETID_TROLL_CORPSE,CREATURE_HULKING_CORPSE,CREATURE_RISEN_SHADOWCASTER), AddSpawnPoint, TEMPSUMMON_CORPSE_TIMED_DESPAWN,20*IN_MILISECONDS);
|
||||
Creature *pSummon = me->SummonCreature(RAND(CREATURE_FETID_TROLL_CORPSE,CREATURE_HULKING_CORPSE,CREATURE_RISEN_SHADOWCASTER), AddSpawnPoint, TEMPSUMMON_CORPSE_TIMED_DESPAWN,20*IN_MILLISECONDS);
|
||||
pSummon->GetMotionMaster()->MovePoint(0, AddDestinyPoint);
|
||||
//If spell is casted stops casting arcane field so no spell casting
|
||||
//DoCast(me, SPELL_SUMMON_MINIONS);
|
||||
uiTimer = 3*IN_MILISECONDS;
|
||||
uiTimer = 3*IN_MILLISECONDS;
|
||||
} else uiTimer -= diff;
|
||||
if (uiCrystalHandlerTimer <= diff)
|
||||
{
|
||||
DoScriptText(SAY_NECRO_ADD, me);
|
||||
Creature *pCrystalHandler = me->SummonCreature(CREATURE_CRYSTAL_HANDLER, CrystalHandlerSpawnPoint, TEMPSUMMON_CORPSE_TIMED_DESPAWN,20*IN_MILISECONDS);
|
||||
Creature *pCrystalHandler = me->SummonCreature(CREATURE_CRYSTAL_HANDLER, CrystalHandlerSpawnPoint, TEMPSUMMON_CORPSE_TIMED_DESPAWN,20*IN_MILLISECONDS);
|
||||
pCrystalHandler->GetMotionMaster()->MovePoint(0, AddDestinyPoint);
|
||||
uiCrystalHandlerTimer = urand(20*IN_MILISECONDS,30*IN_MILISECONDS);
|
||||
uiCrystalHandlerTimer = urand(20*IN_MILLISECONDS,30*IN_MILLISECONDS);
|
||||
} else uiCrystalHandlerTimer -= diff;
|
||||
break;
|
||||
case PHASE_2:
|
||||
@@ -161,7 +161,7 @@ struct boss_novosAI : public Scripted_NoMovementAI
|
||||
if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, DUNGEON_MODE(RAND(SPELL_ARCANE_BLAST,SPELL_BLIZZARD,SPELL_FROSTBOLT,SPELL_WRATH_OF_MISERY),
|
||||
RAND(H_SPELL_ARCANE_BLAST,H_SPELL_BLIZZARD,H_SPELL_FROSTBOLT,H_SPELL_WRATH_OF_MISERY)));
|
||||
uiTimer = urand(1*IN_MILISECONDS,3*IN_MILISECONDS);
|
||||
uiTimer = urand(1*IN_MILLISECONDS,3*IN_MILLISECONDS);
|
||||
} else uiTimer -= diff;
|
||||
break;
|
||||
}
|
||||
@@ -207,7 +207,7 @@ struct boss_novosAI : public Scripted_NoMovementAI
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
|
||||
Phase = PHASE_2;
|
||||
uiTimer = 1*IN_MILISECONDS;
|
||||
uiTimer = 1*IN_MILLISECONDS;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -236,7 +236,7 @@ struct mob_crystal_handlerAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiFlashOfDarknessTimer = 5*IN_MILISECONDS;
|
||||
uiFlashOfDarknessTimer = 5*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void JustDied(Unit* /*killer*/)
|
||||
@@ -253,7 +253,7 @@ struct mob_crystal_handlerAI : public ScriptedAI
|
||||
if (uiFlashOfDarknessTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), DUNGEON_MODE(SPELL_FLASH_OF_DARKNESS,H_SPELL_FLASH_OF_DARKNESS));
|
||||
uiFlashOfDarknessTimer = 5*IN_MILISECONDS;
|
||||
uiFlashOfDarknessTimer = 5*IN_MILLISECONDS;
|
||||
} else uiFlashOfDarknessTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -85,10 +85,10 @@ struct boss_tharon_jaAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiPhaseTimer = 20*IN_MILISECONDS;
|
||||
uiCurseOfLifeTimer = 1*IN_MILISECONDS;
|
||||
uiRainOfFireTimer = urand(14*IN_MILISECONDS,18*IN_MILISECONDS);
|
||||
uiShadowVolleyTimer = urand(8*IN_MILISECONDS,10*IN_MILISECONDS);
|
||||
uiPhaseTimer = 20*IN_MILLISECONDS;
|
||||
uiCurseOfLifeTimer = 1*IN_MILLISECONDS;
|
||||
uiRainOfFireTimer = urand(14*IN_MILLISECONDS,18*IN_MILLISECONDS);
|
||||
uiShadowVolleyTimer = urand(8*IN_MILLISECONDS,10*IN_MILLISECONDS);
|
||||
Phase = SKELETAL;
|
||||
me->SetDisplayId(me->GetNativeDisplayId());
|
||||
if (pInstance)
|
||||
@@ -116,26 +116,26 @@ struct boss_tharon_jaAI : public ScriptedAI
|
||||
{
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_CURSE_OF_LIFE);
|
||||
uiCurseOfLifeTimer = urand(10*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiCurseOfLifeTimer = urand(10*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
} else uiCurseOfLifeTimer -= diff;
|
||||
|
||||
if (uiShadowVolleyTimer < diff)
|
||||
{
|
||||
DoCastVictim(SPELL_SHADOW_VOLLEY);
|
||||
uiShadowVolleyTimer = urand(8*IN_MILISECONDS,10*IN_MILISECONDS);
|
||||
uiShadowVolleyTimer = urand(8*IN_MILLISECONDS,10*IN_MILLISECONDS);
|
||||
} else uiShadowVolleyTimer -= diff;
|
||||
|
||||
if (uiRainOfFireTimer < diff)
|
||||
{
|
||||
DoCastAOE(SPELL_RAIN_OF_FIRE);
|
||||
uiRainOfFireTimer = urand(14*IN_MILISECONDS,18*IN_MILISECONDS);
|
||||
uiRainOfFireTimer = urand(14*IN_MILLISECONDS,18*IN_MILLISECONDS);
|
||||
} else uiRainOfFireTimer -= diff;
|
||||
|
||||
if (uiPhaseTimer < diff)
|
||||
{
|
||||
DoCast(SPELL_DECAY_FLESH);
|
||||
Phase = GOING_FLESH;
|
||||
uiPhaseTimer = 6*IN_MILISECONDS;
|
||||
uiPhaseTimer = 6*IN_MILLISECONDS;
|
||||
} else uiPhaseTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -155,10 +155,10 @@ struct boss_tharon_jaAI : public ScriptedAI
|
||||
pTemp->SetDisplayId(MODEL_SKELETON);
|
||||
}
|
||||
}
|
||||
uiPhaseTimer = 20*IN_MILISECONDS;
|
||||
uiLightningBreathTimer = urand(3*IN_MILISECONDS,4*IN_MILISECONDS);
|
||||
uiEyeBeamTimer = urand(4*IN_MILISECONDS,8*IN_MILISECONDS);
|
||||
uiPoisonCloudTimer = urand(6*IN_MILISECONDS,7*IN_MILISECONDS);
|
||||
uiPhaseTimer = 20*IN_MILLISECONDS;
|
||||
uiLightningBreathTimer = urand(3*IN_MILLISECONDS,4*IN_MILLISECONDS);
|
||||
uiEyeBeamTimer = urand(4*IN_MILLISECONDS,8*IN_MILLISECONDS);
|
||||
uiPoisonCloudTimer = urand(6*IN_MILLISECONDS,7*IN_MILLISECONDS);
|
||||
Phase = FLESH;
|
||||
} else uiPhaseTimer -= diff;
|
||||
break;
|
||||
@@ -167,27 +167,27 @@ struct boss_tharon_jaAI : public ScriptedAI
|
||||
{
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_LIGHTNING_BREATH);
|
||||
uiLightningBreathTimer = urand(6*IN_MILISECONDS,7*IN_MILISECONDS);
|
||||
uiLightningBreathTimer = urand(6*IN_MILLISECONDS,7*IN_MILLISECONDS);
|
||||
} else uiLightningBreathTimer -= diff;
|
||||
|
||||
if (uiEyeBeamTimer < diff)
|
||||
{
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_EYE_BEAM);
|
||||
uiEyeBeamTimer = urand(4*IN_MILISECONDS,6*IN_MILISECONDS);
|
||||
uiEyeBeamTimer = urand(4*IN_MILLISECONDS,6*IN_MILLISECONDS);
|
||||
} else uiEyeBeamTimer -= diff;
|
||||
|
||||
if (uiPoisonCloudTimer < diff)
|
||||
{
|
||||
DoCastAOE(SPELL_POISON_CLOUD);
|
||||
uiPoisonCloudTimer = urand(10*IN_MILISECONDS,12*IN_MILISECONDS);
|
||||
uiPoisonCloudTimer = urand(10*IN_MILLISECONDS,12*IN_MILLISECONDS);
|
||||
} else uiPoisonCloudTimer -= diff;
|
||||
|
||||
if (uiPhaseTimer < diff)
|
||||
{
|
||||
DoCast(SPELL_RETURN_FLESH);
|
||||
Phase = GOING_SKELETAL;
|
||||
uiPhaseTimer = 6*IN_MILISECONDS;
|
||||
uiPhaseTimer = 6*IN_MILLISECONDS;
|
||||
} else uiPhaseTimer -= diff;
|
||||
DoMeleeAttackIfReady();
|
||||
break;
|
||||
@@ -197,10 +197,10 @@ struct boss_tharon_jaAI : public ScriptedAI
|
||||
DoScriptText(RAND(SAY_SKELETON_1,SAY_SKELETON_2), me);
|
||||
me->DeMorph();
|
||||
Phase = SKELETAL;
|
||||
uiPhaseTimer = 20*IN_MILISECONDS;
|
||||
uiCurseOfLifeTimer = 1*IN_MILISECONDS;
|
||||
uiRainOfFireTimer = urand(14*IN_MILISECONDS,18*IN_MILISECONDS);
|
||||
uiShadowVolleyTimer = urand(8*IN_MILISECONDS,10*IN_MILISECONDS);
|
||||
uiPhaseTimer = 20*IN_MILLISECONDS;
|
||||
uiCurseOfLifeTimer = 1*IN_MILLISECONDS;
|
||||
uiRainOfFireTimer = urand(14*IN_MILLISECONDS,18*IN_MILLISECONDS);
|
||||
uiShadowVolleyTimer = urand(8*IN_MILLISECONDS,10*IN_MILLISECONDS);
|
||||
std::list<HostileReference*>& threatlist = me->getThreatManager().getThreatList();
|
||||
for (std::list<HostileReference*>::const_iterator itr = threatlist.begin(); itr != threatlist.end(); ++itr)
|
||||
{
|
||||
|
||||
@@ -76,12 +76,12 @@ struct boss_trollgoreAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiConsumeTimer = 15*IN_MILISECONDS;
|
||||
uiAuraCountTimer = 15.5*IN_MILISECONDS;
|
||||
uiCrushTimer = urand(1*IN_MILISECONDS,5*IN_MILISECONDS);
|
||||
uiInfectedWoundTimer = urand(60*IN_MILISECONDS,10*IN_MILISECONDS);
|
||||
uiExplodeCorpseTimer = 3*IN_MILISECONDS;
|
||||
uiSpawnTimer = urand(30*IN_MILISECONDS,40*IN_MILISECONDS);
|
||||
uiConsumeTimer = 15*IN_MILLISECONDS;
|
||||
uiAuraCountTimer = 15.5*IN_MILLISECONDS;
|
||||
uiCrushTimer = urand(1*IN_MILLISECONDS,5*IN_MILLISECONDS);
|
||||
uiInfectedWoundTimer = urand(60*IN_MILLISECONDS,10*IN_MILLISECONDS);
|
||||
uiExplodeCorpseTimer = 3*IN_MILLISECONDS;
|
||||
uiSpawnTimer = urand(30*IN_MILLISECONDS,40*IN_MILLISECONDS);
|
||||
|
||||
bAchiev = IsHeroic();
|
||||
|
||||
@@ -112,14 +112,14 @@ struct boss_trollgoreAI : public ScriptedAI
|
||||
uint32 spawnNumber = urand(2,DUNGEON_MODE(3,5));
|
||||
for (uint8 i = 0; i < spawnNumber; ++i)
|
||||
DoSummon(RAND(NPC_DRAKKARI_INVADER_1,NPC_DRAKKARI_INVADER_2), AddSpawnPoint, 0, TEMPSUMMON_DEAD_DESPAWN);
|
||||
uiSpawnTimer = urand(30*IN_MILISECONDS,40*IN_MILISECONDS);
|
||||
uiSpawnTimer = urand(30*IN_MILLISECONDS,40*IN_MILLISECONDS);
|
||||
} else uiSpawnTimer -= diff;
|
||||
|
||||
if (uiConsumeTimer <= diff)
|
||||
{
|
||||
DoScriptText(SAY_CONSUME, me);
|
||||
DoCast(SPELL_CONSUME);
|
||||
uiConsumeTimer = 15*IN_MILISECONDS;
|
||||
uiConsumeTimer = 15*IN_MILLISECONDS;
|
||||
} else uiConsumeTimer -= diff;
|
||||
|
||||
if (bAchiev)
|
||||
@@ -132,20 +132,20 @@ struct boss_trollgoreAI : public ScriptedAI
|
||||
if (uiCrushTimer <= diff)
|
||||
{
|
||||
DoCastVictim(SPELL_CRUSH);
|
||||
uiCrushTimer = urand(10*IN_MILISECONDS,15*IN_MILISECONDS);
|
||||
uiCrushTimer = urand(10*IN_MILLISECONDS,15*IN_MILLISECONDS);
|
||||
} else uiCrushTimer -= diff;
|
||||
|
||||
if (uiInfectedWoundTimer <= diff)
|
||||
{
|
||||
DoCastVictim(SPELL_INFECTED_WOUND);
|
||||
uiInfectedWoundTimer = urand(25*IN_MILISECONDS,35*IN_MILISECONDS);
|
||||
uiInfectedWoundTimer = urand(25*IN_MILLISECONDS,35*IN_MILLISECONDS);
|
||||
} else uiInfectedWoundTimer -= diff;
|
||||
|
||||
if (uiExplodeCorpseTimer <= diff)
|
||||
{
|
||||
DoCast(SPELL_CORPSE_EXPLODE);
|
||||
DoScriptText(SAY_EXPLODE, me);
|
||||
uiExplodeCorpseTimer = urand(15*IN_MILISECONDS,19*IN_MILISECONDS);
|
||||
uiExplodeCorpseTimer = urand(15*IN_MILLISECONDS,19*IN_MILLISECONDS);
|
||||
} else uiExplodeCorpseTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -58,7 +58,7 @@ struct boss_drakkari_colossusAI : public ScriptedAI
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
|
||||
me->clearUnitState(UNIT_STAT_STUNNED | UNIT_STAT_ROOT);
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
MightyBlowTimer = 10*IN_MILISECONDS;
|
||||
MightyBlowTimer = 10*IN_MILLISECONDS;
|
||||
bHealth = false;
|
||||
bHealth1 = false;
|
||||
}
|
||||
@@ -114,7 +114,7 @@ struct boss_drakkari_colossusAI : public ScriptedAI
|
||||
if (MightyBlowTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_MIGHTY_BLOW, true);
|
||||
MightyBlowTimer = 10*IN_MILISECONDS;
|
||||
MightyBlowTimer = 10*IN_MILLISECONDS;
|
||||
} else MightyBlowTimer -= diff;
|
||||
|
||||
if (!me->hasUnitState(UNIT_STAT_STUNNED))
|
||||
@@ -152,7 +152,7 @@ struct boss_drakkari_elementalAI : public ScriptedAI
|
||||
{
|
||||
if (Creature *pColossus = Unit::GetCreature(*me, pInstance ? pInstance->GetData64(DATA_DRAKKARI_COLOSSUS) : 0))
|
||||
CAST_AI(boss_drakkari_colossusAI, pColossus->AI())->CreatureState(me, true);
|
||||
uiSurgeTimer = 7*IN_MILISECONDS;
|
||||
uiSurgeTimer = 7*IN_MILLISECONDS;
|
||||
bGoToColossus = false;
|
||||
}
|
||||
|
||||
@@ -195,7 +195,7 @@ struct boss_drakkari_elementalAI : public ScriptedAI
|
||||
if (uiSurgeTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_SURGE);
|
||||
uiSurgeTimer = 7*IN_MILISECONDS;
|
||||
uiSurgeTimer = 7*IN_MILLISECONDS;
|
||||
} else uiSurgeTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -222,8 +222,8 @@ struct npc_living_mojoAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiMojoWaveTimer = 2*IN_MILISECONDS;
|
||||
uiMojoPuddleTimer = 7*IN_MILISECONDS;
|
||||
uiMojoWaveTimer = 2*IN_MILLISECONDS;
|
||||
uiMojoPuddleTimer = 7*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void EnterCombat(Unit* /*who*/)
|
||||
@@ -267,13 +267,13 @@ struct npc_living_mojoAI : public ScriptedAI
|
||||
if (uiMojoWaveTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_MOJO_WAVE);
|
||||
uiMojoWaveTimer = 15*IN_MILISECONDS;
|
||||
uiMojoWaveTimer = 15*IN_MILLISECONDS;
|
||||
} else uiMojoWaveTimer -= diff;
|
||||
|
||||
if (uiMojoPuddleTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_MOJO_PUDDLE);
|
||||
uiMojoPuddleTimer = 18*IN_MILISECONDS;
|
||||
uiMojoPuddleTimer = 18*IN_MILLISECONDS;
|
||||
} else uiMojoPuddleTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -47,10 +47,10 @@ struct boss_eckAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiBerserkTimer = urand(60*IN_MILISECONDS,90*IN_MILISECONDS); //60-90 secs according to wowwiki
|
||||
uiBiteTimer = 5*IN_MILISECONDS;
|
||||
uiSpitTimer = 10*IN_MILISECONDS;
|
||||
uiSpringTimer = 8*IN_MILISECONDS;
|
||||
uiBerserkTimer = urand(60*IN_MILLISECONDS,90*IN_MILLISECONDS); //60-90 secs according to wowwiki
|
||||
uiBiteTimer = 5*IN_MILLISECONDS;
|
||||
uiSpitTimer = 10*IN_MILLISECONDS;
|
||||
uiSpringTimer = 8*IN_MILLISECONDS;
|
||||
|
||||
bBerserk = false;
|
||||
|
||||
@@ -73,13 +73,13 @@ struct boss_eckAI : public ScriptedAI
|
||||
if (uiBiteTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_ECK_BITE);
|
||||
uiBiteTimer = urand(8*IN_MILISECONDS,12*IN_MILISECONDS);
|
||||
uiBiteTimer = urand(8*IN_MILLISECONDS,12*IN_MILLISECONDS);
|
||||
} else uiBiteTimer -= diff;
|
||||
|
||||
if (uiSpitTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_ECK_SPIT);
|
||||
uiSpitTimer = urand(6*IN_MILISECONDS,14*IN_MILISECONDS);
|
||||
uiSpitTimer = urand(6*IN_MILLISECONDS,14*IN_MILLISECONDS);
|
||||
} else uiSpitTimer -= diff;
|
||||
|
||||
if (uiSpringTimer <= diff)
|
||||
@@ -88,7 +88,7 @@ struct boss_eckAI : public ScriptedAI
|
||||
if (pTarget && pTarget->GetTypeId() == TYPEID_PLAYER)
|
||||
{
|
||||
DoCast(pTarget, RAND(SPELL_ECK_SPRING_1, SPELL_ECK_SPRING_2));
|
||||
uiSpringTimer = urand(5*IN_MILISECONDS,10*IN_MILISECONDS);
|
||||
uiSpringTimer = urand(5*IN_MILLISECONDS,10*IN_MILLISECONDS);
|
||||
}
|
||||
} else uiSpringTimer -= diff;
|
||||
|
||||
@@ -141,7 +141,7 @@ struct npc_ruins_dwellerAI : public ScriptedAI
|
||||
{
|
||||
pInstance->SetData64(DATA_RUIN_DWELLER_DIED,me->GetGUID());
|
||||
if (pInstance->GetData(DATA_ALIVE_RUIN_DWELLERS) == 0)
|
||||
me->SummonCreature(CREATURE_ECK, EckSpawnPoint, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 300*IN_MILISECONDS);
|
||||
me->SummonCreature(CREATURE_ECK, EckSpawnPoint, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 300*IN_MILLISECONDS);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@@ -94,13 +94,13 @@ struct boss_gal_darahAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiStampedeTimer = 10*IN_MILISECONDS;
|
||||
uiWhirlingSlashTimer = 21*IN_MILISECONDS;
|
||||
uiPunctureTimer = 10*IN_MILISECONDS;
|
||||
uiEnrageTimer = 15*IN_MILISECONDS;
|
||||
uiImpalingChargeTimer = 21*IN_MILISECONDS;
|
||||
uiStompTimer = 25*IN_MILISECONDS;
|
||||
uiTransformationTimer = 9*IN_MILISECONDS;
|
||||
uiStampedeTimer = 10*IN_MILLISECONDS;
|
||||
uiWhirlingSlashTimer = 21*IN_MILLISECONDS;
|
||||
uiPunctureTimer = 10*IN_MILLISECONDS;
|
||||
uiEnrageTimer = 15*IN_MILLISECONDS;
|
||||
uiImpalingChargeTimer = 21*IN_MILLISECONDS;
|
||||
uiStompTimer = 25*IN_MILLISECONDS;
|
||||
uiTransformationTimer = 9*IN_MILLISECONDS;
|
||||
uiPhaseCounter = 0;
|
||||
|
||||
lImpaledPlayers.clear();
|
||||
@@ -140,7 +140,7 @@ struct boss_gal_darahAI : public ScriptedAI
|
||||
Phase = RHINO;
|
||||
uiPhaseCounter = 0;
|
||||
DoScriptText(SAY_TRANSFORM_1, me);
|
||||
uiTransformationTimer = 5*IN_MILISECONDS;
|
||||
uiTransformationTimer = 5*IN_MILLISECONDS;
|
||||
bStartOfTransformation = true;
|
||||
me->clearUnitState(UNIT_STAT_STUNNED|UNIT_STAT_ROOT);
|
||||
me->SetReactState(REACT_AGGRESSIVE);
|
||||
@@ -163,13 +163,13 @@ struct boss_gal_darahAI : public ScriptedAI
|
||||
{
|
||||
DoCast(me, SPELL_STAMPEDE);
|
||||
DoScriptText(RAND(SAY_SUMMON_RHINO_1,SAY_SUMMON_RHINO_2,SAY_SUMMON_RHINO_3),me);
|
||||
uiStampedeTimer = 15*IN_MILISECONDS;
|
||||
uiStampedeTimer = 15*IN_MILLISECONDS;
|
||||
} else uiStampedeTimer -= diff;
|
||||
|
||||
if (uiWhirlingSlashTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_WHIRLING_SLASH);
|
||||
uiWhirlingSlashTimer = 21*IN_MILISECONDS;
|
||||
uiWhirlingSlashTimer = 21*IN_MILLISECONDS;
|
||||
++uiPhaseCounter;
|
||||
} else uiWhirlingSlashTimer -= diff;
|
||||
}
|
||||
@@ -183,7 +183,7 @@ struct boss_gal_darahAI : public ScriptedAI
|
||||
Phase = TROLL;
|
||||
uiPhaseCounter = 0;
|
||||
DoScriptText(SAY_TRANSFORM_2, me);
|
||||
uiTransformationTimer = 9*IN_MILISECONDS;
|
||||
uiTransformationTimer = 9*IN_MILLISECONDS;
|
||||
bStartOfTransformation = true;
|
||||
me->clearUnitState(UNIT_STAT_STUNNED|UNIT_STAT_ROOT);
|
||||
me->SetReactState(REACT_AGGRESSIVE);
|
||||
@@ -205,19 +205,19 @@ struct boss_gal_darahAI : public ScriptedAI
|
||||
if (uiPunctureTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_PUNCTURE);
|
||||
uiPunctureTimer = 8*IN_MILISECONDS;
|
||||
uiPunctureTimer = 8*IN_MILLISECONDS;
|
||||
} else uiPunctureTimer -= diff;
|
||||
|
||||
if (uiEnrageTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_ENRAGE);
|
||||
uiEnrageTimer = 20*IN_MILISECONDS;
|
||||
uiEnrageTimer = 20*IN_MILLISECONDS;
|
||||
} else uiEnrageTimer -= diff;
|
||||
|
||||
if (uiStompTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_STOMP);
|
||||
uiStompTimer = 20*IN_MILISECONDS;
|
||||
uiStompTimer = 20*IN_MILLISECONDS;
|
||||
} else uiStompTimer -= diff;
|
||||
|
||||
if (uiImpalingChargeTimer <= diff)
|
||||
@@ -227,7 +227,7 @@ struct boss_gal_darahAI : public ScriptedAI
|
||||
DoCast(pTarget, SPELL_IMPALING_CHARGE);
|
||||
lImpaledPlayers.insert(pTarget->GetGUID());
|
||||
}
|
||||
uiImpalingChargeTimer = 31*IN_MILISECONDS;
|
||||
uiImpalingChargeTimer = 31*IN_MILLISECONDS;
|
||||
++uiPhaseCounter;
|
||||
} else uiImpalingChargeTimer -= diff;
|
||||
}
|
||||
|
||||
@@ -66,10 +66,10 @@ struct boss_moorabiAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiGroundTremorTimer = 18*IN_MILISECONDS;
|
||||
uiNumblingShoutTimer = 10*IN_MILISECONDS;
|
||||
uiDeterminedStabTimer = 20*IN_MILISECONDS;
|
||||
uiTransformationTImer = 12*IN_MILISECONDS;
|
||||
uiGroundTremorTimer = 18*IN_MILLISECONDS;
|
||||
uiNumblingShoutTimer = 10*IN_MILLISECONDS;
|
||||
uiDeterminedStabTimer = 20*IN_MILLISECONDS;
|
||||
uiTransformationTImer = 12*IN_MILLISECONDS;
|
||||
bPhase = false;
|
||||
|
||||
if (pInstance)
|
||||
@@ -104,7 +104,7 @@ struct boss_moorabiAI : public ScriptedAI
|
||||
DoCast(me->getVictim(), SPELL_QUAKE, true);
|
||||
else
|
||||
DoCast(me->getVictim(), SPELL_GROUND_TREMOR, true);
|
||||
uiGroundTremorTimer = 10*IN_MILISECONDS;
|
||||
uiGroundTremorTimer = 10*IN_MILLISECONDS;
|
||||
} else uiGroundTremorTimer -= uiDiff;
|
||||
|
||||
if (uiNumblingShoutTimer <= uiDiff)
|
||||
@@ -113,7 +113,7 @@ struct boss_moorabiAI : public ScriptedAI
|
||||
DoCast(me->getVictim(), SPELL_NUMBING_ROAR, true);
|
||||
else
|
||||
DoCast(me->getVictim(), SPELL_NUMBING_SHOUT, true);
|
||||
uiNumblingShoutTimer = 10*IN_MILISECONDS;
|
||||
uiNumblingShoutTimer = 10*IN_MILLISECONDS;
|
||||
} else uiNumblingShoutTimer -=uiDiff;
|
||||
|
||||
if (uiDeterminedStabTimer <= uiDiff)
|
||||
@@ -122,7 +122,7 @@ struct boss_moorabiAI : public ScriptedAI
|
||||
DoCast(me->getVictim(), SPELL_DETERMINED_GORE);
|
||||
else
|
||||
DoCast(me->getVictim(), SPELL_DETERMINED_STAB, true);
|
||||
uiDeterminedStabTimer = 8*IN_MILISECONDS;
|
||||
uiDeterminedStabTimer = 8*IN_MILLISECONDS;
|
||||
} else uiDeterminedStabTimer -=uiDiff;
|
||||
|
||||
if (!bPhase && uiTransformationTImer <= uiDiff)
|
||||
@@ -130,7 +130,7 @@ struct boss_moorabiAI : public ScriptedAI
|
||||
DoScriptText(EMOTE_TRANSFORM, me);
|
||||
DoScriptText(SAY_TRANSFORM, me);
|
||||
DoCast(me, SPELL_TRANSFORMATION, false);
|
||||
uiTransformationTImer = 10*IN_MILISECONDS;
|
||||
uiTransformationTImer = 10*IN_MILLISECONDS;
|
||||
} else uiTransformationTImer -= uiDiff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -85,10 +85,10 @@ struct boss_slad_ranAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiPoisonNovaTimer = 10*IN_MILISECONDS;
|
||||
uiPowerfullBiteTimer = 3*IN_MILISECONDS;
|
||||
uiVenomBoltTimer = 15*IN_MILISECONDS;
|
||||
uiSpawnTimer = 5*IN_MILISECONDS;
|
||||
uiPoisonNovaTimer = 10*IN_MILLISECONDS;
|
||||
uiPowerfullBiteTimer = 3*IN_MILLISECONDS;
|
||||
uiVenomBoltTimer = 15*IN_MILLISECONDS;
|
||||
uiSpawnTimer = 5*IN_MILLISECONDS;
|
||||
uiPhase = 0;
|
||||
|
||||
lSummons.DespawnAll();
|
||||
@@ -114,19 +114,19 @@ struct boss_slad_ranAI : public ScriptedAI
|
||||
if (uiPoisonNovaTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_POISON_NOVA);
|
||||
uiPoisonNovaTimer = 15*IN_MILISECONDS;
|
||||
uiPoisonNovaTimer = 15*IN_MILLISECONDS;
|
||||
} else uiPoisonNovaTimer -= diff;
|
||||
|
||||
if (uiPowerfullBiteTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_POWERFULL_BITE);
|
||||
uiPowerfullBiteTimer = 10*IN_MILISECONDS;
|
||||
uiPowerfullBiteTimer = 10*IN_MILLISECONDS;
|
||||
} else uiPowerfullBiteTimer -= diff;
|
||||
|
||||
if (uiVenomBoltTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_VENOM_BOLT);
|
||||
uiVenomBoltTimer = 10*IN_MILISECONDS;
|
||||
uiVenomBoltTimer = 10*IN_MILLISECONDS;
|
||||
} else uiVenomBoltTimer -= diff;
|
||||
|
||||
if (uiPhase)
|
||||
@@ -135,11 +135,11 @@ struct boss_slad_ranAI : public ScriptedAI
|
||||
{
|
||||
if (uiPhase == 1)
|
||||
for (uint8 i = 0; i < DUNGEON_MODE(3, 5); ++i)
|
||||
me->SummonCreature(CREATURE_SNAKE, SpawnLoc[i], TEMPSUMMON_CORPSE_TIMED_DESPAWN,20*IN_MILISECONDS);
|
||||
me->SummonCreature(CREATURE_SNAKE, SpawnLoc[i], TEMPSUMMON_CORPSE_TIMED_DESPAWN,20*IN_MILLISECONDS);
|
||||
if (uiPhase == 2)
|
||||
for (uint8 i = 0; i < DUNGEON_MODE(3, 5); ++i)
|
||||
me->SummonCreature(CREATURE_CONSTRICTORS, SpawnLoc[i], TEMPSUMMON_CORPSE_TIMED_DESPAWN,20*IN_MILISECONDS);
|
||||
uiSpawnTimer = 5*IN_MILISECONDS;
|
||||
me->SummonCreature(CREATURE_CONSTRICTORS, SpawnLoc[i], TEMPSUMMON_CORPSE_TIMED_DESPAWN,20*IN_MILLISECONDS);
|
||||
uiSpawnTimer = 5*IN_MILLISECONDS;
|
||||
} else uiSpawnTimer -= diff;
|
||||
}
|
||||
|
||||
@@ -186,7 +186,7 @@ struct mob_slad_ran_constrictorAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiGripOfSladRanTimer = 1*IN_MILISECONDS;
|
||||
uiGripOfSladRanTimer = 1*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -196,7 +196,7 @@ struct mob_slad_ran_constrictorAI : public ScriptedAI
|
||||
if (uiGripOfSladRanTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_GRIP_OF_SLAD_RAN);
|
||||
uiGripOfSladRanTimer = 5*IN_MILISECONDS;
|
||||
uiGripOfSladRanTimer = 5*IN_MILLISECONDS;
|
||||
} else uiGripOfSladRanTimer -= diff;
|
||||
}
|
||||
|
||||
@@ -213,7 +213,7 @@ struct mob_slad_ran_viperAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiVenomousBiteTimer = 2*IN_MILISECONDS;
|
||||
uiVenomousBiteTimer = 2*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -224,7 +224,7 @@ struct mob_slad_ran_viperAI : public ScriptedAI
|
||||
if (uiVenomousBiteTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_VENOMOUS_BITE);
|
||||
uiVenomousBiteTimer = 10*IN_MILISECONDS;
|
||||
uiVenomousBiteTimer = 10*IN_MILLISECONDS;
|
||||
} else uiVenomousBiteTimer -= diff;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -78,7 +78,7 @@ struct boss_anomalusAI : public ScriptedAI
|
||||
void Reset()
|
||||
{
|
||||
Phase = 0;
|
||||
uiSparkTimer = 5*IN_MILISECONDS;
|
||||
uiSparkTimer = 5*IN_MILLISECONDS;
|
||||
uiChaoticRiftGUID = 0;
|
||||
|
||||
bDeadChaoticRift = false;
|
||||
@@ -139,7 +139,7 @@ struct boss_anomalusAI : public ScriptedAI
|
||||
Phase = 1;
|
||||
DoScriptText(SAY_SHIELD, me);
|
||||
DoCast(me, SPELL_RIFT_SHIELD);
|
||||
Creature* Rift = me->SummonCreature(MOB_CHAOTIC_RIFT, RiftLocation[urand(0,5)], TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 1*IN_MILISECONDS);
|
||||
Creature* Rift = me->SummonCreature(MOB_CHAOTIC_RIFT, RiftLocation[urand(0,5)], TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 1*IN_MILLISECONDS);
|
||||
if (Rift)
|
||||
{
|
||||
//DoCast(Rift, SPELL_CHARGE_RIFT);
|
||||
@@ -155,7 +155,7 @@ struct boss_anomalusAI : public ScriptedAI
|
||||
{
|
||||
if (Unit *pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_SPARK);
|
||||
uiSparkTimer = 5*IN_MILISECONDS;
|
||||
uiSparkTimer = 5*IN_MILLISECONDS;
|
||||
} else uiSparkTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -188,8 +188,8 @@ struct mob_chaotic_riftAI : public Scripted_NoMovementAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiChaoticEnergyBurstTimer = 1*IN_MILISECONDS;
|
||||
uiSummonCrazedManaWraithTimer = 5*IN_MILISECONDS;
|
||||
uiChaoticEnergyBurstTimer = 1*IN_MILLISECONDS;
|
||||
uiSummonCrazedManaWraithTimer = 5*IN_MILLISECONDS;
|
||||
//me->SetDisplayId(25206); //For some reason in DB models for ally and horde are different.
|
||||
//Model for ally (1126) does not show auras. Horde model works perfect.
|
||||
//Set model to horde number
|
||||
@@ -215,20 +215,20 @@ struct mob_chaotic_riftAI : public Scripted_NoMovementAI
|
||||
DoCast(pTarget, SPELL_CHARGED_CHAOTIC_ENERGY_BURST);
|
||||
else
|
||||
DoCast(pTarget, SPELL_CHAOTIC_ENERGY_BURST);
|
||||
uiChaoticEnergyBurstTimer = 1*IN_MILISECONDS;
|
||||
uiChaoticEnergyBurstTimer = 1*IN_MILLISECONDS;
|
||||
} else uiChaoticEnergyBurstTimer -= diff;
|
||||
|
||||
if (uiSummonCrazedManaWraithTimer <= diff)
|
||||
{
|
||||
Creature* Wraith = me->SummonCreature(MOB_CRAZED_MANA_WRAITH, me->GetPositionX()+1, me->GetPositionY()+1, me->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 1*IN_MILISECONDS);
|
||||
Creature* Wraith = me->SummonCreature(MOB_CRAZED_MANA_WRAITH, me->GetPositionX()+1, me->GetPositionY()+1, me->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 1*IN_MILLISECONDS);
|
||||
if (Wraith)
|
||||
if (Unit *pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0))
|
||||
Wraith->AI()->AttackStart(pTarget);
|
||||
Unit* Anomalus = Unit::GetUnit(*me, pInstance ? pInstance->GetData64(DATA_ANOMALUS) : 0);
|
||||
if (Anomalus && Anomalus->HasAura(SPELL_RIFT_SHIELD))
|
||||
uiSummonCrazedManaWraithTimer = 5*IN_MILISECONDS;
|
||||
uiSummonCrazedManaWraithTimer = 5*IN_MILLISECONDS;
|
||||
else
|
||||
uiSummonCrazedManaWraithTimer = 10*IN_MILISECONDS;
|
||||
uiSummonCrazedManaWraithTimer = 10*IN_MILLISECONDS;
|
||||
} else uiSummonCrazedManaWraithTimer -= diff;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -71,12 +71,12 @@ struct boss_keristraszaAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiCrystalfireBreathTimer = 14*IN_MILISECONDS;
|
||||
uiCrystalChainsCrystalizeTimer = DUNGEON_MODE(30*IN_MILISECONDS,11*IN_MILISECONDS);
|
||||
uiTailSweepTimer = 5*IN_MILISECONDS;
|
||||
uiCrystalfireBreathTimer = 14*IN_MILLISECONDS;
|
||||
uiCrystalChainsCrystalizeTimer = DUNGEON_MODE(30*IN_MILLISECONDS,11*IN_MILLISECONDS);
|
||||
uiTailSweepTimer = 5*IN_MILLISECONDS;
|
||||
bEnrage = false;
|
||||
|
||||
uiCheckIntenseColdTimer = 2*IN_MILISECONDS;
|
||||
uiCheckIntenseColdTimer = 2*IN_MILLISECONDS;
|
||||
bMoreThanTwoIntenseCold = false;
|
||||
|
||||
me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_STUNNED);
|
||||
@@ -175,7 +175,7 @@ struct boss_keristraszaAI : public ScriptedAI
|
||||
break;
|
||||
}
|
||||
}
|
||||
uiCheckIntenseColdTimer = 2*IN_MILISECONDS;
|
||||
uiCheckIntenseColdTimer = 2*IN_MILLISECONDS;
|
||||
} else uiCheckIntenseColdTimer -= diff;
|
||||
|
||||
if (!bEnrage && HealthBelowPct(25))
|
||||
@@ -188,13 +188,13 @@ struct boss_keristraszaAI : public ScriptedAI
|
||||
if (uiCrystalfireBreathTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_CRYSTALFIRE_BREATH);
|
||||
uiCrystalfireBreathTimer = 14*IN_MILISECONDS;
|
||||
uiCrystalfireBreathTimer = 14*IN_MILLISECONDS;
|
||||
} else uiCrystalfireBreathTimer -= diff;
|
||||
|
||||
if (uiTailSweepTimer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_TAIL_SWEEP);
|
||||
uiTailSweepTimer = 5*IN_MILISECONDS;
|
||||
uiTailSweepTimer = 5*IN_MILLISECONDS;
|
||||
} else uiTailSweepTimer -= diff;
|
||||
|
||||
if (uiCrystalChainsCrystalizeTimer <= diff)
|
||||
@@ -204,7 +204,7 @@ struct boss_keristraszaAI : public ScriptedAI
|
||||
DoCast(me, SPELL_CRYSTALIZE);
|
||||
else if (Unit *pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
DoCast(pTarget, SPELL_CRYSTAL_CHAINS);
|
||||
uiCrystalChainsCrystalizeTimer = DUNGEON_MODE(30*IN_MILISECONDS,11*IN_MILISECONDS);
|
||||
uiCrystalChainsCrystalizeTimer = DUNGEON_MODE(30*IN_MILLISECONDS,11*IN_MILLISECONDS);
|
||||
} else uiCrystalChainsCrystalizeTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -50,7 +50,7 @@ enum Yells
|
||||
enum Achievements
|
||||
{
|
||||
ACHIEV_SPLIT_PERSONALITY = 2150,
|
||||
ACHIEV_TIMER = 5*IN_MILISECONDS
|
||||
ACHIEV_TIMER = 5*IN_MILLISECONDS
|
||||
};
|
||||
|
||||
const Position CenterOfRoom = {504.80, 89.07, -16.12, 6.27};
|
||||
@@ -88,9 +88,9 @@ struct boss_magus_telestraAI : public ScriptedAI
|
||||
{
|
||||
Phase = 0;
|
||||
//These times are probably wrong
|
||||
uiIceNovaTimer = 7*IN_MILISECONDS;
|
||||
uiIceNovaTimer = 7*IN_MILLISECONDS;
|
||||
uiFireBombTimer = 0;
|
||||
uiGravityWellTimer = 15*IN_MILISECONDS;
|
||||
uiGravityWellTimer = 15*IN_MILLISECONDS;
|
||||
uiCooldown = 0;
|
||||
|
||||
uiFireMagusGUID = 0;
|
||||
@@ -137,7 +137,7 @@ struct boss_magus_telestraAI : public ScriptedAI
|
||||
|
||||
uint64 SplitPersonality(uint32 entry)
|
||||
{
|
||||
if (Creature* Summoned = me->SummonCreature(entry, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation(), TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 1*IN_MILISECONDS))
|
||||
if (Creature* Summoned = me->SummonCreature(entry, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), me->GetOrientation(), TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 1*IN_MILLISECONDS))
|
||||
{
|
||||
switch (entry)
|
||||
{
|
||||
@@ -224,7 +224,7 @@ struct boss_magus_telestraAI : public ScriptedAI
|
||||
uiFrostMagusGUID = 0;
|
||||
uiArcaneMagusGUID = 0;
|
||||
bIsWaitingToAppear = true;
|
||||
uiIsWaitingToAppearTimer = 4*IN_MILISECONDS;
|
||||
uiIsWaitingToAppearTimer = 4*IN_MILLISECONDS;
|
||||
DoScriptText(SAY_MERGE, me);
|
||||
bIsAchievementTimerRunning = false;
|
||||
uiAchievementTimer = 0;
|
||||
@@ -283,9 +283,9 @@ struct boss_magus_telestraAI : public ScriptedAI
|
||||
if (Unit *pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0))
|
||||
{
|
||||
DoCast(pTarget, SPELL_ICE_NOVA, false);
|
||||
uiCooldown = 1.5*IN_MILISECONDS;
|
||||
uiCooldown = 1.5*IN_MILLISECONDS;
|
||||
}
|
||||
uiIceNovaTimer = 15*IN_MILISECONDS;
|
||||
uiIceNovaTimer = 15*IN_MILLISECONDS;
|
||||
} else uiIceNovaTimer -= diff;
|
||||
|
||||
if (uiGravityWellTimer <= diff)
|
||||
@@ -293,9 +293,9 @@ struct boss_magus_telestraAI : public ScriptedAI
|
||||
if (Unit *pTarget = me->getVictim())
|
||||
{
|
||||
DoCast(pTarget, SPELL_GRAVITY_WELL);
|
||||
uiCooldown = 6*IN_MILISECONDS;
|
||||
uiCooldown = 6*IN_MILLISECONDS;
|
||||
}
|
||||
uiGravityWellTimer = 15*IN_MILISECONDS;
|
||||
uiGravityWellTimer = 15*IN_MILLISECONDS;
|
||||
} else uiGravityWellTimer -= diff;
|
||||
|
||||
if (uiFireBombTimer <= diff)
|
||||
@@ -303,9 +303,9 @@ struct boss_magus_telestraAI : public ScriptedAI
|
||||
if (Unit *pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0))
|
||||
{
|
||||
DoCast(pTarget, SPELL_FIREBOMB, false);
|
||||
uiCooldown = 2*IN_MILISECONDS;
|
||||
uiCooldown = 2*IN_MILLISECONDS;
|
||||
}
|
||||
uiFireBombTimer = 2*IN_MILISECONDS;
|
||||
uiFireBombTimer = 2*IN_MILLISECONDS;
|
||||
} else uiFireBombTimer -=diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
|
||||
@@ -76,10 +76,10 @@ struct boss_ormorokAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiCrystalSpikesTimer = 12*IN_MILISECONDS;
|
||||
uiTrampleTimer = 10*IN_MILISECONDS;
|
||||
uiSpellReflectionTimer = 30*IN_MILISECONDS;
|
||||
uiSummonCrystallineTanglerTimer = 17*IN_MILISECONDS;
|
||||
uiCrystalSpikesTimer = 12*IN_MILLISECONDS;
|
||||
uiTrampleTimer = 10*IN_MILLISECONDS;
|
||||
uiSpellReflectionTimer = 30*IN_MILLISECONDS;
|
||||
uiSummonCrystallineTanglerTimer = 17*IN_MILLISECONDS;
|
||||
bFrenzy = false;
|
||||
bCrystalSpikes = false;
|
||||
|
||||
@@ -126,7 +126,7 @@ struct boss_ormorokAI : public ScriptedAI
|
||||
fSpikeXY[3][0] = fBaseX-(SPIKE_DISTANCE*uiCrystalSpikesCount*cos(fBaseO-(M_PI/2)));
|
||||
fSpikeXY[3][1] = fBaseY-(SPIKE_DISTANCE*uiCrystalSpikesCount*sin(fBaseO-(M_PI/2)));
|
||||
for (uint8 i = 0; i < 4; ++i)
|
||||
me->SummonCreature(MOB_CRYSTAL_SPIKE, fSpikeXY[i][0], fSpikeXY[i][1], fBaseZ, 0, TEMPSUMMON_TIMED_DESPAWN, 7*IN_MILISECONDS);
|
||||
me->SummonCreature(MOB_CRYSTAL_SPIKE, fSpikeXY[i][0], fSpikeXY[i][1], fBaseZ, 0, TEMPSUMMON_TIMED_DESPAWN, 7*IN_MILLISECONDS);
|
||||
if (++uiCrystalSpikesCount >= 13)
|
||||
bCrystalSpikes = false;
|
||||
uiCrystalSpikesTimer2 = 200;
|
||||
@@ -141,14 +141,14 @@ struct boss_ormorokAI : public ScriptedAI
|
||||
if (uiTrampleTimer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_TRAMPLE);
|
||||
uiTrampleTimer = 10*IN_MILISECONDS;
|
||||
uiTrampleTimer = 10*IN_MILLISECONDS;
|
||||
} else uiTrampleTimer -= diff;
|
||||
|
||||
if (uiSpellReflectionTimer <= diff)
|
||||
{
|
||||
DoScriptText(SAY_REFLECT, me);
|
||||
DoCast(me, SPELL_SPELL_REFLECTION);
|
||||
uiSpellReflectionTimer = 30*IN_MILISECONDS;
|
||||
uiSpellReflectionTimer = 30*IN_MILLISECONDS;
|
||||
} else uiSpellReflectionTimer -= diff;
|
||||
|
||||
if (uiCrystalSpikesTimer <= diff)
|
||||
@@ -161,7 +161,7 @@ struct boss_ormorokAI : public ScriptedAI
|
||||
fBaseY = me->GetPositionY();
|
||||
fBaseZ = me->GetPositionZ();
|
||||
fBaseO = me->GetOrientation();
|
||||
uiCrystalSpikesTimer = 20*IN_MILISECONDS;
|
||||
uiCrystalSpikesTimer = 20*IN_MILLISECONDS;
|
||||
} else uiCrystalSpikesTimer -= diff;
|
||||
|
||||
if (IsHeroic() && (uiSummonCrystallineTanglerTimer <= diff))
|
||||
@@ -201,7 +201,7 @@ struct boss_ormorokAI : public ScriptedAI
|
||||
Crystalline_Tangler->getThreatManager().addThreat(pTarget, 1000000000.0f);
|
||||
}
|
||||
}
|
||||
uiSummonCrystallineTanglerTimer = 17*IN_MILISECONDS;
|
||||
uiSummonCrystallineTanglerTimer = 17*IN_MILLISECONDS;
|
||||
} else uiSummonCrystallineTanglerTimer -= diff;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
@@ -219,8 +219,8 @@ struct mob_crystal_spikeAI : public Scripted_NoMovementAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
SpellCrystalSpikeDamageTimer = 3.7*IN_MILISECONDS;
|
||||
SpellCrystalSpikePrevisualTimer = 1*IN_MILISECONDS;
|
||||
SpellCrystalSpikeDamageTimer = 3.7*IN_MILLISECONDS;
|
||||
SpellCrystalSpikePrevisualTimer = 1*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -228,13 +228,13 @@ struct mob_crystal_spikeAI : public Scripted_NoMovementAI
|
||||
if (SpellCrystalSpikePrevisualTimer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_CRYSTAL_SPIKE_PREVISUAL);
|
||||
SpellCrystalSpikePrevisualTimer = 10*IN_MILISECONDS;
|
||||
SpellCrystalSpikePrevisualTimer = 10*IN_MILLISECONDS;
|
||||
} else SpellCrystalSpikePrevisualTimer -= diff;
|
||||
|
||||
if (SpellCrystalSpikeDamageTimer <= diff)
|
||||
{
|
||||
DoCast(me, SPELL_CRYSTALL_SPIKE_DAMAGE);
|
||||
SpellCrystalSpikeDamageTimer = 10*IN_MILISECONDS;
|
||||
SpellCrystalSpikeDamageTimer = 10*IN_MILLISECONDS;
|
||||
} else SpellCrystalSpikeDamageTimer -= diff;
|
||||
}
|
||||
};
|
||||
@@ -247,7 +247,7 @@ struct mob_crystalline_tanglerAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiRootsTimer = 1*IN_MILISECONDS;
|
||||
uiRootsTimer = 1*IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
@@ -257,7 +257,7 @@ struct mob_crystalline_tanglerAI : public ScriptedAI
|
||||
if (me->IsWithinDist(me->getVictim(), 5.0f, false))
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_ROOTS);
|
||||
uiRootsTimer = 15*IN_MILISECONDS;
|
||||
uiRootsTimer = 15*IN_MILLISECONDS;
|
||||
}
|
||||
} else uiRootsTimer -= diff;
|
||||
}
|
||||
|
||||
@@ -189,7 +189,7 @@ struct npc_unstable_sphereAI : public ScriptedAI
|
||||
if (uiPulseTimer <= uiDiff)
|
||||
{
|
||||
DoCast(SPELL_UNSTABLE_SPHERE_PULSE);
|
||||
uiPulseTimer = 3*IN_MILISECONDS;
|
||||
uiPulseTimer = 3*IN_MILLISECONDS;
|
||||
} else uiPulseTimer -= uiDiff;
|
||||
|
||||
if (uiDeathTimer <= uiDiff)
|
||||
|
||||
@@ -252,7 +252,7 @@ struct boss_sartharionAI : public ScriptedAI
|
||||
m_bIsBerserk = false;
|
||||
m_bIsSoftEnraged = false;
|
||||
|
||||
m_uiEnrageTimer = 15*MINUTE*IN_MILISECONDS;
|
||||
m_uiEnrageTimer = 15*MINUTE*IN_MILLISECONDS;
|
||||
m_bIsHardEnraged = false;
|
||||
|
||||
m_uiTenebronTimer = 30000;
|
||||
|
||||
@@ -94,10 +94,10 @@ struct boss_ionarAI : public ScriptedAI
|
||||
bIsSplitPhase = true;
|
||||
bHasDispersed = false;
|
||||
|
||||
uiSplitTimer = 25*IN_MILISECONDS;
|
||||
uiSplitTimer = 25*IN_MILLISECONDS;
|
||||
|
||||
uiStaticOverloadTimer = urand(5*IN_MILISECONDS, 6*IN_MILISECONDS);
|
||||
uiBallLightningTimer = urand(10*IN_MILISECONDS, 11*IN_MILISECONDS);
|
||||
uiStaticOverloadTimer = urand(5*IN_MILLISECONDS, 6*IN_MILLISECONDS);
|
||||
uiBallLightningTimer = urand(10*IN_MILLISECONDS, 11*IN_MILLISECONDS);
|
||||
|
||||
uiDisperseHealth = 45 + urand(0,10);
|
||||
|
||||
@@ -200,7 +200,7 @@ struct boss_ionarAI : public ScriptedAI
|
||||
{
|
||||
if (uiSplitTimer <= uiDiff)
|
||||
{
|
||||
uiSplitTimer = 2.5*IN_MILISECONDS;
|
||||
uiSplitTimer = 2.5*IN_MILLISECONDS;
|
||||
|
||||
// Return sparks to where Ionar splitted
|
||||
if (bIsSplitPhase)
|
||||
@@ -216,7 +216,7 @@ struct boss_ionarAI : public ScriptedAI
|
||||
|
||||
DoCast(me, SPELL_SPARK_DESPAWN, false);
|
||||
|
||||
uiSplitTimer = 25*IN_MILISECONDS;
|
||||
uiSplitTimer = 25*IN_MILLISECONDS;
|
||||
bIsSplitPhase = true;
|
||||
|
||||
if (me->getVictim())
|
||||
@@ -234,7 +234,7 @@ struct boss_ionarAI : public ScriptedAI
|
||||
if (Unit* pTarget = SelectUnit(SELECT_TARGET_RANDOM, 0))
|
||||
DoCast(pTarget, SPELL_STATIC_OVERLOAD);
|
||||
|
||||
uiStaticOverloadTimer = urand(5*IN_MILISECONDS, 6*IN_MILISECONDS);
|
||||
uiStaticOverloadTimer = urand(5*IN_MILLISECONDS, 6*IN_MILLISECONDS);
|
||||
}
|
||||
else
|
||||
uiStaticOverloadTimer -= uiDiff;
|
||||
@@ -242,7 +242,7 @@ struct boss_ionarAI : public ScriptedAI
|
||||
if (uiBallLightningTimer <= uiDiff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_BALL_LIGHTNING);
|
||||
uiBallLightningTimer = urand(10*IN_MILISECONDS, 11*IN_MILISECONDS);
|
||||
uiBallLightningTimer = urand(10*IN_MILLISECONDS, 11*IN_MILLISECONDS);
|
||||
}
|
||||
else
|
||||
uiBallLightningTimer -= uiDiff;
|
||||
@@ -310,7 +310,7 @@ struct mob_spark_of_ionarAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiCheckTimer = 2*IN_MILISECONDS;
|
||||
uiCheckTimer = 2*IN_MILLISECONDS;
|
||||
me->SetReactState(REACT_PASSIVE);
|
||||
}
|
||||
|
||||
@@ -358,7 +358,7 @@ struct mob_spark_of_ionarAI : public ScriptedAI
|
||||
else
|
||||
me->ForcedDespawn();
|
||||
}
|
||||
uiCheckTimer = 2*IN_MILISECONDS;
|
||||
uiCheckTimer = 2*IN_MILLISECONDS;
|
||||
}
|
||||
else
|
||||
uiCheckTimer -= uiDiff;
|
||||
|
||||
@@ -253,7 +253,7 @@ struct boss_skadiAI : public ScriptedAI
|
||||
break;
|
||||
case CREATURE_TRIGGER:
|
||||
pSummoned->CastSpell((Unit*)NULL, SPELL_FREEZING_CLOUD, true);
|
||||
pSummoned->ForcedDespawn(10*IN_MILISECONDS);
|
||||
pSummoned->ForcedDespawn(10*IN_MILLISECONDS);
|
||||
break;
|
||||
}
|
||||
Summons.Summon(pSummoned);
|
||||
@@ -276,7 +276,7 @@ struct boss_skadiAI : public ScriptedAI
|
||||
Phase = SKADI;
|
||||
me->SetFlying(false);
|
||||
me->Unmount();
|
||||
if(Creature* pGrauf = me->SummonCreature(CREATURE_GRAUF, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), 0, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 3*IN_MILISECONDS))
|
||||
if(Creature* pGrauf = me->SummonCreature(CREATURE_GRAUF, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ(), 0, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 3*IN_MILLISECONDS))
|
||||
{
|
||||
pGrauf->GetMotionMaster()->MoveFall(0);
|
||||
pGrauf->HandleEmoteCommand(EMOTE_ONESHOT_FLYDEATH);
|
||||
|
||||
@@ -105,7 +105,7 @@ struct boss_svalaAI : public ScriptedAI
|
||||
void Reset()
|
||||
{
|
||||
Phase = IDLE;
|
||||
uiIntroTimer = 1*IN_MILISECONDS;
|
||||
uiIntroTimer = 1*IN_MILLISECONDS;
|
||||
uiIntroPhase = 0;
|
||||
uiArthasGUID = 0;
|
||||
|
||||
@@ -150,28 +150,28 @@ struct boss_svalaAI : public ScriptedAI
|
||||
case 0:
|
||||
DoScriptText(SAY_DIALOG_WITH_ARTHAS_1, me);
|
||||
++uiIntroPhase;
|
||||
uiIntroTimer = 3.5*IN_MILISECONDS;
|
||||
uiIntroTimer = 3.5*IN_MILLISECONDS;
|
||||
break;
|
||||
case 1:
|
||||
DoScriptText(SAY_DIALOG_OF_ARTHAS_1, pArthas);
|
||||
++uiIntroPhase;
|
||||
uiIntroTimer = 3.5*IN_MILISECONDS;
|
||||
uiIntroTimer = 3.5*IN_MILLISECONDS;
|
||||
break;
|
||||
case 2:
|
||||
DoScriptText(SAY_DIALOG_WITH_ARTHAS_2, me);
|
||||
++uiIntroPhase;
|
||||
uiIntroTimer = 3.5*IN_MILISECONDS;
|
||||
uiIntroTimer = 3.5*IN_MILLISECONDS;
|
||||
break;
|
||||
case 3:
|
||||
DoScriptText(SAY_DIALOG_OF_ARTHAS_2, pArthas);
|
||||
++uiIntroPhase;
|
||||
uiIntroTimer = 3.5*IN_MILISECONDS;
|
||||
uiIntroTimer = 3.5*IN_MILLISECONDS;
|
||||
break;
|
||||
case 4:
|
||||
DoScriptText(SAY_DIALOG_WITH_ARTHAS_3, me);
|
||||
DoCast(me, SPELL_SVALA_TRANSFORMING1);
|
||||
++uiIntroPhase;
|
||||
uiIntroTimer = 2.8*IN_MILISECONDS;
|
||||
uiIntroTimer = 2.8*IN_MILLISECONDS;
|
||||
break;
|
||||
case 5:
|
||||
DoCast(me, SPELL_SVALA_TRANSFORMING2);
|
||||
@@ -179,7 +179,7 @@ struct boss_svalaAI : public ScriptedAI
|
||||
uiIntroTimer = 200;
|
||||
break;
|
||||
case 6:
|
||||
if (Creature* pSvalaSorrowgrave = me->SummonCreature(CREATURE_SVALA_SORROWGRAVE, SvalaPos, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 60*IN_MILISECONDS))
|
||||
if (Creature* pSvalaSorrowgrave = me->SummonCreature(CREATURE_SVALA_SORROWGRAVE, SvalaPos, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 60*IN_MILLISECONDS))
|
||||
{
|
||||
me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE|UNIT_FLAG_NOT_SELECTABLE);
|
||||
me->SetDisplayId(DATA_SVALA_DISPLAY_ID);
|
||||
@@ -244,10 +244,10 @@ struct boss_svala_sorrowgraveAI : public ScriptedAI
|
||||
|
||||
void Reset()
|
||||
{
|
||||
uiSinsterStrikeTimer = 7*IN_MILISECONDS;
|
||||
uiCallFlamesTimer = 10*IN_MILISECONDS;
|
||||
uiRitualOfSwordTimer = 20*IN_MILISECONDS;
|
||||
uiSacrificeTimer = 8*IN_MILISECONDS;
|
||||
uiSinsterStrikeTimer = 7*IN_MILLISECONDS;
|
||||
uiCallFlamesTimer = 10*IN_MILLISECONDS;
|
||||
uiRitualOfSwordTimer = 20*IN_MILLISECONDS;
|
||||
uiSacrificeTimer = 8*IN_MILLISECONDS;
|
||||
|
||||
bSacrificed = false;
|
||||
|
||||
@@ -294,7 +294,7 @@ struct boss_svala_sorrowgraveAI : public ScriptedAI
|
||||
if (uiSinsterStrikeTimer <= diff)
|
||||
{
|
||||
DoCast(me->getVictim(), SPELL_SINSTER_STRIKE);
|
||||
uiSinsterStrikeTimer = urand(5*IN_MILISECONDS,9*IN_MILISECONDS);
|
||||
uiSinsterStrikeTimer = urand(5*IN_MILLISECONDS,9*IN_MILLISECONDS);
|
||||
} else uiSinsterStrikeTimer -= diff;
|
||||
|
||||
if (uiCallFlamesTimer <= diff)
|
||||
@@ -302,7 +302,7 @@ struct boss_svala_sorrowgraveAI : public ScriptedAI
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
{
|
||||
DoCast(pTarget, SPELL_CALL_FLAMES);
|
||||
uiCallFlamesTimer = urand(8*IN_MILISECONDS,12*IN_MILISECONDS);
|
||||
uiCallFlamesTimer = urand(8*IN_MILLISECONDS,12*IN_MILLISECONDS);
|
||||
}
|
||||
} else uiCallFlamesTimer -= diff;
|
||||
|
||||
@@ -348,7 +348,7 @@ struct boss_svala_sorrowgraveAI : public ScriptedAI
|
||||
if (Unit* pTarget = SelectTarget(SELECT_TARGET_RANDOM, 0, 100, true))
|
||||
me->GetMotionMaster()->MoveChase(pTarget);
|
||||
|
||||
uiSacrificeTimer = 8*IN_MILISECONDS;
|
||||
uiSacrificeTimer = 8*IN_MILLISECONDS;
|
||||
}
|
||||
else uiSacrificeTimer -= diff;
|
||||
}
|
||||
|
||||
@@ -199,7 +199,7 @@ struct instance_violet_hold : public ScriptedInstance
|
||||
|
||||
uiActivationTimer = 5000;
|
||||
uiDoorSpellTimer = 2000;
|
||||
uiCyanigosaEventTimer = 3*IN_MILISECONDS;
|
||||
uiCyanigosaEventTimer = 3*IN_MILLISECONDS;
|
||||
|
||||
bActive = false;
|
||||
bIsDoorSpellCasted = false;
|
||||
@@ -726,13 +726,13 @@ struct instance_violet_hold : public ScriptedInstance
|
||||
case 1:
|
||||
pCyanigosa->CastSpell(pCyanigosa, CYANIGOSA_BLUE_AURA, false);
|
||||
DoScriptText(CYANIGOSA_SAY_SPAWN, pCyanigosa);
|
||||
uiCyanigosaEventTimer = 7*IN_MILISECONDS;
|
||||
uiCyanigosaEventTimer = 7*IN_MILLISECONDS;
|
||||
++uiCyanigosaEventPhase;
|
||||
break;
|
||||
case 2:
|
||||
pCyanigosa->GetMotionMaster()->MoveJump(MiddleRoomLocation.GetPositionX(), MiddleRoomLocation.GetPositionY(), MiddleRoomLocation.GetPositionZ(), 10.0f, 20.0f);
|
||||
pCyanigosa->CastSpell(pCyanigosa, CYANIGOSA_BLUE_AURA, false);
|
||||
uiCyanigosaEventTimer = 7*IN_MILISECONDS;
|
||||
uiCyanigosaEventTimer = 7*IN_MILLISECONDS;
|
||||
++uiCyanigosaEventPhase;
|
||||
break;
|
||||
case 3:
|
||||
@@ -740,7 +740,7 @@ struct instance_violet_hold : public ScriptedInstance
|
||||
pCyanigosa->CastSpell(pCyanigosa, CYANIGOSA_SPELL_TRANSFORM, 0);
|
||||
pCyanigosa->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_OOC_NOT_ATTACKABLE|UNIT_FLAG_NON_ATTACKABLE);
|
||||
pCyanigosa->SetReactState(REACT_AGGRESSIVE);
|
||||
uiCyanigosaEventTimer = 2*IN_MILISECONDS;
|
||||
uiCyanigosaEventTimer = 2*IN_MILLISECONDS;
|
||||
++uiCyanigosaEventPhase;
|
||||
break;
|
||||
case 4:
|
||||
|
||||
@@ -68,7 +68,7 @@ struct instance_sethekk_halls : public ScriptedInstance
|
||||
{
|
||||
case DATA_IKISSDOOREVENT:
|
||||
if (data == DONE)
|
||||
DoUseDoorOrButton(m_uiIkissDoorGUID,DAY*IN_MILISECONDS);
|
||||
DoUseDoorOrButton(m_uiIkissDoorGUID,DAY*IN_MILLISECONDS);
|
||||
break;
|
||||
case TYPE_ANZU_ENCOUNTER:
|
||||
AnzuEncounter = data;
|
||||
|
||||
+2
-2
@@ -59,12 +59,12 @@ struct instance_ramparts : public ScriptedInstance
|
||||
{
|
||||
case TYPE_VAZRUDEN:
|
||||
if (uiData == DONE && m_auiEncounter[1] == DONE)
|
||||
DoRespawnGameObject(instance->IsHeroic() ? m_uiChestHGUID : m_uiChestNGUID, HOUR*IN_MILISECONDS);
|
||||
DoRespawnGameObject(instance->IsHeroic() ? m_uiChestHGUID : m_uiChestNGUID, HOUR*IN_MILLISECONDS);
|
||||
m_auiEncounter[0] = uiData;
|
||||
break;
|
||||
case TYPE_NAZAN:
|
||||
if (uiData == DONE && m_auiEncounter[0] == DONE)
|
||||
DoRespawnGameObject(instance->IsHeroic() ? m_uiChestHGUID : m_uiChestNGUID, HOUR*IN_MILISECONDS);
|
||||
DoRespawnGameObject(instance->IsHeroic() ? m_uiChestHGUID : m_uiChestNGUID, HOUR*IN_MILLISECONDS);
|
||||
m_auiEncounter[1] = uiData;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -1850,7 +1850,7 @@ struct npc_ebon_gargoyleAI : CasterAI
|
||||
me->GetMotionMaster()->MovePoint(0, x, y, z);
|
||||
|
||||
// Despawn as soon as possible
|
||||
despawnTimer = 4 * IN_MILISECONDS;
|
||||
despawnTimer = 4 * IN_MILLISECONDS;
|
||||
}
|
||||
|
||||
void UpdateAI(const uint32 diff)
|
||||
|
||||
@@ -168,7 +168,7 @@ enum TimeConstants
|
||||
WEEK = DAY*7,
|
||||
MONTH = DAY*30,
|
||||
YEAR = MONTH*12,
|
||||
IN_MILISECONDS = 1000
|
||||
IN_MILLISECONDS = 1000
|
||||
};
|
||||
|
||||
enum AccountTypes
|
||||
|
||||
Reference in New Issue
Block a user