mirror of
https://github.com/mangosfour/server.git
synced 2025-12-12 10:37:03 +00:00
[9641] Fix typo; IN_MILISECONDS -> IN_MILLISECONDS.
This commit is contained in:
parent
e499150b59
commit
34e56c9978
25 changed files with 96 additions and 96 deletions
|
|
@ -653,7 +653,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;
|
||||
|
|
|
|||
|
|
@ -373,16 +373,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;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@
|
|||
|
||||
class BattleGround;
|
||||
|
||||
#define BG_EY_FLAG_RESPAWN_TIME (10*IN_MILISECONDS) //10 seconds
|
||||
#define BG_EY_FPOINTS_TICK_TIME (2*IN_MILISECONDS) //2 seconds
|
||||
#define BG_EY_FLAG_RESPAWN_TIME (10*IN_MILLISECONDS) //10 seconds
|
||||
#define BG_EY_FPOINTS_TICK_TIME (2*IN_MILLISECONDS) //2 seconds
|
||||
|
||||
enum BG_EY_WorldStates
|
||||
{
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@
|
|||
#include "BattleGround.h"
|
||||
|
||||
#define BG_WS_MAX_TEAM_SCORE 3
|
||||
#define BG_WS_FLAG_RESPAWN_TIME (23*IN_MILISECONDS)
|
||||
#define BG_WS_FLAG_DROP_TIME (10*IN_MILISECONDS)
|
||||
#define BG_WS_FLAG_RESPAWN_TIME (23*IN_MILLISECONDS)
|
||||
#define BG_WS_FLAG_DROP_TIME (10*IN_MILLISECONDS)
|
||||
|
||||
enum BG_WS_Sound
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1252,7 +1252,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_BOOL_SAVE_RESPAWN_TIME_IMMEDIATLY) || isWorldBoss())
|
||||
|
|
@ -1656,7 +1656,7 @@ void Creature::SaveRespawnTime()
|
|||
if(m_respawnTime > time(NULL)) // dead (no corpse)
|
||||
sObjectMgr.SaveCreatureRespawnTime(m_DBTableGuid, GetInstanceId(), m_respawnTime);
|
||||
else if(m_deathTimer > 0) // dead (corpse)
|
||||
sObjectMgr.SaveCreatureRespawnTime(m_DBTableGuid, GetInstanceId(), time(NULL) + m_respawnDelay + m_deathTimer / IN_MILISECONDS);
|
||||
sObjectMgr.SaveCreatureRespawnTime(m_DBTableGuid, GetInstanceId(), time(NULL) + m_respawnDelay + m_deathTimer / IN_MILLISECONDS);
|
||||
}
|
||||
|
||||
bool Creature::IsOutOfThreatArea(Unit* pVictim) const
|
||||
|
|
@ -1837,7 +1837,7 @@ void Creature::AddCreatureSpellCooldown(uint32 spellid)
|
|||
|
||||
uint32 cooldown = GetSpellRecoveryTime(spellInfo);
|
||||
if(cooldown)
|
||||
_AddCreatureSpellCooldown(spellid, time(NULL) + cooldown/IN_MILISECONDS);
|
||||
_AddCreatureSpellCooldown(spellid, time(NULL) + cooldown/IN_MILLISECONDS);
|
||||
|
||||
if(spellInfo->Category)
|
||||
_AddCreatureCategoryCooldown(spellInfo->Category, time(NULL));
|
||||
|
|
@ -1856,7 +1856,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
|
||||
|
|
@ -1885,7 +1885,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;
|
||||
}
|
||||
|
|
@ -1928,7 +1928,7 @@ void Creature::AllLootRemovedFromCorpse()
|
|||
|
||||
// corpse was not skinnable -> apply corpse looted timer
|
||||
if (!cinfo || !cinfo->SkinLootId)
|
||||
nDeathTimer = (uint32)((m_corpseDelay * IN_MILISECONDS) * sWorld.getConfig(CONFIG_FLOAT_RATE_CORPSE_DECAY_LOOTED));
|
||||
nDeathTimer = (uint32)((m_corpseDelay * IN_MILLISECONDS) * sWorld.getConfig(CONFIG_FLOAT_RATE_CORPSE_DECAY_LOOTED));
|
||||
// corpse skinnable, but without skinning flag, and then skinned, corpse will despawn next update
|
||||
else
|
||||
nDeathTimer = 0;
|
||||
|
|
|
|||
|
|
@ -462,7 +462,7 @@ uint32 GameEventMgr::Update() // return the next e
|
|||
nextEventDelay = calcDelay;
|
||||
}
|
||||
sLog.outBasic("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)
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ struct GameObjectInfo
|
|||
{
|
||||
uint32 startOpen; //0 used client side to determine GO_ACTIVATED means open/closed
|
||||
uint32 lockId; //1 -> Lock.dbc
|
||||
uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / IN_MILISECONDS (previous was 0x10000)
|
||||
uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / IN_MILLISECONDS (previous was 0x10000)
|
||||
uint32 noDamageImmune; //3 break opening whenever you recieve damage?
|
||||
uint32 openTextID; //4 can be used to replace castBarCaption?
|
||||
uint32 closeTextID; //5
|
||||
|
|
@ -64,7 +64,7 @@ struct GameObjectInfo
|
|||
{
|
||||
uint32 startOpen; //0
|
||||
uint32 lockId; //1 -> Lock.dbc
|
||||
uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / IN_MILISECONDS (previous was 0x10000)
|
||||
uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / IN_MILLISECONDS (previous was 0x10000)
|
||||
uint32 linkedTrapId; //3
|
||||
uint32 noDamageImmune; //4 isBattlegroundObject
|
||||
uint32 large; //5
|
||||
|
|
@ -127,7 +127,7 @@ struct GameObjectInfo
|
|||
uint32 spellId; //3
|
||||
uint32 charges; //4 need respawn (if > 0)
|
||||
uint32 cooldown; //5 time in secs
|
||||
uint32 autoCloseTime; //6 secs till autoclose = autoCloseTime / IN_MILISECONDS (previous was 0x10000)
|
||||
uint32 autoCloseTime; //6 secs till autoclose = autoCloseTime / IN_MILLISECONDS (previous was 0x10000)
|
||||
uint32 startDelay; //7
|
||||
uint32 serverOnly; //8
|
||||
uint32 stealthed; //9
|
||||
|
|
@ -170,7 +170,7 @@ struct GameObjectInfo
|
|||
uint32 lockId; //0 -> Lock.dbc
|
||||
uint32 questId; //1
|
||||
uint32 eventId; //2
|
||||
uint32 autoCloseTime; //3 secs till autoclose = autoCloseTime / IN_MILISECONDS (previous was 0x10000)
|
||||
uint32 autoCloseTime; //3 secs till autoclose = autoCloseTime / IN_MILLISECONDS (previous was 0x10000)
|
||||
uint32 customAnim; //4
|
||||
uint32 consumable; //5
|
||||
uint32 cooldown; //6
|
||||
|
|
@ -194,7 +194,7 @@ struct GameObjectInfo
|
|||
{
|
||||
uint32 pause; //0
|
||||
uint32 startOpen; //1
|
||||
uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / IN_MILISECONDS (previous was 0x10000)
|
||||
uint32 autoCloseTime; //2 secs till autoclose = autoCloseTime / IN_MILLISECONDS (previous was 0x10000)
|
||||
uint32 pause1EventID; //3
|
||||
uint32 pause2EventID; //4
|
||||
} transport;
|
||||
|
|
@ -206,7 +206,7 @@ struct GameObjectInfo
|
|||
uint32 damageMin; //2
|
||||
uint32 damageMax; //3
|
||||
uint32 damageSchool; //4
|
||||
uint32 autoCloseTime; //5 secs till autoclose = autoCloseTime / IN_MILISECONDS (previous was 0x10000)
|
||||
uint32 autoCloseTime; //5 secs till autoclose = autoCloseTime / IN_MILLISECONDS (previous was 0x10000)
|
||||
uint32 openTextID; //6
|
||||
uint32 closeTextID; //7
|
||||
} areadamage;
|
||||
|
|
@ -478,7 +478,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
|
||||
|
|
|
|||
|
|
@ -39,7 +39,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 MAX_NUMBER_OF_CELLS 8
|
||||
|
|
|
|||
|
|
@ -143,7 +143,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_UINT32_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;
|
||||
|
|
|
|||
|
|
@ -179,7 +179,7 @@ void WorldSession::HandleMoveTeleportAck(WorldPacket& recv_data)
|
|||
uint32 flags, time;
|
||||
recv_data >> flags >> time;
|
||||
DEBUG_LOG("Guid: %s", guid.GetString().c_str());
|
||||
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;
|
||||
|
|
|
|||
|
|
@ -1054,7 +1054,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);
|
||||
|
||||
|
|
@ -1175,10 +1175,10 @@ void Pet::_LoadAuras(uint32 timediff)
|
|||
// negative effects should continue counting down after logout
|
||||
if (remaintime != -1 && !IsPositiveEffect(spellid, effindex))
|
||||
{
|
||||
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
|
||||
|
|
|
|||
|
|
@ -320,7 +320,7 @@ void PetAI::UpdateAllies()
|
|||
Unit* owner = m_creature->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;
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@
|
|||
|
||||
#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)
|
||||
|
|
@ -406,7 +406,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 (int j=0; j < PLAYER_MAX_BATTLEGROUND_QUEUES; ++j)
|
||||
{
|
||||
|
|
@ -898,13 +898,13 @@ int32 Player::getMaxTimer(MirrorTimerType timer)
|
|||
case FATIGUE_TIMER:
|
||||
if (GetSession()->GetSecurity() >= (AccountTypes)sWorld.getConfig(CONFIG_UINT32_TIMERBAR_FATIGUE_GMLEVEL))
|
||||
return DISABLED_MIRROR_TIMER;
|
||||
return sWorld.getConfig(CONFIG_UINT32_TIMERBAR_FATIGUE_MAX)*IN_MILISECONDS;
|
||||
return sWorld.getConfig(CONFIG_UINT32_TIMERBAR_FATIGUE_MAX)*IN_MILLISECONDS;
|
||||
case BREATH_TIMER:
|
||||
{
|
||||
if (!isAlive() || HasAuraType(SPELL_AURA_WATER_BREATHING) ||
|
||||
GetSession()->GetSecurity() >= (AccountTypes)sWorld.getConfig(CONFIG_UINT32_TIMERBAR_BREATH_GMLEVEL))
|
||||
return DISABLED_MIRROR_TIMER;
|
||||
int32 UnderWaterTime = sWorld.getConfig(CONFIG_UINT32_TIMERBAR_BREATH_MAX)*IN_MILISECONDS;
|
||||
int32 UnderWaterTime = sWorld.getConfig(CONFIG_UINT32_TIMERBAR_BREATH_MAX)*IN_MILLISECONDS;
|
||||
AuraList const& mModWaterBreathing = GetAurasByType(SPELL_AURA_MOD_WATER_BREATHING);
|
||||
for(AuraList::const_iterator i = mModWaterBreathing.begin(); i != mModWaterBreathing.end(); ++i)
|
||||
UnderWaterTime = uint32(UnderWaterTime * (100.0f + (*i)->GetModifier()->m_amount) / 100.0f);
|
||||
|
|
@ -914,7 +914,7 @@ int32 Player::getMaxTimer(MirrorTimerType timer)
|
|||
{
|
||||
if (!isAlive() || GetSession()->GetSecurity() >= (AccountTypes)sWorld.getConfig(CONFIG_UINT32_TIMERBAR_FIRE_GMLEVEL))
|
||||
return DISABLED_MIRROR_TIMER;
|
||||
return sWorld.getConfig(CONFIG_UINT32_TIMERBAR_FIRE_MAX)*IN_MILISECONDS;
|
||||
return sWorld.getConfig(CONFIG_UINT32_TIMERBAR_FIRE_MAX)*IN_MILLISECONDS;
|
||||
}
|
||||
default:
|
||||
return 0;
|
||||
|
|
@ -949,7 +949,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);
|
||||
|
|
@ -985,7 +985,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);
|
||||
|
|
@ -1018,7 +1018,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);
|
||||
|
|
@ -1347,7 +1347,7 @@ void Player::Update( uint32 p_time )
|
|||
{
|
||||
m_drunkTimer += p_time;
|
||||
|
||||
if (m_drunkTimer > 10*IN_MILISECONDS)
|
||||
if (m_drunkTimer > 10*IN_MILLISECONDS)
|
||||
HandleSobering();
|
||||
}
|
||||
|
||||
|
|
@ -2763,7 +2763,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...
|
||||
{
|
||||
|
|
@ -3462,8 +3462,8 @@ void Player::RemoveArenaSpellCooldowns()
|
|||
SpellEntry const * entry = sSpellStore.LookupEntry(itr->first);
|
||||
// check if spellentry is present and if the cooldown is less than 15 mins
|
||||
if( entry &&
|
||||
entry->RecoveryTime <= 15 * MINUTE * IN_MILISECONDS &&
|
||||
entry->CategoryRecoveryTime <= 15 * MINUTE * IN_MILISECONDS )
|
||||
entry->RecoveryTime <= 15 * MINUTE * IN_MILLISECONDS &&
|
||||
entry->CategoryRecoveryTime <= 15 * MINUTE * IN_MILLISECONDS )
|
||||
{
|
||||
// remove & notify
|
||||
RemoveSpellCooldown(itr->first, true);
|
||||
|
|
@ -4262,7 +4262,7 @@ void Player::ResurrectPlayer(float restore_percent, bool applySickness)
|
|||
{
|
||||
if(Aura* Aur = GetAura(SPELL_ID_PASSIVE_RESURRECTION_SICKNESS,SpellEffectIndex(i)))
|
||||
{
|
||||
Aur->SetAuraDuration(delta*IN_MILISECONDS);
|
||||
Aur->SetAuraDuration(delta*IN_MILLISECONDS);
|
||||
Aur->SendAuraUpdate(false);
|
||||
}
|
||||
}
|
||||
|
|
@ -4283,7 +4283,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
|
||||
|
||||
|
|
@ -13183,10 +13183,10 @@ void Player::AddQuest( Quest const *pQuest, Object *questGiver )
|
|||
|
||||
// shared timed quest
|
||||
if(questGiver && questGiver->GetTypeId()==TYPEID_PLAYER)
|
||||
limittime = ((Player*)questGiver)->getQuestStatusMap()[quest_id].m_timer / IN_MILISECONDS;
|
||||
limittime = ((Player*)questGiver)->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
|
||||
|
|
@ -15343,10 +15343,10 @@ void Player::_LoadAuras(QueryResult *result, uint32 timediff)
|
|||
// negative effects should continue counting down after logout
|
||||
if (remaintime != -1 && !IsPositiveEffect(spellid, effindex))
|
||||
{
|
||||
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
|
||||
|
|
@ -15756,7 +15756,7 @@ void Player::_LoadQuestStatus(QueryResult *result)
|
|||
if (quest_time <= sWorld.GetGameTime())
|
||||
questStatusData.m_timer = 1;
|
||||
else
|
||||
questStatusData.m_timer = uint32(quest_time - sWorld.GetGameTime()) * IN_MILISECONDS;
|
||||
questStatusData.m_timer = uint32(quest_time - sWorld.GetGameTime()) * IN_MILLISECONDS;
|
||||
}
|
||||
else
|
||||
quest_time = 0;
|
||||
|
|
@ -16647,11 +16647,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;
|
||||
|
|
@ -17232,7 +17232,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?
|
||||
|
|
@ -17242,7 +17242,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?
|
||||
|
|
@ -17889,7 +17889,7 @@ void Player::ProhibitSpellSchool(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);
|
||||
|
|
@ -18315,8 +18315,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
|
||||
|
|
@ -20009,7 +20009,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 );
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -333,7 +333,7 @@ struct Areas
|
|||
};
|
||||
|
||||
#define MAX_RUNES 6
|
||||
#define RUNE_COOLDOWN (2*5*IN_MILISECONDS) // msec
|
||||
#define RUNE_COOLDOWN (2*5*IN_MILLISECONDS) // msec
|
||||
|
||||
enum RuneType
|
||||
{
|
||||
|
|
@ -2080,7 +2080,7 @@ class MANGOS_DLL_SPEC Player : public Unit
|
|||
/*** 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; }
|
||||
|
|
@ -2574,7 +2574,7 @@ template <class T> T Player::ApplySpellMod(uint32 spellId, SpellModOp op, T &bas
|
|||
continue;
|
||||
|
||||
// special case (skip >10sec spell casts for instant cast setting)
|
||||
if( mod->op==SPELLMOD_CASTING_TIME && basevalue >= T(10*IN_MILISECONDS) && mod->value <= -100)
|
||||
if( mod->op==SPELLMOD_CASTING_TIME && basevalue >= T(10*IN_MILLISECONDS) && mod->value <= -100)
|
||||
continue;
|
||||
|
||||
totalpct += mod->value;
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@
|
|||
#include "BattleGround.h"
|
||||
#include "Util.h"
|
||||
|
||||
#define SPELL_CHANNEL_UPDATE_INTERVAL (1 * IN_MILISECONDS)
|
||||
#define SPELL_CHANNEL_UPDATE_INTERVAL (1 * IN_MILLISECONDS)
|
||||
|
||||
extern pEffect SpellEffects[TOTAL_SPELL_EFFECTS];
|
||||
|
||||
|
|
|
|||
|
|
@ -233,7 +233,7 @@ enum SpellTargets
|
|||
SPELL_TARGETS_AOE_DAMAGE
|
||||
};
|
||||
|
||||
#define SPELL_SPELL_CHANNEL_UPDATE_INTERVAL (1*IN_MILISECONDS)
|
||||
#define SPELL_SPELL_CHANNEL_UPDATE_INTERVAL (1*IN_MILLISECONDS)
|
||||
|
||||
typedef std::multimap<uint64, uint64> SpellTargetTimeMap;
|
||||
|
||||
|
|
|
|||
|
|
@ -615,7 +615,7 @@ void Aura::Update(uint32 diff)
|
|||
{
|
||||
Powers powertype = Powers(m_spellProto->powerType);
|
||||
int32 manaPerSecond = m_spellProto->manaPerSecond + m_spellProto->manaPerSecondPerLevel * caster->getLevel();
|
||||
m_timeCla = 1*IN_MILISECONDS;
|
||||
m_timeCla = 1*IN_MILLISECONDS;
|
||||
if (manaPerSecond)
|
||||
{
|
||||
if(powertype==POWER_HEALTH)
|
||||
|
|
@ -2293,7 +2293,7 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
|
|||
case 7057: // Haunting Spirits
|
||||
// expected to tick with 30 sec period (tick part see in Aura::PeriodicTick)
|
||||
m_isPeriodic = true;
|
||||
m_modifier.periodictime = 30*IN_MILISECONDS;
|
||||
m_modifier.periodictime = 30*IN_MILLISECONDS;
|
||||
m_periodicTimer = m_modifier.periodictime;
|
||||
return;
|
||||
case 13139: // net-o-matic
|
||||
|
|
@ -3403,7 +3403,7 @@ void Aura::HandleAuraTransform(bool apply, bool Real)
|
|||
// 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()) )
|
||||
((Player*)m_target)->setRegenTimer(1*IN_MILISECONDS);
|
||||
((Player*)m_target)->setRegenTimer(1*IN_MILLISECONDS);
|
||||
|
||||
//dismount polymorphed target (after patch 2.4.2)
|
||||
if (m_target->IsMounted())
|
||||
|
|
@ -3925,7 +3925,7 @@ void Aura::HandleAuraModStun(bool apply, bool Real)
|
|||
if(pObj->Create(sObjectMgr.GenerateLowGuid(HIGHGUID_GAMEOBJECT), 185584, m_target->GetMap(), m_target->GetPhaseMask(),
|
||||
m_target->GetPositionX(), m_target->GetPositionY(), m_target->GetPositionZ(), m_target->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 100, GO_STATE_READY))
|
||||
{
|
||||
pObj->SetRespawnTime(GetAuraDuration()/IN_MILISECONDS);
|
||||
pObj->SetRespawnTime(GetAuraDuration()/IN_MILLISECONDS);
|
||||
pObj->SetSpellId(GetId());
|
||||
m_target->AddGameObject(pObj);
|
||||
m_target->GetMap()->Add(pObj);
|
||||
|
|
|
|||
|
|
@ -735,7 +735,7 @@ void Spell::EffectSchoolDMG(SpellEffectIndex 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(m_spellInfo, EFFECT_INDEX_2, m_spellInfo->EffectBasePoints[EFFECT_INDEX_2], unitTarget);
|
||||
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 & UI64LIT(0x0010000000000000))
|
||||
|
|
@ -4095,7 +4095,7 @@ void Spell::EffectDistract(SpellEffectIndex /*eff_idx*/)
|
|||
// 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);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -5261,7 +5261,7 @@ void Spell::EffectSummonObjectWild(SpellEffectIndex eff_idx)
|
|||
|
||||
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
|
||||
|
|
@ -6212,7 +6212,7 @@ void Spell::EffectDuel(SpellEffectIndex eff_idx)
|
|||
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);
|
||||
|
|
@ -6289,7 +6289,7 @@ void Spell::EffectSummonPlayer(SpellEffectIndex /*eff_idx*/)
|
|||
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
|
||||
((Player*)unitTarget)->GetSession()->SendPacket(&data);
|
||||
}
|
||||
|
||||
|
|
@ -6455,7 +6455,7 @@ void Spell::EffectEnchantHeldItem(SpellEffectIndex eff_idx)
|
|||
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);
|
||||
}
|
||||
}
|
||||
|
|
@ -6579,7 +6579,7 @@ void Spell::EffectSummonObject(SpellEffectIndex eff_idx)
|
|||
|
||||
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);
|
||||
|
||||
|
|
@ -7169,7 +7169,7 @@ void Spell::EffectTransmitted(SpellEffectIndex eff_idx)
|
|||
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:
|
||||
|
|
@ -7187,7 +7187,7 @@ void Spell::EffectTransmitted(SpellEffectIndex eff_idx)
|
|||
break;
|
||||
}
|
||||
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
|
||||
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
|
||||
|
||||
pGameObj->SetOwnerGUID(m_caster->GetGUID());
|
||||
|
||||
|
|
|
|||
|
|
@ -2994,7 +2994,7 @@ SpellCastResult SpellMgr::GetSpellAllowedInLocationError(SpellEntry const *spell
|
|||
// - with SPELL_ATTR_EX4_NOT_USABLE_IN_ARENA flag
|
||||
// - with greater than 15 min CD
|
||||
if ((spellInfo->AttributesEx4 & SPELL_ATTR_EX4_NOT_USABLE_IN_ARENA) ||
|
||||
(GetSpellRecoveryTime(spellInfo) > 15 * MINUTE * IN_MILISECONDS && !(spellInfo->AttributesEx4 & SPELL_ATTR_EX4_USABLE_IN_ARENA)))
|
||||
(GetSpellRecoveryTime(spellInfo) > 15 * MINUTE * IN_MILLISECONDS && !(spellInfo->AttributesEx4 & SPELL_ATTR_EX4_USABLE_IN_ARENA)))
|
||||
if (player && player->InArena())
|
||||
return SPELL_FAILED_NOT_IN_ARENA;
|
||||
|
||||
|
|
|
|||
|
|
@ -33,7 +33,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
|
||||
|
|
|
|||
|
|
@ -4229,7 +4229,7 @@ void Unit::RemoveAurasDueToSpellBySteal(uint32 spellId, uint64 casterGUID, Unit
|
|||
// set its duration and maximum duration
|
||||
// max duration 2 minutes (in msecs)
|
||||
int32 dur = aur->GetAuraDuration();
|
||||
int32 max_dur = 2*MINUTE*IN_MILISECONDS;
|
||||
int32 max_dur = 2*MINUTE*IN_MILLISECONDS;
|
||||
int32 new_max_dur = max_dur > dur ? dur : max_dur;
|
||||
new_aur->SetAuraMaxDuration( new_max_dur );
|
||||
new_aur->SetAuraDuration( new_max_dur );
|
||||
|
|
|
|||
|
|
@ -35,7 +35,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
|
||||
|
|
|
|||
|
|
@ -517,9 +517,9 @@ void World::LoadConfigSettings(bool reload)
|
|||
setConfigMinMax(CONFIG_UINT32_COMPRESSION, "Compression", 1, 1, 9);
|
||||
setConfig(CONFIG_BOOL_ADDON_CHANNEL, "AddonChannel", true);
|
||||
setConfig(CONFIG_BOOL_GRID_UNLOAD, "GridUnload", true);
|
||||
setConfigPos(CONFIG_UINT32_INTERVAL_SAVE, "PlayerSaveInterval", 15 * MINUTE * IN_MILISECONDS);
|
||||
setConfigPos(CONFIG_UINT32_INTERVAL_SAVE, "PlayerSaveInterval", 15 * MINUTE * IN_MILLISECONDS);
|
||||
|
||||
setConfigMin(CONFIG_UINT32_INTERVAL_GRIDCLEAN, "GridCleanUpDelay", 5 * MINUTE * IN_MILISECONDS, MIN_GRID_DELAY);
|
||||
setConfigMin(CONFIG_UINT32_INTERVAL_GRIDCLEAN, "GridCleanUpDelay", 5 * MINUTE * IN_MILLISECONDS, MIN_GRID_DELAY);
|
||||
if (reload)
|
||||
sMapMgr.SetGridCleanUpDelay(getConfig(CONFIG_UINT32_INTERVAL_GRIDCLEAN));
|
||||
|
||||
|
|
@ -527,7 +527,7 @@ void World::LoadConfigSettings(bool reload)
|
|||
if (reload)
|
||||
sMapMgr.SetMapUpdateInterval(getConfig(CONFIG_UINT32_INTERVAL_MAPUPDATE));
|
||||
|
||||
setConfig(CONFIG_UINT32_INTERVAL_CHANGEWEATHER, "ChangeWeatherInterval", 10 * MINUTE * IN_MILISECONDS);
|
||||
setConfig(CONFIG_UINT32_INTERVAL_CHANGEWEATHER, "ChangeWeatherInterval", 10 * MINUTE * IN_MILLISECONDS);
|
||||
|
||||
if (configNoReload(reload, CONFIG_UINT32_PORT_WORLD, "WorldServerPort", DEFAULT_WORLDSERVER_PORT))
|
||||
setConfig(CONFIG_UINT32_PORT_WORLD, "WorldServerPort", DEFAULT_WORLDSERVER_PORT);
|
||||
|
|
@ -596,7 +596,7 @@ void World::LoadConfigSettings(bool reload)
|
|||
setConfig(CONFIG_BOOL_CAST_UNSTUCK, "CastUnstuck", true);
|
||||
setConfig(CONFIG_UINT32_MAX_SPELL_CASTS_IN_CHAIN, "MaxSpellCastsInChain", 10);
|
||||
setConfig(CONFIG_UINT32_INSTANCE_RESET_TIME_HOUR, "Instance.ResetTimeHour", 4);
|
||||
setConfig(CONFIG_UINT32_INSTANCE_UNLOAD_DELAY, "Instance.UnloadDelay", 30 * MINUTE * IN_MILISECONDS);
|
||||
setConfig(CONFIG_UINT32_INSTANCE_UNLOAD_DELAY, "Instance.UnloadDelay", 30 * MINUTE * IN_MILLISECONDS);
|
||||
|
||||
setConfig(CONFIG_UINT32_MAX_PRIMARY_TRADE_SKILL, "MaxPrimaryTradeSkill", 2);
|
||||
setConfigMinMax(CONFIG_UINT32_MIN_PETITION_SIGNS, "MinPetitionSigns", 9, 0, 9);
|
||||
|
|
@ -622,7 +622,7 @@ void World::LoadConfigSettings(bool reload)
|
|||
setConfigPos(CONFIG_UINT32_UPTIME_UPDATE, "UpdateUptimeInterval", 10);
|
||||
if (reload)
|
||||
{
|
||||
m_timers[WUPDATE_UPTIME].SetInterval(getConfig(CONFIG_UINT32_UPTIME_UPDATE)*MINUTE*IN_MILISECONDS);
|
||||
m_timers[WUPDATE_UPTIME].SetInterval(getConfig(CONFIG_UINT32_UPTIME_UPDATE)*MINUTE*IN_MILLISECONDS);
|
||||
m_timers[WUPDATE_UPTIME].Reset();
|
||||
}
|
||||
|
||||
|
|
@ -712,10 +712,10 @@ void World::LoadConfigSettings(bool reload)
|
|||
setConfigMinMax(CONFIG_UINT32_BATTLEGROUND_QUEUE_ANNOUNCER_JOIN, "Battleground.QueueAnnouncer.Join", 0, 0, 2);
|
||||
setConfig(CONFIG_BOOL_BATTLEGROUND_QUEUE_ANNOUNCER_START, "Battleground.QueueAnnouncer.Start", false);
|
||||
setConfig(CONFIG_UINT32_BATTLEGROUND_INVITATION_TYPE, "Battleground.InvitationType", 0);
|
||||
setConfig(CONFIG_UINT32_BATTLEGROUND_PREMATURE_FINISH_TIMER, "BattleGround.PrematureFinishTimer", 5 * MINUTE * IN_MILISECONDS);
|
||||
setConfig(CONFIG_UINT32_BATTLEGROUND_PREMADE_GROUP_WAIT_FOR_MATCH, "BattleGround.PremadeGroupWaitForMatch", 30 * MINUTE * IN_MILISECONDS);
|
||||
setConfig(CONFIG_UINT32_BATTLEGROUND_PREMATURE_FINISH_TIMER, "BattleGround.PrematureFinishTimer", 5 * MINUTE * IN_MILLISECONDS);
|
||||
setConfig(CONFIG_UINT32_BATTLEGROUND_PREMADE_GROUP_WAIT_FOR_MATCH, "BattleGround.PremadeGroupWaitForMatch", 30 * MINUTE * IN_MILLISECONDS);
|
||||
setConfig(CONFIG_UINT32_ARENA_MAX_RATING_DIFFERENCE, "Arena.MaxRatingDifference", 150);
|
||||
setConfig(CONFIG_UINT32_ARENA_RATING_DISCARD_TIMER, "Arena.RatingDiscardTimer", 10 * MINUTE * IN_MILISECONDS);
|
||||
setConfig(CONFIG_UINT32_ARENA_RATING_DISCARD_TIMER, "Arena.RatingDiscardTimer", 10 * MINUTE * IN_MILLISECONDS);
|
||||
setConfig(CONFIG_BOOL_ARENA_AUTO_DISTRIBUTE_POINTS, "Arena.AutoDistributePoints", false);
|
||||
setConfig(CONFIG_UINT32_ARENA_AUTO_DISTRIBUTE_INTERVAL_DAYS, "Arena.AutoDistributeInterval", 7);
|
||||
setConfig(CONFIG_BOOL_ARENA_QUEUE_ANNOUNCER_JOIN, "Arena.QueueAnnouncer.Join", false);
|
||||
|
|
@ -1229,19 +1229,19 @@ void World::SetInitialWorldSettings()
|
|||
|
||||
m_timers[WUPDATE_OBJECTS].SetInterval(0);
|
||||
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_configUint32Values[CONFIG_UINT32_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_configUint32Values[CONFIG_UINT32_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
|
||||
|
||||
//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 = uint32((((localtime( &m_gameTime )->tm_hour + 20) % 24)* HOUR * IN_MILISECONDS) / m_timers[WUPDATE_AUCTIONS].GetInterval() );
|
||||
mail_timer = uint32((((localtime( &m_gameTime )->tm_hour + 20) % 24)* HOUR * IN_MILLISECONDS) / m_timers[WUPDATE_AUCTIONS].GetInterval() );
|
||||
//1440
|
||||
mail_timer_expires = uint32( (DAY * IN_MILISECONDS) / (m_timers[WUPDATE_AUCTIONS].GetInterval()));
|
||||
mail_timer_expires = uint32( (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);
|
||||
|
||||
///- Initialize static helper structures
|
||||
|
|
|
|||
|
|
@ -166,7 +166,7 @@ enum TimeConstants
|
|||
DAY = HOUR*24,
|
||||
MONTH = DAY*30,
|
||||
YEAR = MONTH*12,
|
||||
IN_MILISECONDS = 1000
|
||||
IN_MILLISECONDS = 1000
|
||||
};
|
||||
|
||||
enum AccountTypes
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "9640"
|
||||
#define REVISION_NR "9641"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue