aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSpp- <u84280@epreinf21.(none)>2011-08-01 14:51:44 +0200
committerSpp- <u84280@epreinf21.(none)>2011-08-01 14:51:44 +0200
commit079f292b15eea7d5bb679d098c4675797ba14e5f (patch)
tree2162a5ad9c1726664de03d90ff4ebb9097585b60 /src
parentacd0fc79f63f6881ead6fff2985755dd45ea3a5d (diff)
Core: Some more missing changes from previous commit (Pass by const reference for simple objects replaced with pass by value). Also fix unintended change
Diffstat (limited to 'src')
-rwxr-xr-xsrc/server/game/AI/CoreAI/UnitAI.h2
-rw-r--r--src/server/game/Battlegrounds/ArenaTeamMgr.cpp2
-rw-r--r--src/server/game/Battlegrounds/ArenaTeamMgr.h2
-rwxr-xr-xsrc/server/game/Battlegrounds/Zones/BattlegroundEY.h2
-rwxr-xr-xsrc/server/game/Battlegrounds/Zones/BattlegroundIC.cpp2
-rwxr-xr-xsrc/server/game/Battlegrounds/Zones/BattlegroundIC.h2
-rwxr-xr-xsrc/server/game/Entities/Corpse/Corpse.h2
-rwxr-xr-xsrc/server/game/Entities/Creature/TemporarySummon.h2
-rwxr-xr-xsrc/server/game/Entities/Item/Item.h2
-rwxr-xr-xsrc/server/game/Entities/Object/ObjectDefines.h2
-rwxr-xr-xsrc/server/game/Entities/Vehicle/Vehicle.h2
-rw-r--r--src/server/game/Guilds/GuildMgr.h2
-rwxr-xr-xsrc/server/game/Spells/Auras/SpellAuras.h8
-rwxr-xr-xsrc/server/game/Spells/SpellScript.cpp2
-rwxr-xr-xsrc/server/game/Spells/SpellScript.h2
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp2
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp2
-rwxr-xr-xsrc/server/scripts/Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp2
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp2
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.cpp2
-rw-r--r--src/server/scripts/Northrend/Nexus/Nexus/boss_keristrasza.cpp2
-rwxr-xr-xsrc/server/shared/Packets/ByteBuffer.h2
22 files changed, 25 insertions, 25 deletions
diff --git a/src/server/game/AI/CoreAI/UnitAI.h b/src/server/game/AI/CoreAI/UnitAI.h
index 6bd9c98bd64..dbd4c14ed25 100755
--- a/src/server/game/AI/CoreAI/UnitAI.h
+++ b/src/server/game/AI/CoreAI/UnitAI.h
@@ -120,7 +120,7 @@ class UnitAI
virtual void DoAction(int32 const /*param*/) {}
virtual uint32 GetData(uint32 /*id = 0*/) { return 0; }
virtual void SetData(uint32 /*id*/, uint32 /*value*/) {}
- virtual void SetGUID(uint64 const&/*guid*/, int32 /*id*/ = 0) {}
+ virtual void SetGUID(unit64 const/*guid*/, int32 /*id*/ = 0) {}
virtual uint64 GetGUID(int32 /*id*/ = 0) { return 0; }
Unit* SelectTarget(SelectAggroTarget targetType, uint32 position = 0, float dist = 0.0f, bool playerOnly = false, int32 aura = 0);
diff --git a/src/server/game/Battlegrounds/ArenaTeamMgr.cpp b/src/server/game/Battlegrounds/ArenaTeamMgr.cpp
index 0d677cb3521..0ff3faf50af 100644
--- a/src/server/game/Battlegrounds/ArenaTeamMgr.cpp
+++ b/src/server/game/Battlegrounds/ArenaTeamMgr.cpp
@@ -53,7 +53,7 @@ ArenaTeam* ArenaTeamMgr::GetArenaTeamByName(const std::string& arenaTeamName) co
return NULL;
}
-ArenaTeam* ArenaTeamMgr::GetArenaTeamByCaptain(uint64 const& guid) const
+ArenaTeam* ArenaTeamMgr::GetArenaTeamByCaptain(unit64 const guid) const
{
for (ArenaTeamContainer::const_iterator itr = ArenaTeamStore.begin(); itr != ArenaTeamStore.end(); ++itr)
if (itr->second->GetCaptain() == guid)
diff --git a/src/server/game/Battlegrounds/ArenaTeamMgr.h b/src/server/game/Battlegrounds/ArenaTeamMgr.h
index ac368d65fcc..0f58b145012 100644
--- a/src/server/game/Battlegrounds/ArenaTeamMgr.h
+++ b/src/server/game/Battlegrounds/ArenaTeamMgr.h
@@ -31,7 +31,7 @@ public:
ArenaTeam* GetArenaTeamById(uint32 arenaTeamId) const;
ArenaTeam* GetArenaTeamByName(const std::string& arenaTeamName) const;
- ArenaTeam* GetArenaTeamByCaptain(uint64 const& guid) const;
+ ArenaTeam* GetArenaTeamByCaptain(unit64 const guid) const;
void LoadArenaTeams();
void AddArenaTeam(ArenaTeam* arenaTeam);
diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundEY.h b/src/server/game/Battlegrounds/Zones/BattlegroundEY.h
index 3609b8b44d8..d8369c29582 100755
--- a/src/server/game/Battlegrounds/Zones/BattlegroundEY.h
+++ b/src/server/game/Battlegrounds/Zones/BattlegroundEY.h
@@ -349,7 +349,7 @@ class BattlegroundEY : public Battleground
void RespawnFlagAfterDrop();
void RemovePlayer(Player *plr, uint64 guid, uint32 team);
- void HandleBuffUse(uint64 const& buff_guid);
+ void HandleBuffUse(unit64 const buff_guid);
void HandleAreaTrigger(Player *Source, uint32 Trigger);
void HandleKillPlayer(Player* player, Player* killer);
virtual WorldSafeLocsEntry const* GetClosestGraveYard(Player* player);
diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp
index 28fc844b119..bd0e0fc0251 100755
--- a/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp
+++ b/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp
@@ -85,7 +85,7 @@ void BattlegroundIC::SendTransportInit(Player* player)
player->GetSession()->SendPacket(&packet);
}
-void BattlegroundIC::DoAction(uint32 action, uint64 const& var)
+void BattlegroundIC::DoAction(uint32 action, unit64 const var)
{
if (action != ACTION_TELEPORT_PLAYER_TO_TRANSPORT)
return;
diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundIC.h b/src/server/game/Battlegrounds/Zones/BattlegroundIC.h
index 6ffdff2da55..e26aaad64a4 100755
--- a/src/server/game/Battlegrounds/Zones/BattlegroundIC.h
+++ b/src/server/game/Battlegrounds/Zones/BattlegroundIC.h
@@ -888,7 +888,7 @@ class BattlegroundIC : public Battleground
void FillInitialWorldStates(WorldPacket& data);
- void DoAction(uint32 action, uint64 const& var);
+ void DoAction(uint32 action, unit64 const var);
virtual void HandlePlayerResurrect(Player* player);
diff --git a/src/server/game/Entities/Corpse/Corpse.h b/src/server/game/Entities/Corpse/Corpse.h
index d977aed0719..c58e89d68a5 100755
--- a/src/server/game/Entities/Corpse/Corpse.h
+++ b/src/server/game/Entities/Corpse/Corpse.h
@@ -64,7 +64,7 @@ class Corpse : public WorldObject, public GridObject<Corpse>
void DeleteBonesFromWorld();
void DeleteFromDB(SQLTransaction& trans);
- uint64 const& GetOwnerGUID() const { return GetUInt64Value(CORPSE_FIELD_OWNER); }
+ unit64 const GetOwnerGUID() const { return GetUInt64Value(CORPSE_FIELD_OWNER); }
time_t const& GetGhostTime() const { return m_time; }
void ResetGhostTime() { m_time = time(NULL); }
diff --git a/src/server/game/Entities/Creature/TemporarySummon.h b/src/server/game/Entities/Creature/TemporarySummon.h
index 67a94ecd591..7130b0b6944 100755
--- a/src/server/game/Entities/Creature/TemporarySummon.h
+++ b/src/server/game/Entities/Creature/TemporarySummon.h
@@ -34,7 +34,7 @@ class TempSummon : public Creature
void SetTempSummonType(TempSummonType type);
void SaveToDB(uint32 /*mapid*/, uint8 /*spawnMask*/, uint32 /*phaseMask*/) {}
Unit* GetSummoner() const;
- uint64 const& GetSummonerGUID() { return m_summonerGUID; }
+ unit64 const GetSummonerGUID() { return m_summonerGUID; }
TempSummonType const& GetSummonType() { return m_type; }
const SummonPropertiesEntry * const m_Properties;
diff --git a/src/server/game/Entities/Item/Item.h b/src/server/game/Entities/Item/Item.h
index c3c6b999fcc..22aa9e96590 100755
--- a/src/server/game/Entities/Item/Item.h
+++ b/src/server/game/Entities/Item/Item.h
@@ -235,7 +235,7 @@ class Item : public Object
ItemTemplate const* GetTemplate() const;
- uint64 const& GetOwnerGUID() const { return GetUInt64Value(ITEM_FIELD_OWNER); }
+ unit64 const GetOwnerGUID() const { return GetUInt64Value(ITEM_FIELD_OWNER); }
void SetOwnerGUID(uint64 guid) { SetUInt64Value(ITEM_FIELD_OWNER, guid); }
Player* GetOwner()const;
diff --git a/src/server/game/Entities/Object/ObjectDefines.h b/src/server/game/Entities/Object/ObjectDefines.h
index 956370e7878..f2a04d827bc 100755
--- a/src/server/game/Entities/Object/ObjectDefines.h
+++ b/src/server/game/Entities/Object/ObjectDefines.h
@@ -78,7 +78,7 @@ enum HighGuid
#define _GUID_LOPART_2(x) (uint32)(uint64(x) & UI64LIT(0x00000000FFFFFFFF))
#define _GUID_LOPART_3(x) (uint32)(uint64(x) & UI64LIT(0x0000000000FFFFFF))
-inline bool IsGuidHaveEnPart(uint64 const& guid)
+inline bool IsGuidHaveEnPart(unit64 const guid)
{
switch(GUID_HIPART(guid))
{
diff --git a/src/server/game/Entities/Vehicle/Vehicle.h b/src/server/game/Entities/Vehicle/Vehicle.h
index b20fe3237f9..6838d9edaec 100755
--- a/src/server/game/Entities/Vehicle/Vehicle.h
+++ b/src/server/game/Entities/Vehicle/Vehicle.h
@@ -118,7 +118,7 @@ class Vehicle
Unit* GetBase() const { return _me; }
VehicleEntry const* GetVehicleInfo() const { return _vehicleInfo; }
- uint32 const& GetCreatureEntry() const { return _creatureEntry; }
+ uint32 const GetCreatureEntry() const { return _creatureEntry; }
bool HasEmptySeat(int8 seatId) const;
Unit* GetPassenger(int8 seatId) const;
diff --git a/src/server/game/Guilds/GuildMgr.h b/src/server/game/Guilds/GuildMgr.h
index 2eb91ff4ad8..0f6823eb378 100644
--- a/src/server/game/Guilds/GuildMgr.h
+++ b/src/server/game/Guilds/GuildMgr.h
@@ -29,7 +29,7 @@ class GuildMgr
public:
typedef UNORDERED_MAP<uint32, Guild*> GuildContainer;
- Guild* GetGuildByLeader(uint64 const& guid) const;
+ Guild* GetGuildByLeader(unit64 const guid) const;
Guild* GetGuildById(uint32 guildId) const;
Guild* GetGuildByName(const std::string& guildName) const;
std::string GetGuildNameById(uint32 guildId) const;
diff --git a/src/server/game/Spells/Auras/SpellAuras.h b/src/server/game/Spells/Auras/SpellAuras.h
index b5385d193ea..b7473954b2b 100755
--- a/src/server/game/Spells/Auras/SpellAuras.h
+++ b/src/server/game/Spells/Auras/SpellAuras.h
@@ -99,7 +99,7 @@ class Aura
uint32 GetId() const{ return GetSpellInfo()->Id; }
uint64 GetCastItemGUID() const { return m_castItemGuid; }
- uint64 const& GetCasterGUID() const { return m_casterGuid; }
+ unit64 const GetCasterGUID() const { return m_casterGuid; }
Unit* GetCaster() const;
WorldObject * GetOwner() const { return m_owner; }
Unit* GetUnitOwner() const { ASSERT(GetType() == UNIT_AURA_TYPE); return (Unit*)m_owner; }
@@ -175,9 +175,9 @@ class Aura
// Helpers for targets
ApplicationMap const & GetApplicationMap() {return m_applications;}
void GetApplicationList(std::list<AuraApplication*> & applicationList) const;
- const AuraApplication * GetApplicationOfTarget (uint64 const & guid) const { ApplicationMap::const_iterator itr = m_applications.find(guid); if (itr != m_applications.end()) return itr->second; return NULL; }
- AuraApplication * GetApplicationOfTarget (uint64 const & guid) { ApplicationMap::iterator itr = m_applications.find(guid); if (itr != m_applications.end()) return itr->second; return NULL; }
- bool IsAppliedOnTarget(uint64 const & guid) const { return m_applications.find(guid) != m_applications.end(); }
+ const AuraApplication * GetApplicationOfTarget (unit64 const guid) const { ApplicationMap::const_iterator itr = m_applications.find(guid); if (itr != m_applications.end()) return itr->second; return NULL; }
+ AuraApplication * GetApplicationOfTarget (unit64 const guid) { ApplicationMap::iterator itr = m_applications.find(guid); if (itr != m_applications.end()) return itr->second; return NULL; }
+ bool IsAppliedOnTarget(unit64 const guid) const { return m_applications.find(guid) != m_applications.end(); }
void SetNeedClientUpdateForTargets() const;
void HandleAuraSpecificMods(AuraApplication const* aurApp, Unit* caster, bool apply, bool onReapply);
diff --git a/src/server/game/Spells/SpellScript.cpp b/src/server/game/Spells/SpellScript.cpp
index fb4d9afb9ad..689ab3bf8be 100755
--- a/src/server/game/Spells/SpellScript.cpp
+++ b/src/server/game/Spells/SpellScript.cpp
@@ -713,7 +713,7 @@ uint32 AuraScript::GetId() const
return m_aura->GetId();
}
-uint64 const& AuraScript::GetCasterGUID() const
+unit64 const AuraScript::GetCasterGUID() const
{
return m_aura->GetCasterGUID();
}
diff --git a/src/server/game/Spells/SpellScript.h b/src/server/game/Spells/SpellScript.h
index aa0dc044e14..3b44bf92667 100755
--- a/src/server/game/Spells/SpellScript.h
+++ b/src/server/game/Spells/SpellScript.h
@@ -585,7 +585,7 @@ class AuraScript : public _SpellScript
uint32 GetId() const;
// returns guid of object which casted the aura (m_originalCaster of the Spell class)
- uint64 const& GetCasterGUID() const;
+ unit64 const GetCasterGUID() const;
// returns unit which casted the aura or NULL if not avalible (caster logged out for example)
Unit* GetCaster() const;
// returns object on which aura was casted, target for non-area auras, area aura source for area auras
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp
index bf70e8500a7..075c371b8f3 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp
@@ -1176,7 +1176,7 @@ class npc_ball_of_flame : public CreatureScript
}
}
- void SetGUID(uint64 const& guid, int32 /*type*/)
+ void SetGUID(unit64 const guid, int32 /*type*/)
{
_chaseGUID = guid;
}
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
index 3fe8b7f6aa8..a2cd4e5b16f 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
@@ -253,7 +253,7 @@ class boss_blood_queen_lana_thel : public CreatureScript
Talk(SAY_KILL);
}
- void SetGUID(uint64 const& guid, int32 type = 0)
+ void SetGUID(unit64 const guid, int32 type = 0)
{
if (type == GUID_VAMPIRE)
_vampires.insert(guid);
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp
index 4f8ed4c536f..04752d4b04e 100755
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp
@@ -548,7 +548,7 @@ class boss_lady_deathwhisper : public CreatureScript
summon->AI()->DoCast(summon, SPELL_TELEPORT_VISUAL);
}
- void SetGUID(uint64 const& guid, int32 id/* = 0*/)
+ void SetGUID(unit64 const guid, int32 id/* = 0*/)
{
if (id != GUID_CULTIST)
return;
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp
index e5bb5ac6e60..3db875baf11 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp
@@ -523,7 +523,7 @@ class npc_ice_tomb : public CreatureScript
me->SetReactState(REACT_PASSIVE);
}
- void SetGUID(uint64 const& guid, int32 type/* = 0 */)
+ void SetGUID(unit64 const guid, int32 type/* = 0 */)
{
if (type == DATA_TRAPPED_PLAYER)
{
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.cpp b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.cpp
index 09c19dd8a71..a6682701640 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.cpp
@@ -971,7 +971,7 @@ class npc_crok_scourgebane : public CreatureScript
}
}
- void SetGUID(uint64 const& guid, int32 type/* = 0*/)
+ void SetGUID(unit64 const guid, int32 type/* = 0*/)
{
if (type == ACTION_VRYKUL_DEATH)
{
diff --git a/src/server/scripts/Northrend/Nexus/Nexus/boss_keristrasza.cpp b/src/server/scripts/Northrend/Nexus/Nexus/boss_keristrasza.cpp
index a8ccd350bc3..9688a9a9568 100644
--- a/src/server/scripts/Northrend/Nexus/Nexus/boss_keristrasza.cpp
+++ b/src/server/scripts/Northrend/Nexus/Nexus/boss_keristrasza.cpp
@@ -157,7 +157,7 @@ public:
}
}
- void SetGUID(uint64 const& guid, int32 id/* = 0 */)
+ void SetGUID(unit64 const guid, int32 id/* = 0 */)
{
if (id == DATA_INTENSE_COLD)
intenseColdList.push_back(guid);
diff --git a/src/server/shared/Packets/ByteBuffer.h b/src/server/shared/Packets/ByteBuffer.h
index c48d0220f5d..34bfea019ab 100755
--- a/src/server/shared/Packets/ByteBuffer.h
+++ b/src/server/shared/Packets/ByteBuffer.h
@@ -299,7 +299,7 @@ class ByteBuffer
_rpos += len;
}
- void readPackGUID(uint64 guid)
+ void readPackGUID(uint64& guid)
{
if(rpos() + 1 > size())
throw ByteBufferException(false, _rpos, 1, size());