EvEmu
0.8.4
11 September 2021
|
#include "SpawnMgr.h"
Public Member Functions | |
~SpawnMgr () | |
void | SetDungMgr (DungeonMgr *pDmgr) |
void | StopRatTimer () |
void | StopRatGroupTimer () |
bool | IsRatSpawnEnabled () |
bool | IsInitialized () |
bool | IsRatTimerStarted () |
Protected Types | |
typedef std::vector< NPC * > | RatSpawningVec |
typedef std::vector < SystemBubble * > | RatBubbleVec |
typedef std::vector< SpawnGroup > | RatSpawnGroupVec |
typedef std::vector < RatSpawnClass > | RatSpawnClassVec |
typedef std::vector < RatFactionGroups > | RatFactionGroupsVec |
typedef std::map< uint8, uint16 > | RatFactionGroupsMap |
typedef std::multimap< uint16, SpawnEntry > | SpawnEntryDef |
Definition at line 25 of file SpawnMgr.h.
|
protected |
Definition at line 75 of file SpawnMgr.h.
|
protected |
Definition at line 79 of file SpawnMgr.h.
|
protected |
Definition at line 78 of file SpawnMgr.h.
|
protected |
Definition at line 77 of file SpawnMgr.h.
|
protected |
Definition at line 76 of file SpawnMgr.h.
|
protected |
Definition at line 74 of file SpawnMgr.h.
|
protected |
Definition at line 80 of file SpawnMgr.h.
SpawnMgr::SpawnMgr | ( | SystemManager * | mgr, |
PyServiceMgr & | svc | ||
) |
add booleans for checking roam/static spawns and add anomaly checks to enable spawn mgr.
Definition at line 40 of file SpawnMgr.cpp.
References m_bubbles, m_factionGroups, m_initalized, m_ratEnabled, m_ratSpawnClass, m_ratSpawns, m_spawnID, m_spawns, and m_toSpawn.
|
inline |
Definition at line 29 of file SpawnMgr.h.
void SpawnMgr::DoSpawnForAnomaly | ( | SystemBubble * | pBubble, |
uint8 | spawnClass | ||
) |
Definition at line 309 of file SpawnMgr.cpp.
References PrepSpawn(), and SystemBubble::SetAnomaly().
Referenced by DungeonMgr::Create().
bool SpawnMgr::DoSpawnForBubble | ( | SystemBubble * | pBubble | ) |
Definition at line 344 of file SpawnMgr.cpp.
References _log, FindSpawnForBubble(), SystemBubble::GetID(), GetTimeUSeconds(), SystemManager::IncGateSpawnCount(), SystemManager::IncRatSpawnCount(), SystemBubble::IsBelt(), SystemBubble::IsGate(), m_ratEnabled, m_system, PrepSpawn(), sConfig, SystemBubble::SetSpawned(), Profile::spawn, and sProfiler.
Referenced by SystemManager::DoSpawnForBubble().
void SpawnMgr::DoSpawnForIncursion | ( | SystemBubble * | pBubble, |
uint32 | regionID | ||
) |
Definition at line 317 of file SpawnMgr.cpp.
References IsRegionID, and SystemBubble::SetIncursion().
void SpawnMgr::DoSpawnForMission | ( | SystemBubble * | pBubble, |
uint32 | regionID | ||
) |
Definition at line 327 of file SpawnMgr.cpp.
References IsRegionID, and SystemBubble::SetMission().
|
protected |
Definition at line 811 of file SpawnMgr.cpp.
References m_spawns.
Referenced by DoSpawnForBubble().
Definition at line 818 of file SpawnMgr.cpp.
References m_factionGroups, and sDataMgr.
Referenced by PrepSpawn().
std::string SpawnMgr::GetSpawnClassName | ( | int8 | sClass | ) |
Definition at line 952 of file SpawnMgr.cpp.
References Spawn::Class::Annex, Spawn::Class::Assembly, Spawn::Class::Average, Spawn::Class::Base, Spawn::Class::Burrow, Spawn::Class::Center, Spawn::Class::ChemicalYard, Spawn::Class::Cluster, Spawn::Class::Collection, Spawn::Class::Commander, Spawn::Class::Complex, Spawn::Class::Crazy, Spawn::Class::Crumbling, Spawn::Class::Decayed, Spawn::Class::Den, Spawn::Class::DesolateSite, Spawn::Class::DirtySite, Spawn::Class::Easy, Spawn::Class::Fair, Spawn::Class::Fortress, Spawn::Class::Gathering, Spawn::Class::Hard, Spawn::Class::Hauler, Spawn::Class::HauntedYard, Spawn::Class::Haven, Spawn::Class::Herd, Spawn::Class::Hideaway, Spawn::Class::Hideout, Spawn::Class::Hierarchy, Spawn::Class::Horde, Spawn::Class::Hub, Spawn::Class::Independence, Spawn::Class::Insane, Spawn::Class::Lookout, Spawn::Class::Looted, Spawn::Class::Mainframe, Spawn::Class::Medium, Spawn::Class::Menagerie, Spawn::Class::None, Spawn::Class::Officer, Spawn::Class::Outpost, Spawn::Class::Patrol, Spawn::Class::Port, Spawn::Class::Pristine, Spawn::Class::Radiance, Spawn::Class::RallyPoint, Spawn::Class::Ransacked, Spawn::Class::Refuge, Spawn::Class::Ruined, Spawn::Class::Ruins, Spawn::Class::Sanctum, Spawn::Class::Server, Spawn::Class::Shard, Spawn::Class::Squad, Spawn::Class::StagingPoint, Spawn::Class::Surveillance, Spawn::Class::Tower, Spawn::Class::TrialYard, Spawn::Class::Vigil, Spawn::Class::Watch, and Spawn::Class::Yard.
Referenced by MakeSpawn(), and PrepSpawn().
Definition at line 858 of file SpawnMgr.cpp.
References Spawn::Class::Annex, Spawn::Group::Anomaly, Spawn::Class::Assembly, Spawn::Class::Average, Spawn::Class::Base, Spawn::Class::Burrow, Spawn::Class::Center, Spawn::Class::ChemicalYard, Spawn::Class::Cluster, Spawn::Class::Collection, Spawn::Group::Combat, Spawn::Class::Commander, Spawn::Class::Complex, Spawn::Class::Crazy, Spawn::Class::Crumbling, Spawn::Group::Deadspace, Spawn::Class::Decayed, Spawn::Class::Den, Spawn::Class::DesolateSite, Spawn::Class::DirtySite, Spawn::Class::Easy, Spawn::Class::Extra, Spawn::Class::Fair, Spawn::Class::Fortress, Spawn::Class::Gathering, Spawn::Class::Hard, Spawn::Class::Hauler, Spawn::Class::HauntedYard, Spawn::Class::Haven, Spawn::Class::Hell, Spawn::Class::Herd, Spawn::Class::Hideaway, Spawn::Class::Hideout, Spawn::Class::Hierarchy, Spawn::Class::Horde, Spawn::Class::Hub, Spawn::Class::Independence, Spawn::Class::Insane, Spawn::Class::Lookout, Spawn::Class::Looted, Spawn::Class::Mainframe, Spawn::Class::Medium, Spawn::Class::Menagerie, Spawn::Class::None, Spawn::Group::None, Spawn::Class::Officer, Spawn::Class::Outpost, Spawn::Class::Patrol, Spawn::Class::Port, Spawn::Class::Pristine, Spawn::Class::Radiance, Spawn::Class::RallyPoint, Spawn::Class::Ransacked, Spawn::Class::Refuge, Spawn::Group::Roaming, Spawn::Class::Ruined, Spawn::Class::Ruins, Spawn::Class::Sanctum, Spawn::Class::Server, Spawn::Class::Shard, Spawn::Class::Squad, Spawn::Class::StagingPoint, Spawn::Class::Surveillance, Spawn::Class::Tower, Spawn::Class::TrialYard, Spawn::Class::Vigil, Spawn::Class::Watch, and Spawn::Class::Yard.
Referenced by MakeSpawn().
std::string SpawnMgr::GetSpawnGroupName | ( | int8 | sGroup | ) |
Definition at line 934 of file SpawnMgr.cpp.
References Spawn::Group::Anomaly, Spawn::Group::Combat, Spawn::Group::Deadspace, Spawn::Group::Escalation, Spawn::Group::Incursion, Spawn::Group::Mission, Spawn::Group::None, Spawn::Group::Roaming, Spawn::Group::Sleeper, and Spawn::Group::Static.
Referenced by MakeSpawn().
bool SpawnMgr::Init | ( | ) |
Definition at line 62 of file SpawnMgr.cpp.
References _log, SystemManager::BeltCount(), SystemManager::GetID(), SystemManager::GetName(), m_groupTimerSetTime, m_initalized, m_ratEnabled, m_system, and sConfig.
Referenced by SystemManager::LoadCosmicMgrs().
bool SpawnMgr::IsChaining | ( | uint16 | bubbleID | ) |
Definition at line 827 of file SpawnMgr.cpp.
References m_spawns.
Referenced by NPCAIMgr::Process().
|
inline |
Definition at line 59 of file SpawnMgr.h.
References m_initalized.
Referenced by SystemManager::DoSpawnForBubble().
|
inline |
|
inline |
Definition at line 60 of file SpawnMgr.h.
References Timer::Enabled(), and m_ratTimer.
|
protected |
Definition at line 655 of file SpawnMgr.cpp.
References _log, SystemManager::AddNPC(), FactionData::allianceID, SpawnEntry::corpID, FactionData::corporationID, SpawnEntry::enabled, SpawnEntry::factionID, FactionData::factionID, factionRogueDrones, flagNone, RefPtr< X >::get(), SystemBubble::GetCenter(), SystemManager::GetID(), SystemBubble::GetID(), SystemManager::GetName(), GetSpawnClassName(), GetSpawnGroup(), GetSpawnGroupName(), ItemType::groupID(), SpawnEntry::groupID, InventoryItem::itemID(), SpawnEntry::itemID, SpawnEntry::level, m_bubbles, m_ratSpawns, m_services, m_spawnID, m_spawns, m_system, m_toSpawn, MakeRandomInt(), GPoint::MakeRandomPointOnSphere(), Dungeon::Event::Msg::NPC, SpawnEntry::number, Spawn::Class::Officer, FactionData::ownerID, sDataMgr, sEntityList, sItemFactory, SpawnEntry::spawnClass, SpawnEntry::spawnGroup, SpawnEntry::spawnID, SpawnEntry::stamp, SpawnEntry::total, InventoryItem::type(), and SpawnEntry::typeID.
Referenced by PrepSpawn(), and SpawnKilled().
void SpawnMgr::MoveSpawn | ( | NPC * | pNPC, |
SystemBubble * | pBubble | ||
) |
Definition at line 141 of file SpawnMgr.cpp.
References _log, SystemBubble::CountNPCs(), SystemBubble::GetID(), SystemEntity::GetID(), SystemEntity::GetName(), m_spawns, SystemBubble::SetSpawned(), and SystemEntity::SysBubble().
Referenced by NPCAIMgr::WarpOut().
|
protected |
Definition at line 376 of file SpawnMgr.cpp.
References _log, Spawn::Class::Average, Spawn::Class::BeltSpawn, Spawn::Class::Commander, Spawn::Class::Crazy, Spawn::Class::Easy, factionRogueDrones, Spawn::Class::Fair, GetRandTypeID(), SystemManager::GetRegionID(), SystemManager::GetSecValue(), GetSpawnClassName(), Spawn::Class::Hard, Spawn::Class::Hauler, Spawn::Class::Hell, Spawn::Class::Insane, is_log_enabled, SystemBubble::IsBelt(), SystemBubble::IsGate(), m_factionGroups, m_system, m_toSpawn, MakeRandomFloat(), MakeRandomInt(), MakeSpawn(), Spawn::Class::Medium, Spawn::Class::None, Spawn::Class::Officer, SpawnGroup::quantity, sConfig, sDataMgr, and SpawnGroup::typeID.
Referenced by DoSpawnForAnomaly(), and DoSpawnForBubble().
void SpawnMgr::Process | ( | ) |
Definition at line 85 of file SpawnMgr.cpp.
References _log, Timer::Check(), Timer::Disable(), Timer::Enabled(), SystemManager::GetID(), SystemManager::GetName(), GetTimeUSeconds(), m_initalized, m_ratEnabled, m_ratGroupTimer, m_spawns, m_system, ReSpawn(), sBubbleMgr, sConfig, sEntityList, Profile::spawn, and sProfiler.
Referenced by SystemManager::ProcessTic().
Definition at line 841 of file SpawnMgr.cpp.
References _log, and m_spawns.
Referenced by SpawnKilled().
|
protected |
Definition at line 763 of file SpawnMgr.cpp.
References _log, SystemManager::AddNPC(), SpawnEntry::corpID, SystemEntity::DestinyMgr(), SpawnEntry::enabled, SpawnEntry::factionID, flagNone, SystemBubble::GetCenter(), SystemManager::GetID(), SystemBubble::GetID(), SystemEntity::GetID(), SystemEntity::GetSelf(), Spawn::Class::Insane, NPC::Load(), m_services, m_system, MakeRandomInt(), Dungeon::Event::Msg::NPC, SpawnEntry::number, SafeDelete(), sItemFactory, SpawnEntry::spawnClass, SpawnEntry::spawnID, SpawnEntry::stamp, SpawnEntry::total, InventoryItem::typeID(), SpawnEntry::typeID, and DestinyManager::WarpTo().
Referenced by Process().
|
inline |
Definition at line 34 of file SpawnMgr.h.
References m_dungMgr.
Referenced by DungeonMgr::Init().
void SpawnMgr::SpawnKilled | ( | SystemBubble * | pBubble, |
uint32 | itemID | ||
) |
Definition at line 229 of file SpawnMgr.cpp.
References _log, SystemBubble::CountNPCs(), SystemBubble::GetID(), SystemBubble::IsAnomaly(), SystemBubble::IsBelt(), SystemBubble::IsGate(), SystemBubble::IsIncursion(), SystemBubble::IsMission(), itemID(), m_bubbles, m_spawns, m_system, MakeSpawn(), RemoveSpawn(), SystemManager::RemoveSpawnBubble(), SystemBubble::ResetBubbleRatSpawn(), sConfig, sEntityList, SystemBubble::SetSpawned(), and StartRatGroupTimer().
Referenced by NPC::Killed().
void SpawnMgr::StartRatGroupTimer | ( | ) |
Definition at line 215 of file SpawnMgr.cpp.
References _log, Timer::Enabled(), SystemManager::GetID(), SystemManager::GetName(), Timer::GetRemainingTime(), is_log_enabled, m_groupTimerSetTime, m_ratGroupTimer, m_system, and Timer::Start().
Referenced by SpawnKilled().
void SpawnMgr::StartRatTimer | ( | ) |
Definition at line 201 of file SpawnMgr.cpp.
References _log, Timer::Enabled(), SystemManager::GetID(), SystemManager::GetName(), is_log_enabled, m_ratTimer, m_system, sConfig, and Timer::Start().
|
inline |
Definition at line 56 of file SpawnMgr.h.
References Timer::Disable(), and m_ratGroupTimer.
|
inline |
Definition at line 54 of file SpawnMgr.h.
References Timer::Disable(), and m_ratTimer.
void SpawnMgr::WarpOutSpawn | ( | NPC * | pNPC, |
SystemBubble * | pBubble | ||
) |
Definition at line 169 of file SpawnMgr.cpp.
References _log, SystemEntity::DestinyMgr(), SystemBubble::GetCenter(), SystemBubble::GetID(), SystemEntity::GetID(), SystemEntity::GetName(), SystemManager::GetNPCSE(), m_spawns, m_system, MakeRandomFloat(), SystemBubble::SetSpawned(), SystemEntity::SysBubble(), and DestinyManager::WarpTo().
|
private |
Definition at line 101 of file SpawnMgr.h.
Referenced by MakeSpawn(), SpawnKilled(), and SpawnMgr().
|
private |
Definition at line 92 of file SpawnMgr.h.
|
private |
Definition at line 86 of file SpawnMgr.h.
Referenced by SetDungMgr().
|
private |
Definition at line 107 of file SpawnMgr.h.
Referenced by GetRandTypeID(), PrepSpawn(), and SpawnMgr().
|
private |
Definition at line 97 of file SpawnMgr.h.
Referenced by Init(), and StartRatGroupTimer().
|
private |
Definition at line 91 of file SpawnMgr.h.
|
private |
Definition at line 95 of file SpawnMgr.h.
Referenced by Init(), IsInitialized(), Process(), and SpawnMgr().
|
private |
Definition at line 90 of file SpawnMgr.h.
|
private |
Definition at line 94 of file SpawnMgr.h.
Referenced by DoSpawnForBubble(), Init(), IsRatSpawnEnabled(), Process(), and SpawnMgr().
|
private |
Definition at line 89 of file SpawnMgr.h.
Referenced by Process(), StartRatGroupTimer(), and StopRatGroupTimer().
|
private |
Definition at line 105 of file SpawnMgr.h.
Referenced by SpawnMgr().
|
private |
Definition at line 103 of file SpawnMgr.h.
Referenced by MakeSpawn(), and SpawnMgr().
|
private |
Definition at line 88 of file SpawnMgr.h.
Referenced by IsRatTimerStarted(), StartRatTimer(), and StopRatTimer().
|
private |
Definition at line 85 of file SpawnMgr.h.
Referenced by MakeSpawn(), and ReSpawn().
|
private |
Definition at line 99 of file SpawnMgr.h.
Referenced by MakeSpawn(), and SpawnMgr().
|
private |
Definition at line 102 of file SpawnMgr.h.
Referenced by FindSpawnForBubble(), IsChaining(), MakeSpawn(), MoveSpawn(), Process(), RemoveSpawn(), SpawnKilled(), SpawnMgr(), and WarpOutSpawn().
|
private |
Definition at line 84 of file SpawnMgr.h.
Referenced by DoSpawnForBubble(), Init(), MakeSpawn(), PrepSpawn(), Process(), ReSpawn(), SpawnKilled(), StartRatGroupTimer(), StartRatTimer(), and WarpOutSpawn().
|
private |
Definition at line 104 of file SpawnMgr.h.
Referenced by MakeSpawn(), PrepSpawn(), and SpawnMgr().