mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 22:37:03 +00:00
Various Cleanups (game T-Z)
This commit is contained in:
parent
08fd085549
commit
6379a746d7
34 changed files with 2858 additions and 2852 deletions
|
|
@ -362,7 +362,8 @@ HostileReference* ThreatContainer::selectNextVictim(Creature* pAttacker, Hostile
|
|||
|
||||
if (pCurrentRef->getThreat() > 1.3f * pCurrentVictim->getThreat() ||
|
||||
(pCurrentRef->getThreat() > 1.1f * pCurrentVictim->getThreat() && pAttacker->CanReachWithMeleeAttack(pTarget)))
|
||||
{ // implement 110% threat rule for targets in melee range
|
||||
{
|
||||
// implement 110% threat rule for targets in melee range
|
||||
found = true; // and 130% rule for targets in ranged distances
|
||||
break; // for selecting alive targets
|
||||
}
|
||||
|
|
|
|||
|
|
@ -116,7 +116,8 @@ void MapManager::LoadTransports()
|
|||
|
||||
//t->GetMap()->Add<GameObject>((GameObject *)t);
|
||||
++count;
|
||||
} while(result->NextRow());
|
||||
}
|
||||
while (result->NextRow());
|
||||
delete result;
|
||||
|
||||
sLog.outString();
|
||||
|
|
|
|||
|
|
@ -10975,7 +10975,8 @@ void Unit::SetVehicleId(uint32 entry)
|
|||
|
||||
void Unit::UpdateSplineMovement(uint32 t_diff)
|
||||
{
|
||||
enum{
|
||||
enum
|
||||
{
|
||||
POSITION_UPDATE_DELAY = 400,
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -756,7 +756,8 @@ inline ByteBuffer& operator>> (ByteBuffer& buf, MovementInfo& mi)
|
|||
return buf;
|
||||
}
|
||||
|
||||
namespace Movement{
|
||||
namespace Movement
|
||||
{
|
||||
class MoveSpline;
|
||||
}
|
||||
|
||||
|
|
@ -827,7 +828,8 @@ struct CalcDamageInfo
|
|||
};
|
||||
|
||||
// Spell damage info structure based on structure sending in SMSG_SPELLNONMELEEDAMAGELOG opcode
|
||||
struct SpellNonMeleeDamage{
|
||||
struct SpellNonMeleeDamage
|
||||
{
|
||||
SpellNonMeleeDamage(Unit* _attacker, Unit* _target, uint32 _SpellID, SpellSchoolMask _schoolMask)
|
||||
: target(_target), attacker(_attacker), SpellID(_SpellID), damage(0), schoolMask(_schoolMask),
|
||||
absorb(0), resist(0), physicalLog(false), unused(false), blocked(0), HitInfo(0)
|
||||
|
|
|
|||
|
|
@ -323,7 +323,8 @@ bool FlightPathMovementGenerator::Update(Player &player, const uint32 &diff)
|
|||
break;
|
||||
i_currentNode += (uint32)departureEvent;
|
||||
departureEvent = !departureEvent;
|
||||
} while(true);
|
||||
}
|
||||
while (true);
|
||||
}
|
||||
|
||||
return i_currentNode < (i_path->size()-1);
|
||||
|
|
|
|||
|
|
@ -363,8 +363,7 @@ void WorldSession::LogoutPlayer(bool Save)
|
|||
if (owner->GetTypeId()==TYPEID_PLAYER)
|
||||
aset.insert((Player*)owner);
|
||||
}
|
||||
else
|
||||
if((*itr)->GetTypeId()==TYPEID_PLAYER)
|
||||
else if ((*itr)->GetTypeId()==TYPEID_PLAYER)
|
||||
aset.insert((Player*)(*itr));
|
||||
}
|
||||
|
||||
|
|
@ -661,7 +660,8 @@ void WorldSession::LoadAccountData(QueryResult* result, uint32 mask)
|
|||
m_accountData[type].Time = time_t(fields[1].GetUInt64());
|
||||
m_accountData[type].Data = fields[2].GetCppString();
|
||||
|
||||
} while (result->NextRow());
|
||||
}
|
||||
while (result->NextRow());
|
||||
|
||||
delete result;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue