[8786] Rename some files.

* HostilRefManager.cpp/.h -> HostileRefManager.cpp/.h
 * PoolHandler.cpp/.h -> PoolManager.cpp/.h
This commit is contained in:
XTZGZoReX 2009-11-08 04:21:43 +01:00
parent dc725ad6b8
commit 33d475caf3
15 changed files with 40 additions and 40 deletions

View file

@ -26,7 +26,7 @@
#include "QuestDef.h" #include "QuestDef.h"
#include "GossipDef.h" #include "GossipDef.h"
#include "Player.h" #include "Player.h"
#include "PoolHandler.h" #include "PoolManager.h"
#include "Opcodes.h" #include "Opcodes.h"
#include "Log.h" #include "Log.h"
#include "LootMgr.h" #include "LootMgr.h"

View file

@ -19,7 +19,7 @@
#include "GameEventMgr.h" #include "GameEventMgr.h"
#include "World.h" #include "World.h"
#include "ObjectMgr.h" #include "ObjectMgr.h"
#include "PoolHandler.h" #include "PoolManager.h"
#include "ProgressBar.h" #include "ProgressBar.h"
#include "Language.h" #include "Language.h"
#include "Log.h" #include "Log.h"

View file

@ -20,7 +20,7 @@
#include "QuestDef.h" #include "QuestDef.h"
#include "GameObject.h" #include "GameObject.h"
#include "ObjectMgr.h" #include "ObjectMgr.h"
#include "PoolHandler.h" #include "PoolManager.h"
#include "SpellMgr.h" #include "SpellMgr.h"
#include "Spell.h" #include "Spell.h"
#include "UpdateMask.h" #include "UpdateMask.h"

View file

@ -16,7 +16,7 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/ */
#include "HostilRefManager.h" #include "HostileRefManager.h"
#include "ThreatManager.h" #include "ThreatManager.h"
#include "Unit.h" #include "Unit.h"
#include "DBCStructure.h" #include "DBCStructure.h"

View file

@ -30,7 +30,7 @@
#include "World.h" #include "World.h"
#include "GameEventMgr.h" #include "GameEventMgr.h"
#include "SpellMgr.h" #include "SpellMgr.h"
#include "PoolHandler.h" #include "PoolManager.h"
#include "AccountMgr.h" #include "AccountMgr.h"
#include "GMTicketMgr.h" #include "GMTicketMgr.h"
#include "WaypointManager.h" #include "WaypointManager.h"

View file

@ -148,8 +148,8 @@ libmangosgame_a_SOURCES = \
GuildHandler.cpp \ GuildHandler.cpp \
HomeMovementGenerator.cpp \ HomeMovementGenerator.cpp \
HomeMovementGenerator.h \ HomeMovementGenerator.h \
HostilRefManager.cpp \ HostileRefManager.cpp \
HostilRefManager.h \ HostileRefManager.h \
IdleMovementGenerator.cpp \ IdleMovementGenerator.cpp \
IdleMovementGenerator.h \ IdleMovementGenerator.h \
InstanceData.cpp \ InstanceData.cpp \
@ -218,8 +218,8 @@ libmangosgame_a_SOURCES = \
PlayerDump.h \ PlayerDump.h \
PointMovementGenerator.cpp \ PointMovementGenerator.cpp \
PointMovementGenerator.h \ PointMovementGenerator.h \
PoolHandler.cpp \ PoolManager.cpp \
PoolHandler.h \ PoolManager.h \
QueryHandler.cpp \ QueryHandler.cpp \
QuestDef.cpp \ QuestDef.cpp \
QuestDef.h \ QuestDef.h \

View file

@ -16,14 +16,14 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/ */
#include "PoolHandler.h" #include "PoolManager.h"
#include "ObjectMgr.h" #include "ObjectMgr.h"
#include "ProgressBar.h" #include "ProgressBar.h"
#include "Log.h" #include "Log.h"
#include "MapManager.h" #include "MapManager.h"
#include "Policies/SingletonImp.h" #include "Policies/SingletonImp.h"
INSTANTIATE_SINGLETON_1(PoolHandler); INSTANTIATE_SINGLETON_1(PoolManager);
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
// Methods of template class PoolGroup // Methods of template class PoolGroup
@ -343,14 +343,14 @@ bool PoolGroup<Pool>::ReSpawn1Object(uint32 /*guid*/)
//////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////
// Methods of class PoolHandler // Methods of class PoolManager
PoolHandler::PoolHandler() PoolManager::PoolManager()
{ {
m_IsPoolSystemStarted = false; m_IsPoolSystemStarted = false;
} }
void PoolHandler::LoadFromDB() void PoolManager::LoadFromDB()
{ {
QueryResult *result = WorldDatabase.Query("SELECT MAX(entry) FROM pool_template"); QueryResult *result = WorldDatabase.Query("SELECT MAX(entry) FROM pool_template");
if (!result) if (!result)
@ -619,7 +619,7 @@ void PoolHandler::LoadFromDB()
} }
// The initialize method will spawn all pools not in an event and not in another pool, this is why there is 2 left joins with 2 null checks // The initialize method will spawn all pools not in an event and not in another pool, this is why there is 2 left joins with 2 null checks
void PoolHandler::Initialize() void PoolManager::Initialize()
{ {
QueryResult *result = WorldDatabase.Query("SELECT DISTINCT pool_template.entry FROM pool_template LEFT JOIN game_event_pool ON pool_template.entry=game_event_pool.pool_entry LEFT JOIN pool_pool ON pool_template.entry=pool_pool.pool_id WHERE game_event_pool.pool_entry IS NULL AND pool_pool.pool_id IS NULL"); QueryResult *result = WorldDatabase.Query("SELECT DISTINCT pool_template.entry FROM pool_template LEFT JOIN game_event_pool ON pool_template.entry=game_event_pool.pool_entry LEFT JOIN pool_pool ON pool_template.entry=pool_pool.pool_id WHERE game_event_pool.pool_entry IS NULL AND pool_pool.pool_id IS NULL");
uint32 count=0; uint32 count=0;
@ -648,7 +648,7 @@ void PoolHandler::Initialize()
// Call to spawn a pool, if cache if true the method will spawn only if cached entry is different // Call to spawn a pool, if cache if true the method will spawn only if cached entry is different
// If it's same, the gameobject/creature is respawned only (added back to map) // If it's same, the gameobject/creature is respawned only (added back to map)
void PoolHandler::SpawnPool(uint16 pool_id, uint32 guid, uint32 type) void PoolManager::SpawnPool(uint16 pool_id, uint32 guid, uint32 type)
{ {
switch (type) switch (type)
{ {
@ -667,7 +667,7 @@ void PoolHandler::SpawnPool(uint16 pool_id, uint32 guid, uint32 type)
} }
// Call to despawn a pool, all gameobjects/creatures in this pool are removed // Call to despawn a pool, all gameobjects/creatures in this pool are removed
void PoolHandler::DespawnPool(uint16 pool_id) void PoolManager::DespawnPool(uint16 pool_id)
{ {
if (!mPoolCreatureGroups[pool_id].isEmpty()) if (!mPoolCreatureGroups[pool_id].isEmpty())
mPoolCreatureGroups[pool_id].DespawnObject(); mPoolCreatureGroups[pool_id].DespawnObject();
@ -682,7 +682,7 @@ void PoolHandler::DespawnPool(uint16 pool_id)
// Call to update the pool when a gameobject/creature part of pool [pool_id] is ready to respawn // Call to update the pool when a gameobject/creature part of pool [pool_id] is ready to respawn
// Here we cache only the creature/gameobject whose guid is passed as parameter // Here we cache only the creature/gameobject whose guid is passed as parameter
// Then the spawn pool call will use this cache to decide // Then the spawn pool call will use this cache to decide
void PoolHandler::UpdatePool(uint16 pool_id, uint32 guid, uint32 type) void PoolManager::UpdatePool(uint16 pool_id, uint32 guid, uint32 type)
{ {
if (uint16 motherpoolid = IsPartOfAPool(pool_id, 0)) if (uint16 motherpoolid = IsPartOfAPool(pool_id, 0))
SpawnPool(motherpoolid, 0, 0); SpawnPool(motherpoolid, 0, 0);
@ -691,7 +691,7 @@ void PoolHandler::UpdatePool(uint16 pool_id, uint32 guid, uint32 type)
} }
// Method that tell if the gameobject/creature is part of a pool and return the pool id if yes // Method that tell if the gameobject/creature is part of a pool and return the pool id if yes
uint16 PoolHandler::IsPartOfAPool(uint32 guid, uint32 type) uint16 PoolManager::IsPartOfAPool(uint32 guid, uint32 type)
{ {
if (type == 0) // pool of pool if (type == 0) // pool of pool
{ {
@ -715,7 +715,7 @@ uint16 PoolHandler::IsPartOfAPool(uint32 guid, uint32 type)
} }
// Method that check chance integrity of the creatures and gameobjects in this pool // Method that check chance integrity of the creatures and gameobjects in this pool
bool PoolHandler::CheckPool(uint16 pool_id) bool PoolManager::CheckPool(uint16 pool_id)
{ {
return pool_id <= max_pool_id && return pool_id <= max_pool_id &&
mPoolGameobjectGroups[pool_id].CheckPool() && mPoolGameobjectGroups[pool_id].CheckPool() &&
@ -724,7 +724,7 @@ bool PoolHandler::CheckPool(uint16 pool_id)
} }
// Method that tell if a creature or gameobject in pool_id is spawned currently // Method that tell if a creature or gameobject in pool_id is spawned currently
bool PoolHandler::IsSpawnedObject(uint16 pool_id, uint32 guid, uint32 type) bool PoolManager::IsSpawnedObject(uint16 pool_id, uint32 guid, uint32 type)
{ {
if (pool_id > max_pool_id) if (pool_id > max_pool_id)
return false; return false;

View file

@ -65,11 +65,11 @@ class Pool // for Pool of Pool
{ {
}; };
class PoolHandler class PoolManager
{ {
public: public:
PoolHandler(); PoolManager();
~PoolHandler() {}; ~PoolManager() {};
void LoadFromDB(); void LoadFromDB();
uint16 IsPartOfAPool(uint32 guid, uint32 type); uint16 IsPartOfAPool(uint32 guid, uint32 type);
bool IsSpawnedObject(uint16 pool_id, uint32 guid, uint32 type); bool IsSpawnedObject(uint16 pool_id, uint32 guid, uint32 type);
@ -99,5 +99,5 @@ class PoolHandler
}; };
#define poolhandler MaNGOS::Singleton<PoolHandler>::Instance() #define poolhandler MaNGOS::Singleton<PoolManager>::Instance()
#endif #endif

View file

@ -26,7 +26,7 @@
#include "UpdateFields.h" #include "UpdateFields.h"
#include "SharedDefines.h" #include "SharedDefines.h"
#include "ThreatManager.h" #include "ThreatManager.h"
#include "HostilRefManager.h" #include "HostileRefManager.h"
#include "FollowerReference.h" #include "FollowerReference.h"
#include "FollowerRefManager.h" #include "FollowerRefManager.h"
#include "Utilities/EventProcessor.h" #include "Utilities/EventProcessor.h"

View file

@ -54,7 +54,7 @@
#include "VMapFactory.h" #include "VMapFactory.h"
#include "GlobalEvents.h" #include "GlobalEvents.h"
#include "GameEventMgr.h" #include "GameEventMgr.h"
#include "PoolHandler.h" #include "PoolManager.h"
#include "Database/DatabaseImpl.h" #include "Database/DatabaseImpl.h"
#include "GridNotifiersImpl.h" #include "GridNotifiersImpl.h"
#include "CellImpl.h" #include "CellImpl.h"

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__ #ifndef __REVISION_NR_H__
#define __REVISION_NR_H__ #define __REVISION_NR_H__
#define REVISION_NR "8785" #define REVISION_NR "8786"
#endif // __REVISION_NR_H__ #endif // __REVISION_NR_H__

View file

@ -407,7 +407,7 @@
<ClCompile Include="..\..\src\game\Guild.cpp" /> <ClCompile Include="..\..\src\game\Guild.cpp" />
<ClCompile Include="..\..\src\game\GuildHandler.cpp" /> <ClCompile Include="..\..\src\game\GuildHandler.cpp" />
<ClCompile Include="..\..\src\game\HomeMovementGenerator.cpp" /> <ClCompile Include="..\..\src\game\HomeMovementGenerator.cpp" />
<ClCompile Include="..\..\src\game\HostilRefManager.cpp" /> <ClCompile Include="..\..\src\game\HostileRefManager.cpp" />
<ClCompile Include="..\..\src\game\IdleMovementGenerator.cpp" /> <ClCompile Include="..\..\src\game\IdleMovementGenerator.cpp" />
<ClCompile Include="..\..\src\game\InstanceData.cpp" /> <ClCompile Include="..\..\src\game\InstanceData.cpp" />
<ClCompile Include="..\..\src\game\InstanceSaveMgr.cpp" /> <ClCompile Include="..\..\src\game\InstanceSaveMgr.cpp" />
@ -454,7 +454,7 @@
<ClCompile Include="..\..\src\game\Player.cpp" /> <ClCompile Include="..\..\src\game\Player.cpp" />
<ClCompile Include="..\..\src\game\PlayerDump.cpp" /> <ClCompile Include="..\..\src\game\PlayerDump.cpp" />
<ClCompile Include="..\..\src\game\PointMovementGenerator.cpp" /> <ClCompile Include="..\..\src\game\PointMovementGenerator.cpp" />
<ClCompile Include="..\..\src\game\PoolHandler.cpp" /> <ClCompile Include="..\..\src\game\PoolManager.cpp" />
<ClCompile Include="..\..\src\game\QueryHandler.cpp" /> <ClCompile Include="..\..\src\game\QueryHandler.cpp" />
<ClCompile Include="..\..\src\game\QuestDef.cpp" /> <ClCompile Include="..\..\src\game\QuestDef.cpp" />
<ClCompile Include="..\..\src\game\QuestHandler.cpp" /> <ClCompile Include="..\..\src\game\QuestHandler.cpp" />
@ -557,7 +557,7 @@
<ClInclude Include="..\..\src\game\GuardAI.h" /> <ClInclude Include="..\..\src\game\GuardAI.h" />
<ClInclude Include="..\..\src\game\Guild.h" /> <ClInclude Include="..\..\src\game\Guild.h" />
<ClInclude Include="..\..\src\game\HomeMovementGenerator.h" /> <ClInclude Include="..\..\src\game\HomeMovementGenerator.h" />
<ClInclude Include="..\..\src\game\HostilRefManager.h" /> <ClInclude Include="..\..\src\game\HostileRefManager.h" />
<ClInclude Include="..\..\src\game\IdleMovementGenerator.h" /> <ClInclude Include="..\..\src\game\IdleMovementGenerator.h" />
<ClInclude Include="..\..\src\game\InstanceData.h" /> <ClInclude Include="..\..\src\game\InstanceData.h" />
<ClInclude Include="..\..\src\game\InstanceSaveMgr.h" /> <ClInclude Include="..\..\src\game\InstanceSaveMgr.h" />
@ -590,7 +590,7 @@
<ClInclude Include="..\..\src\game\Player.h" /> <ClInclude Include="..\..\src\game\Player.h" />
<ClInclude Include="..\..\src\game\PlayerDump.h" /> <ClInclude Include="..\..\src\game\PlayerDump.h" />
<ClInclude Include="..\..\src\game\PointMovementGenerator.h" /> <ClInclude Include="..\..\src\game\PointMovementGenerator.h" />
<ClInclude Include="..\..\src\game\PoolHandler.h" /> <ClInclude Include="..\..\src\game\PoolManager.h" />
<ClInclude Include="..\..\src\game\QuestDef.h" /> <ClInclude Include="..\..\src\game\QuestDef.h" />
<ClInclude Include="..\..\src\game\RandomMovementGenerator.h" /> <ClInclude Include="..\..\src\game\RandomMovementGenerator.h" />
<ClInclude Include="..\..\src\game\ReactorAI.h" /> <ClInclude Include="..\..\src\game\ReactorAI.h" />

View file

@ -878,11 +878,11 @@
> >
</File> </File>
<File <File
RelativePath="..\..\src\game\PoolHandler.cpp" RelativePath="..\..\src\game\PoolManager.cpp"
> >
</File> </File>
<File <File
RelativePath="..\..\src\game\PoolHandler.h" RelativePath="..\..\src\game\PoolManager.h"
> >
</File> </File>
<File <File
@ -1586,11 +1586,11 @@
> >
</File> </File>
<File <File
RelativePath="..\..\src\game\HostilRefManager.cpp" RelativePath="..\..\src\game\HostileRefManager.cpp"
> >
</File> </File>
<File <File
RelativePath="..\..\src\game\HostilRefManager.h" RelativePath="..\..\src\game\HostileRefManager.h"
> >
</File> </File>
<File <File

View file

@ -879,11 +879,11 @@
> >
</File> </File>
<File <File
RelativePath="..\..\src\game\PoolHandler.cpp" RelativePath="..\..\src\game\PoolManager.cpp"
> >
</File> </File>
<File <File
RelativePath="..\..\src\game\PoolHandler.h" RelativePath="..\..\src\game\PoolManager.h"
> >
</File> </File>
<File <File
@ -1587,11 +1587,11 @@
> >
</File> </File>
<File <File
RelativePath="..\..\src\game\HostilRefManager.cpp" RelativePath="..\..\src\game\HostileRefManager.cpp"
> >
</File> </File>
<File <File
RelativePath="..\..\src\game\HostilRefManager.h" RelativePath="..\..\src\game\HostileRefManager.h"
> >
</File> </File>
<File <File