aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Entities
diff options
context:
space:
mode:
authorNefarion <nefarion123@gmail.com>2013-03-08 21:41:30 +0100
committerNefarion <nefarion123@gmail.com>2013-03-08 21:55:37 +0100
commit49fd11ab5aebcbce86ca2ee48711287cf020d798 (patch)
tree8086b6f797c80dbf09edd8f41c1c79912838e3b6 /src/server/game/Entities
parent2dbe3d6cfe2d174b5edf9fdb6720fee21c7009d2 (diff)
First step of comment style refactoring to doxygen-style.
Diffstat (limited to 'src/server/game/Entities')
-rw-r--r--src/server/game/Entities/Creature/Creature.cpp10
-rw-r--r--src/server/game/Entities/Creature/TemporarySummon.cpp2
-rw-r--r--src/server/game/Entities/GameObject/GameObject.cpp14
-rw-r--r--src/server/game/Entities/Object/Object.cpp10
-rw-r--r--src/server/game/Entities/Pet/Pet.cpp4
-rw-r--r--src/server/game/Entities/Player/Player.cpp42
-rw-r--r--src/server/game/Entities/Totem/Totem.cpp2
-rw-r--r--src/server/game/Entities/Unit/Unit.cpp42
-rw-r--r--src/server/game/Entities/Unit/Unit.h6
9 files changed, 66 insertions, 66 deletions
diff --git a/src/server/game/Entities/Creature/Creature.cpp b/src/server/game/Entities/Creature/Creature.cpp
index 1fc13f9f15b..6f88222bbbc 100644
--- a/src/server/game/Entities/Creature/Creature.cpp
+++ b/src/server/game/Entities/Creature/Creature.cpp
@@ -397,7 +397,7 @@ bool Creature::UpdateEntry(uint32 Entry, uint32 team, const CreatureData* data)
SetMeleeDamageSchool(SpellSchools(cInfo->dmgschool));
CreatureBaseStats const* stats = sObjectMgr->GetCreatureBaseStats(getLevel(), cInfo->unit_class);
- float armor = (float)stats->GenerateArmor(cInfo); // TODO: Why is this treated as uint32 when it's a float?
+ float armor = (float)stats->GenerateArmor(cInfo); /// @todo Why is this treated as uint32 when it's a float?
SetModifierValue(UNIT_MOD_ARMOR, BASE_VALUE, armor);
SetModifierValue(UNIT_MOD_RESISTANCE_HOLY, BASE_VALUE, float(cInfo->resistance[SPELL_SCHOOL_HOLY]));
SetModifierValue(UNIT_MOD_RESISTANCE_FIRE, BASE_VALUE, float(cInfo->resistance[SPELL_SCHOOL_FIRE]));
@@ -737,7 +737,7 @@ void Creature::DoFleeToGetAssistance()
if (!creature)
//SetFeared(true, getVictim()->GetGUID(), 0, sWorld->getIntConfig(CONFIG_CREATURE_FAMILY_FLEE_DELAY));
- //TODO: use 31365
+ /// @todo use 31365
SetControlled(true, UNIT_STATE_FLEEING);
else
GetMotionMaster()->MoveSeekAssistance(creature->GetPositionX(), creature->GetPositionY(), creature->GetPositionZ());
@@ -850,7 +850,7 @@ bool Creature::Create(uint32 guidlow, Map* map, uint32 phaseMask, uint32 Entry,
LastUsedScriptID = GetCreatureTemplate()->ScriptID;
- // TODO: Replace with spell, handle from DB
+ /// @todo Replace with spell, handle from DB
if (isSpiritHealer() || isSpiritGuide())
{
m_serverSideVisibility.SetValue(SERVERSIDE_VISIBILITY_GHOST, GHOST_VISIBILITY_GHOST);
@@ -1186,7 +1186,7 @@ void Creature::SelectLevel(const CreatureTemplate* cinfo)
SetMaxPower(POWER_MANA, mana); //MAX Mana
SetPower(POWER_MANA, mana);
- // TODO: set UNIT_FIELD_POWER*, for some creature class case (energy, etc)
+ /// @todo set UNIT_FIELD_POWER*, for some creature class case (energy, etc)
SetModifierValue(UNIT_MOD_HEALTH, BASE_VALUE, (float)health);
SetModifierValue(UNIT_MOD_MANA, BASE_VALUE, (float)mana);
@@ -1484,7 +1484,7 @@ bool Creature::canStartAttack(Unit const* who, bool force) const
if (!CanFly() && (GetDistanceZ(who) > CREATURE_Z_ATTACK_RANGE + m_CombatDistance))
//|| who->IsControlledByPlayer() && who->IsFlying()))
// we cannot check flying for other creatures, too much map/vmap calculation
- // TODO: should switch to range attack
+ /// @todo should switch to range attack
return false;
if (!force)
diff --git a/src/server/game/Entities/Creature/TemporarySummon.cpp b/src/server/game/Entities/Creature/TemporarySummon.cpp
index 2f691f68c99..eb7c0e7da6c 100644
--- a/src/server/game/Entities/Creature/TemporarySummon.cpp
+++ b/src/server/game/Entities/Creature/TemporarySummon.cpp
@@ -372,7 +372,7 @@ void Puppet::Update(uint32 time)
if (!isAlive())
{
UnSummon();
- // TODO: why long distance .die does not remove it
+ /// @todo why long distance .die does not remove it
}
}
}
diff --git a/src/server/game/Entities/GameObject/GameObject.cpp b/src/server/game/Entities/GameObject/GameObject.cpp
index a2c0b4b8c92..db51d88653a 100644
--- a/src/server/game/Entities/GameObject/GameObject.cpp
+++ b/src/server/game/Entities/GameObject/GameObject.cpp
@@ -428,8 +428,8 @@ void GameObject::Update(uint32 diff)
bool IsBattlegroundTrap = false;
//FIXME: this is activation radius (in different casting radius that must be selected from spell data)
- //TODO: move activated state code (cast itself) to GO_ACTIVATED, in this place only check activating and set state
- float radius = (float)(goInfo->trap.radius)/3*2; // TODO rename radius to diameter (goInfo->trap.radius) should be (goInfo->trap.diameter)
+ /// @todo move activated state code (cast itself) to GO_ACTIVATED, in this place only check activating and set state
+ float radius = (float)(goInfo->trap.radius)/3*2; /// @todo rename radius to diameter (goInfo->trap.radius) should be (goInfo->trap.diameter)
if (!radius)
{
if (goInfo->trap.cooldown != 3) // cast in other case (at some triggering/linked go/etc explicit call)
@@ -945,7 +945,7 @@ bool GameObject::ActivateToQuest(Player* target) const
{
if (LootTemplates_Gameobject.HaveQuestLootForPlayer(GetGOInfo()->GetLootId(), target))
{
- //TODO: fix this hack
+ /// @todo fix this hack
//look for battlegroundAV for some objects which are only activated after mine gots captured by own team
if (GetEntry() == BG_AV_OBJECTID_MINE_N || GetEntry() == BG_AV_OBJECTID_MINE_S)
if (Battleground* bg = target->GetBattleground())
@@ -1353,12 +1353,12 @@ void GameObject::Use(Unit* user)
{
player->UpdateFishingSkill();
- //TODO: I do not understand this hack. Need some explanation.
+ /// @todo I do not understand this hack. Need some explanation.
// prevent removing GO at spell cancel
RemoveFromOwner();
SetOwnerGUID(player->GetGUID());
- //TODO: find reasonable value for fishing hole search
+ /// @todo find reasonable value for fishing hole search
GameObject* ok = LookupFishingHoleAround(20.0f + CONTACT_DISTANCE);
if (ok)
{
@@ -1368,7 +1368,7 @@ void GameObject::Use(Unit* user)
else
player->SendLoot(GetGUID(), LOOT_FISHING);
}
- // TODO: else: junk
+ /// @todo else: junk
else
m_respawnTime = time(NULL);
@@ -1831,7 +1831,7 @@ void GameObject::ModifyHealth(int32 change, Unit* attackerOrHealer /*= NULL*/, u
Player* player = attackerOrHealer->GetCharmerOrOwnerPlayerOrPlayerItself();
// dealing damage, send packet
- // TODO: is there any packet for healing?
+ /// @todo is there any packet for healing?
if (change < 0 && player)
{
WorldPacket data(SMSG_DESTRUCTIBLE_BUILDING_DAMAGE, 8 + 8 + 8 + 4 + 4);
diff --git a/src/server/game/Entities/Object/Object.cpp b/src/server/game/Entities/Object/Object.cpp
index 083690baf81..5b6bf87057f 100644
--- a/src/server/game/Entities/Object/Object.cpp
+++ b/src/server/game/Entities/Object/Object.cpp
@@ -457,7 +457,7 @@ void Object::_BuildMovementUpdate(ByteBuffer* data, uint16 flags) const
*data << uint32(GetGUIDLow()); // GetGUIDLow()
break;
//! Unit, Player and default here are sending wrong values.
- //! TODO: Research the proper formula
+ /// @todo Research the proper formula
case TYPEID_UNIT:
*data << uint32(0x0000000B); // unk
break;
@@ -491,7 +491,7 @@ void Object::_BuildMovementUpdate(ByteBuffer* data, uint16 flags) const
// 0x80
if (flags & UPDATEFLAG_VEHICLE)
{
- // TODO: Allow players to aquire this updateflag.
+ /// @todo Allow players to aquire this updateflag.
*data << uint32(((Unit*)this)->GetVehicleKit()->GetVehicleInfo()->m_ID);
*data << float(((Creature*)this)->GetOrientation());
}
@@ -2174,7 +2174,7 @@ namespace Trinity
{
char const* text = sObjectMgr->GetTrinityString(i_textId, loc_idx);
- // TODO: i_object.GetName() also must be localized?
+ /// @todo i_object.GetName() also must be localized?
i_object.BuildMonsterChat(&data, i_msgtype, text, i_language, i_object.GetNameForLocaleIdx(loc_idx), i_targetGUID);
}
@@ -2193,7 +2193,7 @@ namespace Trinity
: i_object(obj), i_msgtype(msgtype), i_text(text), i_language(language), i_targetGUID(targetGUID) {}
void operator()(WorldPacket& data, LocaleConstant loc_idx)
{
- // TODO: i_object.GetName() also must be localized?
+ /// @todo i_object.GetName() also must be localized?
i_object.BuildMonsterChat(&data, i_msgtype, i_text, i_language, i_object.GetNameForLocaleIdx(loc_idx), i_targetGUID);
}
@@ -3119,7 +3119,7 @@ void WorldObject::DestroyForNearbyPlayers()
if (!player->HaveAtClient(this))
continue;
- if (isType(TYPEMASK_UNIT) && ((Unit*)this)->GetCharmerGUID() == player->GetGUID()) // TODO: this is for puppet
+ if (isType(TYPEMASK_UNIT) && ((Unit*)this)->GetCharmerGUID() == player->GetGUID()) /// @todo this is for puppet
continue;
DestroyForPlayer(player);
diff --git a/src/server/game/Entities/Pet/Pet.cpp b/src/server/game/Entities/Pet/Pet.cpp
index e4981ee8483..e10ca7b64c2 100644
--- a/src/server/game/Entities/Pet/Pet.cpp
+++ b/src/server/game/Entities/Pet/Pet.cpp
@@ -286,7 +286,7 @@ bool Pet::LoadPetFromDB(Player* owner, uint32 petentry, uint32 petnumber, bool c
// Send fake summon spell cast - this is needed for correct cooldown application for spells
// Example: 46584 - without this cooldown (which should be set always when pet is loaded) isn't set clientside
- // TODO: pets should be summoned from real cast instead of just faking it?
+ /// @todo pets should be summoned from real cast instead of just faking it?
if (summon_spell_id)
{
WorldPacket data(SMSG_SPELL_GO, (8+8+4+4+2));
@@ -822,7 +822,7 @@ bool Pet::CreateBaseAtTamed(CreatureTemplate const* cinfo, Map* map, uint32 phas
return true;
}
-// TODO: Move stat mods code to pet passive auras
+/// @todo Move stat mods code to pet passive auras
bool Guardian::InitStatsForLevel(uint8 petlevel)
{
CreatureTemplate const* cinfo = GetCreatureTemplate();
diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp
index 7447868d763..e9f1af5595a 100644
--- a/src/server/game/Entities/Player/Player.cpp
+++ b/src/server/game/Entities/Player/Player.cpp
@@ -932,7 +932,7 @@ void Player::CleanupsBeforeDelete(bool finalCleanup)
bool Player::Create(uint32 guidlow, CharacterCreateInfo* createInfo)
{
//FIXME: outfitId not used in player creating
- // TODO: need more checks against packet modifications
+ /// @todo need more checks against packet modifications
// should check that skin, face, hair* are valid via DBC per race/class
// also do it in Player::BuildEnumData, Player::LoadFromDB
@@ -1040,7 +1040,7 @@ bool Player::Create(uint32 guidlow, CharacterCreateInfo* createInfo)
SetFlag(PLAYER_EXPLORED_ZONES_1+i, 0xFFFFFFFF);
}
- //Reputations if "StartAllReputation" is enabled, -- TODO: Fix this in a better way
+ //Reputations if "StartAllReputation" is enabled, -- @todo Fix this in a better way
if (sWorld->getBoolConfig(CONFIG_START_ALL_REP))
{
GetReputationMgr().SetReputation(sFactionStore.LookupEntry(942), 42999);
@@ -1376,7 +1376,7 @@ void Player::HandleDrowning(uint32 time_diff)
{
m_MirrorTimer[BREATH_TIMER]+= 1*IN_MILLISECONDS;
// Calculate and deal damage
- // TODO: Check this formula
+ /// @todo Check this formula
uint32 damage = GetMaxHealth() / 5 + urand(0, getLevel()-1);
EnvironmentalDamage(DAMAGE_DROWNING, damage);
}
@@ -1445,7 +1445,7 @@ void Player::HandleDrowning(uint32 time_diff)
{
m_MirrorTimer[FIRE_TIMER]+= 1*IN_MILLISECONDS;
// Calculate and deal damage
- // TODO: Check this formula
+ /// @todo Check this formula
uint32 damage = urand(600, 700);
if (m_MirrorTimerFlags & UNDERWATER_INLAVA)
EnvironmentalDamage(DAMAGE_LAVA, damage);
@@ -1621,7 +1621,7 @@ void Player::Update(uint32 p_time)
if (Unit* victim = getVictim())
{
// default combat reach 10
- // TODO add weapon, skill check
+ /// @todo add weapon, skill check
if (isAttackReady(BASE_ATTACK))
{
@@ -2506,7 +2506,7 @@ void Player::Regenerate(Powers power)
uint32 curValue = GetPower(power);
- // TODO: possible use of miscvalueb instead of amount
+ /// @todo possible use of miscvalueb instead of amount
if (HasAuraTypeWithValue(SPELL_AURA_PREVENT_REGENERATE_POWER, power))
return;
@@ -2762,7 +2762,7 @@ GameObject* Player::GetGameObjectIfCanInteractWith(uint64 guid, GameobjectTypes
float maxdist;
switch (type)
{
- // TODO: find out how the client calculates the maximal usage distance to spellless working
+ /// @todo find out how the client calculates the maximal usage distance to spellless working
// gameobjects like guildbanks and mailboxes - 10.0 is a just an abitrary choosen number
case GAMEOBJECT_TYPE_GUILD_BANK:
case GAMEOBJECT_TYPE_MAILBOX:
@@ -2801,7 +2801,7 @@ void Player::SetInWater(bool apply)
//move player's guid into HateOfflineList of those mobs
//which can't swim and move guid back into ThreatList when
//on surface.
- //TODO: exist also swimming mobs, and function must be symmetric to enter/leave water
+ /// @todo exist also swimming mobs, and function must be symmetric to enter/leave water
m_isInWater = apply;
// remove auras that need water/land
@@ -2914,7 +2914,7 @@ bool Player::IsInSameRaidWith(Player const* p) const
}
///- If the player is invited, remove him. If the group if then only 1 person, disband the group.
-/// \todo Shouldn't we also check if there is no other invitees before disbanding the group?
+/// @todo Shouldn't we also check if there is no other invitees before disbanding the group?
void Player::UninviteFromGroup()
{
Group* group = GetGroupInvite();
@@ -3103,7 +3103,7 @@ void Player::GiveLevel(uint8 level)
if (MailLevelReward const* mailReward = sObjectMgr->GetMailLevelReward(level, getRaceMask()))
{
- //- TODO: Poor design of mail system
+ /// @todo Poor design of mail system
SQLTransaction trans = CharacterDatabase.BeginTransaction();
MailDraft(mailReward->mailTemplateId).SendMailTo(trans, this, MailSender(MAIL_CREATURE, mailReward->senderEntry));
CharacterDatabase.CommitTransaction(trans);
@@ -5824,7 +5824,7 @@ void Player::GetDodgeFromAgility(float &diminishing, float &nondiminishing)
if (dodgeRatio == NULL || pclass > MAX_CLASSES)
return;
- // TODO: research if talents/effects that increase total agility by x% should increase non-diminishing part
+ /// @todo research if talents/effects that increase total agility by x% should increase non-diminishing part
float base_agility = GetCreateStat(STAT_AGILITY) * m_auraModifiersGroup[UNIT_MOD_STAT_START + STAT_AGILITY][BASE_PCT];
float bonus_agility = GetStat(STAT_AGILITY) - base_agility;
@@ -8769,7 +8769,7 @@ void Player::SendLoot(uint64 guid, LootType loot_type)
{
uint32 lootid = go->GetGOInfo()->GetLootId();
- //TODO: fix this big hack
+ /// @todo fix this big hack
if ((go->GetEntry() == BG_AV_OBJECTID_MINE_N || go->GetEntry() == BG_AV_OBJECTID_MINE_S))
if (Battleground* bg = GetBattleground())
if (bg->GetTypeID(true) == BATTLEGROUND_AV)
@@ -11902,7 +11902,7 @@ InventoryResult Player::CanUseItem(Item* pItem, bool not_loading) const
// Armor that is binded to account can "morph" from plate to mail, etc. if skill is not learned yet.
if (pProto->Quality == ITEM_QUALITY_HEIRLOOM && pProto->Class == ITEM_CLASS_ARMOR && !HasSkill(itemSkill))
{
- // TODO: when you right-click already equipped item it throws EQUIP_ERR_NO_REQUIRED_PROFICIENCY.
+ /// @todo when you right-click already equipped item it throws EQUIP_ERR_NO_REQUIRED_PROFICIENCY.
// In fact it's a visual bug, everything works properly... I need sniffs of operations with
// binded to account items from off server.
@@ -13692,7 +13692,7 @@ void Player::AddTradeableItem(Item* item)
m_itemSoulboundTradeable.push_back(item);
}
-//TODO: should never allow an item to be added to m_itemSoulboundTradeable twice
+/// @todo should never allow an item to be added to m_itemSoulboundTradeable twice
void Player::RemoveTradeableItem(Item* item)
{
m_itemSoulboundTradeable.remove(item);
@@ -14747,7 +14747,7 @@ void Player::SendPreparedQuest(uint64 guid)
else if (icon == 4)
PlayerTalkClass->SendQuestGiverRequestItems(quest, guid, CanRewardQuest(quest, false), true);
// Send completable on repeatable and autoCompletable quest if player don't have quest
- // TODO: verify if check for !quest->IsDaily() is really correct (possibly not)
+ /// @todo verify if check for !quest->IsDaily() is really correct (possibly not)
else
{
Object* object = ObjectAccessor::GetObjectByTypeMask(*this, guid, TYPEMASK_UNIT | TYPEMASK_GAMEOBJECT | TYPEMASK_ITEM);
@@ -15284,7 +15284,7 @@ void Player::RewardQuest(Quest const* quest, uint32 reward, Object* questGiver,
// Send reward mail
if (uint32 mail_template_id = quest->GetRewMailTemplateId())
{
- //- TODO: Poor design of mail system
+ /// @todo Poor design of mail system
SQLTransaction trans = CharacterDatabase.BeginTransaction();
MailDraft(mail_template_id).SendMailTo(trans, this, questGiver, MAIL_CHECK_MASK_HAS_BODY, quest->GetRewMailDelaySecs());
CharacterDatabase.CommitTransaction(trans);
@@ -17750,7 +17750,7 @@ void Player::_LoadInventory(PreparedQueryResult result, uint32 timeDiff)
//NOTE: the "order by `bag`" is important because it makes sure
//the bagMap is filled before items in the bags are loaded
//NOTE2: the "order by `slot`" is needed because mainhand weapons are (wrongly?)
- //expected to be equipped before offhand items (TODO: fixme)
+ //expected to be equipped before offhand items (@todo fixme)
if (result)
{
@@ -20696,7 +20696,7 @@ void Player::RestoreSpellMods(Spell* spell, uint32 ownerAuraId, Aura* aura)
mod->charges = mod->ownerAura->GetCharges();
// Skip this check for now - aura charges may change due to various reason
- // TODO: trac these changes correctly
+ /// @todo trac these changes correctly
//ASSERT (mod->ownerAura->GetCharges() <= mod->charges);
}
}
@@ -21551,7 +21551,7 @@ void Player::UpdateHomebindTime(uint32 time)
void Player::UpdatePvPState(bool onlyFFA)
{
- // TODO: should we always synchronize UNIT_FIELD_BYTES_2, 1 of controller and controlled?
+ /// @todo should we always synchronize UNIT_FIELD_BYTES_2, 1 of controller and controlled?
// no, we shouldn't, those are checked for affecting player by client
if (!pvpInfo.IsInNoPvPArea && !isGameMaster()
&& (pvpInfo.IsInFFAPvPArea || sWorld->IsFFAPvPRealm()))
@@ -23825,7 +23825,7 @@ PartyResult Player::CanUninviteFromGroup() const
if (grp->isRollLootActive())
return ERR_PARTY_LFG_BOOT_LOOT_ROLLS;
- // TODO: Should also be sent when anyone has recently left combat, with an aprox ~5 seconds timer.
+ /// @todo Should also be sent when anyone has recently left combat, with an aprox ~5 seconds timer.
for (GroupReference const* itr = grp->GetFirstMember(); itr != NULL; itr = itr->next())
if (itr->getSource() && itr->getSource()->isInCombat())
return ERR_PARTY_LFG_BOOT_IN_COMBAT;
@@ -25913,7 +25913,7 @@ bool Player::AddItem(uint32 itemId, uint32 count)
if (count == 0 || dest.empty())
{
- // -- TODO: Send to mailbox if no space
+ /// @todo Send to mailbox if no space
ChatHandler(GetSession()).PSendSysMessage("You don't have any space in your bags.");
return false;
}
diff --git a/src/server/game/Entities/Totem/Totem.cpp b/src/server/game/Entities/Totem/Totem.cpp
index c2dec9086ca..07aa28ecee0 100644
--- a/src/server/game/Entities/Totem/Totem.cpp
+++ b/src/server/game/Entities/Totem/Totem.cpp
@@ -148,7 +148,7 @@ void Totem::UnSummon(uint32 msTime)
bool Totem::IsImmunedToSpellEffect(SpellInfo const* spellInfo, uint32 index) const
{
- // TODO: possibly all negative auras immune?
+ /// @todo possibly all negative auras immune?
if (GetEntry() == 5925)
return false;
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp
index 4c48a55694c..0e93bd93433 100644
--- a/src/server/game/Entities/Unit/Unit.cpp
+++ b/src/server/game/Entities/Unit/Unit.cpp
@@ -624,7 +624,7 @@ uint32 Unit::DealDamage(Unit* victim, uint32 damage, CleanDamage const* cleanDam
uint32 share = CalculatePct(damage, (*i)->GetAmount());
- // TODO: check packets if damage is done by victim, or by attacker of victim
+ /// @todo check packets if damage is done by victim, or by attacker of victim
DealDamageMods(shareDamageTarget, share, NULL);
DealDamage(shareDamageTarget, share, NULL, NODAMAGE, spell->GetSchoolMask(), spell, false);
}
@@ -844,7 +844,7 @@ void Unit::CastSpell(SpellCastTargets const& targets, SpellInfo const* spellInfo
return;
}
- // TODO: this is a workaround - not needed anymore, but required for some scripts :(
+ /// @todo this is a workaround - not needed anymore, but required for some scripts :(
if (!originalCaster && triggeredByAura)
originalCaster = triggeredByAura->GetCasterGUID();
@@ -1104,7 +1104,7 @@ void Unit::DealSpellDamage(SpellNonMeleeDamage* damageInfo, bool durabilityLoss)
DealDamage(victim, damageInfo->damage, &cleanDamage, SPELL_DIRECT_DAMAGE, SpellSchoolMask(damageInfo->schoolMask), spellProto, durabilityLoss);
}
-// TODO for melee need create structure as in
+/// @todo for melee need create structure as in
void Unit::CalculateMeleeDamage(Unit* victim, uint32 damage, CalcDamageInfo* damageInfo, WeaponAttackType attackType)
{
damageInfo->attacker = this;
@@ -1427,7 +1427,7 @@ void Unit::DealMeleeDamage(CalcDamageInfo* damageInfo, bool durabilityLoss)
// No Unit::CalcAbsorbResist here - opcode doesn't send that data - this damage is probably not affected by that
victim->DealDamageMods(this, damage, NULL);
- // TODO: Move this to a packet handler
+ /// @todo Move this to a packet handler
WorldPacket data(SMSG_SPELLDAMAGESHIELD, (8+8+4+4+4+4));
data << uint64(victim->GetGUID());
data << uint64(GetGUID());
@@ -2456,7 +2456,7 @@ SpellMissInfo Unit::MeleeSpellHitResult(Unit* victim, SpellInfo const* spell)
return SPELL_MISS_NONE;
}
-// TODO need use unit spell resistances in calculations
+/// @todo need use unit spell resistances in calculations
SpellMissInfo Unit::MagicSpellHitResult(Unit* victim, SpellInfo const* spell)
{
// Can`t miss on dead target (on skinning for example)
@@ -2575,7 +2575,7 @@ SpellMissInfo Unit::SpellHitResult(Unit* victim, SpellInfo const* spell, bool Ca
return SPELL_MISS_IMMUNE;
// All positive spells can`t miss
- // TODO: client not show miss log for this spells - so need find info for this in dbc and use it!
+ /// @todo client not show miss log for this spells - so need find info for this in dbc and use it!
if (spell->IsPositive()
&&(!IsHostileTo(victim))) // prevent from affecting enemy by "positive" spell
return SPELL_MISS_NONE;
@@ -5200,7 +5200,7 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere
target = this;
if (roll_chance_i(10))
- ToPlayer()->Say("This is Madness!", LANG_UNIVERSAL); // TODO: It should be moved to database, shouldn't it?
+ ToPlayer()->Say("This is Madness!", LANG_UNIVERSAL); /// @todo It should be moved to database, shouldn't it?
break;
}
// Sunwell Exalted Caster Neck (??? neck)
@@ -5600,7 +5600,7 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere
if (!vehicleBase)
return false;
- // Todo: Check if this amount is blizzlike
+ /// @todo Check if this amount is blizzlike
vehicleBase->ModifyHealth(int32(vehicleBase->CountPctFromMaxHealth(1)));
break;
}
@@ -7181,7 +7181,7 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere
// Mark of Blood
if (dummySpell->Id == 49005)
{
- // TODO: need more info (cooldowns/PPM)
+ /// @todo need more info (cooldowns/PPM)
triggered_spell_id = 61607;
break;
}
@@ -8092,7 +8092,7 @@ bool Unit::HandleProcTriggerSpell(Unit* victim, uint32 damage, AuraEffect* trigg
basepoints0 = int32(auraSpellInfo->Effects[EFFECT_0].CalcValue() * GetMaxHealth() / 100.0f);
target = this;
trigger_spell_id = 31616;
- // TODO: Threat part
+ /// @todo Threat part
}
else
return false;
@@ -8449,7 +8449,7 @@ bool Unit::HandleProcTriggerSpell(Unit* victim, uint32 damage, AuraEffect* trigg
{
if (AuraEffect* aurEff = owner->GetDummyAuraEffect(SPELLFAMILY_WARLOCK, 3220, 0))
{
- basepoints0 = int32((aurEff->GetAmount() * owner->SpellBaseDamageBonusDone(SpellSchoolMask(SPELL_SCHOOL_MASK_MAGIC)) + 100.0f) / 100.0f); // TODO: Is it right?
+ basepoints0 = int32((aurEff->GetAmount() * owner->SpellBaseDamageBonusDone(SpellSchoolMask(SPELL_SCHOOL_MASK_MAGIC)) + 100.0f) / 100.0f); /// @todo Is it right?
CastCustomSpell(this, trigger_spell_id, &basepoints0, &basepoints0, NULL, true, castItem, triggeredByAura);
return true;
}
@@ -9527,7 +9527,7 @@ void Unit::SetCharm(Unit* charm, bool apply)
sLog->outFatal(LOG_FILTER_UNITS, "Player %s is trying to charm unit %u, but it already has a charmed unit " UI64FMTD "", GetName().c_str(), charm->GetEntry(), GetCharmGUID());
charm->m_ControlledByPlayer = true;
- // TODO: maybe we can use this flag to check if controlled by player
+ /// @todo maybe we can use this flag to check if controlled by player
charm->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE);
}
else
@@ -9644,7 +9644,7 @@ Unit* Unit::GetMagicHitRedirectTarget(Unit* victim, SpellInfo const* spellInfo)
&& spellInfo->CheckTarget(this, magnet, false) == SPELL_CAST_OK
&& _IsValidAttackTarget(magnet, spellInfo))
{
- // TODO: handle this charge drop by proc in cast phase on explicit target
+ /// @todo handle this charge drop by proc in cast phase on explicit target
(*itr)->GetBase()->DropCharge(AURA_REMOVE_BY_EXPIRE);
return magnet;
}
@@ -10645,7 +10645,7 @@ uint32 Unit::SpellCriticalDamageBonus(SpellInfo const* spellProto, uint32 damage
{
case SPELL_DAMAGE_CLASS_MELEE: // for melee based spells is 100%
case SPELL_DAMAGE_CLASS_RANGED:
- // TODO: write here full calculation for melee/ranged spells
+ /// @todo write here full calculation for melee/ranged spells
crit_bonus += damage;
break;
default:
@@ -10683,7 +10683,7 @@ uint32 Unit::SpellCriticalHealingBonus(SpellInfo const* spellProto, uint32 damag
{
case SPELL_DAMAGE_CLASS_MELEE: // for melee based spells is 100%
case SPELL_DAMAGE_CLASS_RANGED:
- // TODO: write here full calculation for melee/ranged spells
+ /// @todo write here full calculation for melee/ranged spells
crit_bonus = damage;
break;
default:
@@ -12257,7 +12257,7 @@ void Unit::UpdateSpeed(UnitMoveType mtype, bool forced)
}
// Normalize speed by 191 aura SPELL_AURA_USE_NORMAL_MOVEMENT_SPEED if need
- // TODO: possible affect only on MOVE_RUN
+ /// @todo possible affect only on MOVE_RUN
if (int32 normalization = GetMaxPositiveAuraModifier(SPELL_AURA_USE_NORMAL_MOVEMENT_SPEED))
{
// Use speed from aura
@@ -12683,7 +12683,7 @@ Unit* Creature::SelectVictim()
return NULL;
}
- // TODO: a vehicle may eat some mob, so mob should not evade
+ /// @todo a vehicle may eat some mob, so mob should not evade
if (GetVehicle())
return NULL;
@@ -15362,7 +15362,7 @@ void Unit::Kill(Unit* victim, bool durabilityLoss)
{
Map* instanceMap = creature->GetMap();
Player* creditedPlayer = GetCharmerOrOwnerPlayerOrPlayerItself();
- // TODO: do instance binding anyway if the charmer/owner is offline
+ /// @todo do instance binding anyway if the charmer/owner is offline
if (instanceMap->IsDungeon() && creditedPlayer)
{
@@ -15724,7 +15724,7 @@ bool Unit::SetCharmedBy(Unit* charmer, CharmType type, AuraApplication const* au
}
CastStop();
- CombatStop(); // TODO: CombatStop(true) may cause crash (interrupt spells)
+ CombatStop(); /// @todo CombatStop(true) may cause crash (interrupt spells)
DeleteThreatList();
// Charmer stop charming
@@ -15859,7 +15859,7 @@ void Unit::RemoveCharmedBy(Unit* charmer)
type = CHARM_TYPE_CHARM;
CastStop();
- CombatStop(); // TODO: CombatStop(true) may cause crash (interrupt spells)
+ CombatStop(); /// @todo CombatStop(true) may cause crash (interrupt spells)
getHostileRefManager().deleteReferences();
DeleteThreatList();
Map* map = GetMap();
@@ -17389,7 +17389,7 @@ void Unit::SetFacingToObject(WorldObject* object)
if (!IsStopped())
return;
- // TODO: figure out under what conditions creature will move towards object instead of facing it where it currently is.
+ /// @todo figure out under what conditions creature will move towards object instead of facing it where it currently is.
SetFacingTo(GetAngle(object));
}
diff --git a/src/server/game/Entities/Unit/Unit.h b/src/server/game/Entities/Unit/Unit.h
index 5684a7bfa37..dc4c89198db 100644
--- a/src/server/game/Entities/Unit/Unit.h
+++ b/src/server/game/Entities/Unit/Unit.h
@@ -703,7 +703,7 @@ enum MovementFlags
MOVEMENTFLAG_FALLING_SLOW = 0x20000000, // active rogue safe fall spell (passive)
MOVEMENTFLAG_HOVER = 0x40000000, // hover, cannot jump
- // TODO: Check if PITCH_UP and PITCH_DOWN really belong here..
+ /// @todo Check if PITCH_UP and PITCH_DOWN really belong here..
MOVEMENTFLAG_MASK_MOVING =
MOVEMENTFLAG_FORWARD | MOVEMENTFLAG_BACKWARD | MOVEMENTFLAG_STRAFE_LEFT | MOVEMENTFLAG_STRAFE_RIGHT |
MOVEMENTFLAG_PITCH_UP | MOVEMENTFLAG_PITCH_DOWN | MOVEMENTFLAG_FALLING | MOVEMENTFLAG_FALLING_FAR | MOVEMENTFLAG_ASCENDING | MOVEMENTFLAG_DESCENDING |
@@ -715,7 +715,7 @@ enum MovementFlags
MOVEMENTFLAG_MASK_MOVING_FLY =
MOVEMENTFLAG_FLYING | MOVEMENTFLAG_ASCENDING | MOVEMENTFLAG_DESCENDING,
- //! TODO if needed: add more flags to this masks that are exclusive to players
+ /// @todo if needed: add more flags to this masks that are exclusive to players
MOVEMENTFLAG_MASK_PLAYER_ONLY =
MOVEMENTFLAG_FLYING
};
@@ -926,7 +926,7 @@ struct CalcDamageInfo
uint32 procVictim;
uint32 procEx;
uint32 cleanDamage; // Used only for rage calculation
- MeleeHitOutcome hitOutCome; // TODO: remove this field (need use TargetState)
+ MeleeHitOutcome hitOutCome; /// @todo remove this field (need use TargetState)
};
// Spell damage info structure based on structure sending in SMSG_SPELLNONMELEEDAMAGELOG opcode