|
Project SkyFire Core
SkyFire 5.4.8 server core API documentation
|
#include <LFGMgr.h>
Public Member Functions | |
| void | _LoadFromDB (Field *fields, uint64 guid) |
| Load Lfg group info from DB. | |
| void | AddPlayerToGroup (uint64 gguid, uint64 guid) |
| Adds player to group. | |
| uint32 | AddProposal (LfgProposal &proposal) |
| Add a new Proposal. | |
| bool | AllQueued (LfgGuidList const &check) |
| Checks if all players are queued. | |
| void | Clean () |
| Clears queue - Only for internal testing. | |
| void | ClearDungeonGroupState (uint64 guid, uint32 dbGuid, char const *debugMsg, bool sendUpdate) |
| Clears active dungeon finder state for an LFG dungeon group. | |
| std::string | DumpGroupInfo (uint64 guid) |
| Dumps queue-scoped group state - Only for internal testing. | |
| std::string | DumpPlayerInfo (uint64 guid) |
| Dumps queue-scoped player state - Only for internal testing. | |
| std::string | DumpQueueInfo (bool full=false) |
| Dumps the state of the queue - Only for internal testing. | |
| void | FinishDungeon (uint64 gguid, uint32 dungeonId) |
| Finish the dungeon for the given group. All check are performed using internal lfg data. | |
| uint8 | GetActiveQueueId (uint64 guid) |
| Get active LFG queue id. | |
| std::string const & | GetComment (uint64 gguid) |
| Get current player comment (used for LFR). | |
| uint32 | GetDungeon (uint64 guid, bool asId=true) |
| Get current dungeon. | |
| uint32 | GetDungeonMapId (uint64 guid) |
| Get the map id of the current dungeon. | |
| uint64 | GetGroup (uint64 guid) |
| Gets player group. | |
| uint8 | GetKicksLeft (uint64 gguid) |
| Get kicks left in current group. | |
| uint64 | GetLeader (uint64 guid) |
| Get leader of the group (using internal data). | |
| uint8 | GetLFGDungeonCategory (uint32 id) |
| Return Lfg dungeon category for given dungeon id. | |
| uint32 | GetLFGDungeonEntry (uint32 id) |
| Return Lfg dungeon entry for given dungeon id. | |
| LfgUpdateData | GetLfgStatus (uint64 guid) |
| Returns current lfg status. | |
| LfgLockMap const | GetLockedDungeons (uint64 guid) |
| Get locked dungeons. | |
| LfgState | GetOldState (uint64 guid) |
| Get last lfg state (NONE, DUNGEON or FINISHED_DUNGEON). | |
| uint32 | GetOptions () |
| Gets current lfg options. | |
| uint8 | GetPlayerCount (uint64 guid) |
| Gets the player count of given group. | |
| uint8 | GetQueueId (uint64 guid) |
| Returns queue id. | |
| time_t | GetQueueJoinTime (uint64 guid) |
| Gets queue join time. | |
| LfgDungeonSet | GetRandomAndSeasonalDungeons (uint8 level, uint8 expansion) |
| Returns all random and seasonal dungeons for given level and expansion. | |
| LfgReward const * | GetRandomDungeonReward (uint32 dungeon, uint8 level) |
| Gets the random dungeon reward corresponding to given dungeon and player level. | |
| uint8 | GetRoles (uint64 guid) |
| Get current player roles. | |
| LfgDungeonSet const & | GetSelectedDungeons (uint64 guid) |
| Get selected dungeons. | |
| LfgState | GetState (uint64 guid) |
| Get current lfg state. | |
| void | InitBoot (uint64 gguid, uint64 kguid, uint64 vguid, std::string const &reason) |
| Inits new proposal to boot a player. | |
| bool | inLfgDungeonMap (uint64 guid, uint32 map, DifficultyID difficulty) |
| Check if given guid applied for given map and difficulty. Used to know. | |
| bool | IsDebugFlexRaidMinimumOverrideEnabled () const |
| Gets the server-wide debug override for flexible raid minimum group size. | |
| bool | IsDebugRequirementOverrideEnabled () const |
| Gets the server-wide debug override for dungeon and raid finder requirements. | |
| bool | IsFlexibleRaidDungeon (uint32 dungeonId) |
| Check whether the dungeon id belongs to a flexible raid queue entry. | |
| bool | IsLfgGroup (uint64 guid) |
| Check if given group guid is lfg. | |
| bool | isOptionEnabled (uint32 option) |
| Checks if given lfg option is enabled. | |
| bool | IsRaidFinderDungeon (uint32 dungeonId) |
| Check whether the dungeon id belongs to a Raid Finder queue entry. | |
| bool | IsSeasonActive (uint32 dungeonId) |
| Checks if Seasonal dungeon is active. | |
| bool | IsVoteKickActive (uint64 gguid) |
| Get current vote kick state. | |
| void | JoinLfg (Player *player, uint8 roles, LfgDungeonSet &dungeons, std::string const &comment) |
| Join Lfg with selected roles, dungeons and comment. | |
| void | LeaveLfg (uint64 guid, bool disconnected=false) |
| Leaves lfg. | |
| void | LeaveSoloLfg (uint64 guid, uint32 queueID, bool disconnected=false) |
| Leaves Solo lfg. | |
| void | LoadLFGDungeons (bool reload=false) |
| Loads dungeons from dbc and adds teleport coords. | |
| void | LoadRewards () |
| Loads rewards for random dungeons. | |
| void | RemoveGroupData (uint64 guid) |
| Removes saved group data. | |
| uint8 | RemovePlayerFromGroup (uint64 gguid, uint64 guid) |
| Removes a player from a group. | |
| bool | RestoreActiveQueue (uint64 guid) |
| Restores the active queue id from saved queue data. | |
| bool | selectedRandomLfgDungeon (uint64 guid) |
| Check if given guid applied for random dungeon. | |
| bool | SendActiveProposal (uint64 guid) |
| Resends an active dungeon proposal to a player if one exists. | |
| void | SetComment (uint64 guid, std::string const &comment) |
| Sets player lfr comment. | |
| void | SetDebugFlexRaidMinimumOverride (bool enabled) |
| Sets the server-wide debug override for flexible raid minimum group size. | |
| void | SetDebugRequirementOverride (bool enabled) |
| Sets the server-wide debug override for dungeon and raid finder requirements. | |
| void | SetGroup (uint64 guid, uint64 group) |
| Sets player group. | |
| void | SetLeader (uint64 gguid, uint64 leader) |
| Sets the leader of the group. | |
| void | SetOptions (uint32 options) |
| Sets new lfg options. | |
| void | SetRoles (uint64 guid, uint8 roles) |
| Sets player lfg roles. | |
| void | SetTeam (uint64 guid, uint8 team) |
| Sets player team. | |
| void | SetupGroupMember (uint64 guid, uint64 gguid) |
| Initializes player data after loading group data from DB. | |
| void | TeleportDungeonGroupOut (Group *group) |
| Teleport online members of an LFG dungeon group back to their saved entry points. | |
| void | TeleportPlayer (Player *player, bool out, bool fromOpcode=false, bool forceChangeInstance=false) |
| Teleport a player to/from selected dungeon. | |
| void | Update (uint32 diff) |
| void | UpdateBoot (uint64 guid, bool accept) |
| Updates player boot proposal with new player answer. | |
| void | UpdateProposal (uint32 proposalId, uint64 guid, bool accept) |
| Updates proposal to join dungeon with player answer. | |
| void | UpdateRoleCheck (uint64 gguid, uint64 guid=0, uint8 roles=PLAYER_ROLE_NONE) |
| Updates the role check with player answer. | |
Static Public Member Functions | |
| static bool | CheckDpsOnlyRoles (LfgRolesMap &groles, uint8 neededDamage) |
| Assigns queued players to damage roles for role-neutral scenario queues. | |
| static bool | CheckFlexibleRaidRoles (LfgRolesMap &groles, uint8 maxPlayers) |
| Assigns queued players to their preferred combat role for flexible raid queues. | |
| static bool | CheckGroupRoles (LfgRolesMap &groles) |
| Checks if given roles match, modifies given roles map with new roles. | |
| static bool | HasIgnore (uint64 guid1, uint64 guid2) |
| Checks if given players are ignoring each other. | |
| static void | SendLfgQueueStatus (uint64 guid, LfgQueueStatusData const &data) |
| Sends queue status to player. | |
Private Member Functions | |
| void | _SaveToDB (uint64 guid, uint32 db_guid) |
| void | ClearGroupQueueState (uint64 guid, char const *debugMsg, bool sendUpdate) |
| void | ClearQueueState (uint64 guid, char const *debugMsg) |
| void | ClearState (uint64 guid, char const *debugMsg) |
| void | DecreaseKicksLeft (uint64 guid) |
| void | GetCompatibleDungeons (LfgDungeonSet &dungeons, LfgGuidSet const &players, LfgLockPartyMap &lockMap, bool isContinue) |
| LfgDungeonSet const & | GetDungeonsByRandom (uint32 randomdungeon) |
| LfgType | GetDungeonType (uint32 dungeon) |
| LFGDungeonData const * | GetLFGDungeon (uint32 id) |
| LfgGuidSet const & | GetPlayers (uint64 guid) |
| LFGQueue & | GetQueue (uint64 guid) |
| uint8 | GetTeam (uint64 guid) |
| LFGMgr () | |
| bool | MakeNewGroup (LfgProposal const &proposal) |
| void | RemovePlayerData (uint64 guid) |
| void | RemoveProposal (LfgProposalContainer::iterator itProposal, LfgUpdateType type) |
| void | RestoreOrClearState (uint64 guid, char const *debugMsg) |
| void | RestoreState (uint64 guid, char const *debugMsg) |
| void | SendLfgBootProposalUpdate (uint64 guid, LfgPlayerBoot const &boot) |
| void | SendLfgJoinResult (uint64 guid, LfgJoinResultData const &data) |
| void | SendLfgRoleCheckUpdate (uint64 guid, LfgRoleCheck const &roleCheck) |
| void | SendLfgRoleChosen (uint64 guid, uint64 pguid, uint8 roles) |
| void | SendLfgUpdateProposal (uint64 guid, LfgProposal const &proposal) |
| void | SendLfgUpdateStatus (uint64 guid, LfgUpdateData const &data, bool party) |
| void | SetActiveQueueId (uint64 guid, uint8 queueId) |
| void | SetDungeon (uint64 guid, uint32 dungeon) |
| void | SetSelectedDungeons (uint64 guid, LfgDungeonSet const &dungeons) |
| void | SetState (uint64 guid, LfgState state) |
| void | SetVoteKick (uint64 guid, bool active) |
| ~LFGMgr () | |
Private Attributes | |
| LfgPlayerBootContainer | BootsStore |
| Current player kicks. | |
| LfgCachedDungeonContainer | CachedDungeonMapStore |
| Stores all dungeons by groupType. | |
| LfgGroupDataContainer | GroupsStore |
| Group data. | |
| LFGDungeonContainer | LfgDungeonStore |
| bool | m_debugFlexRaidMinimumOverride |
| allows flexible raid queues to form below normal minimum for debugging | |
| bool | m_debugRequirementOverride |
| bypasses LFG entry requirements for server-wide debugging | |
| uint32 | m_lfgProposalId |
| used as internal counter for proposals | |
| uint32 | m_options |
| Stores config options. | |
| uint32 | m_QueueTimer |
| used to check interval of update | |
| LfgPlayerDataContainer | PlayersStore |
| Player data. | |
| LfgProposalContainer | ProposalsStore |
| Current Proposals. | |
| LfgQueueContainer | QueuesStore |
| Queues. | |
| LfgRewardContainer | RewardMapStore |
| Stores rewards for random dungeons. | |
| LfgRoleCheckContainer | RoleChecksStore |
| Current Role checks. | |
Friends | |
| class | Skyfire::Singleton< LFGMgr, Skyfire::NullMutex > |
|
private |
Definition at line 158 of file LFGMgr.cpp.
References m_debugFlexRaidMinimumOverride, m_debugRequirementOverride, m_lfgProposalId, m_options, m_QueueTimer, and sWorld.
|
private |
Definition at line 167 of file LFGMgr.cpp.
References RewardMapStore.
Load Lfg group info from DB.
Definition at line 173 of file LFGMgr.cpp.
References Field::GetUInt32(), Field::GetUInt8(), HIGHGUID_PLAYER, IS_GROUP_GUID(), lfg::LFG_STATE_DUNGEON, lfg::LFG_STATE_FINISHED_DUNGEON, MAKE_NEW_GUID(), SetDungeon(), SetLeader(), and SetState().
Definition at line 203 of file LFGMgr.cpp.
References CHAR_DEL_LFG_DATA, CHAR_INS_LFG_DATA, CharacterDatabase, GetDungeon(), GetState(), IS_GROUP_GUID(), and PreparedStatement::setUInt32().
Referenced by MakeNewGroup().
Adds player to group.
Definition at line 2485 of file LFGMgr.cpp.
References GroupsStore.
Referenced by SetupGroupMember().
| uint32 lfg::LFGMgr::AddProposal | ( | LfgProposal & | proposal | ) |
Add a new Proposal.
Definition at line 1294 of file LFGMgr.cpp.
References lfg::LfgProposal::id, m_lfgProposalId, and ProposalsStore.
| bool lfg::LFGMgr::AllQueued | ( | LfgGuidList const & | check | ) |
Checks if all players are queued.
Definition at line 2611 of file LFGMgr.cpp.
References GetState(), lfg::GetStateString(), GUID_LOPART(), lfg::LFG_STATE_PROPOSAL, lfg::LFG_STATE_QUEUED, and SF_LOG_DEBUG.
|
static |
Assigns queued players to damage roles for role-neutral scenario queues.
Definition at line 1114 of file LFGMgr.cpp.
References lfg::PLAYER_ROLE_DAMAGE, and lfg::PLAYER_ROLE_LEADER.
Referenced by UpdateRoleCheck().
|
static |
Assigns queued players to their preferred combat role for flexible raid queues.
Definition at line 1125 of file LFGMgr.cpp.
References lfg::PLAYER_ROLE_DAMAGE, lfg::PLAYER_ROLE_HEALER, lfg::PLAYER_ROLE_LEADER, and lfg::PLAYER_ROLE_TANK.
Referenced by UpdateRoleCheck().
|
static |
Checks if given roles match, modifies given roles map with new roles.
Check if a group can be formed with the given group roles
| [in] | groles | Map of roles to check |
Definition at line 1073 of file LFGMgr.cpp.
References MAXGROUPSIZE, lfg::PLAYER_ROLE_LEADER, and lfg::PLAYER_ROLE_NONE.
Referenced by UpdateRoleCheck().
| void lfg::LFGMgr::Clean | ( | ) |
Clears queue - Only for internal testing.
Definition at line 2649 of file LFGMgr.cpp.
References BootsStore, GroupsStore, PlayersStore, ProposalsStore, QueuesStore, RoleChecksStore, and SF_LOG_INFO.
| void lfg::LFGMgr::ClearDungeonGroupState | ( | uint64 | guid, |
| uint32 | dbGuid, | ||
| char const * | debugMsg, | ||
| bool | sendUpdate ) |
Clears active dungeon finder state for an LFG dungeon group.
Definition at line 2354 of file LFGMgr.cpp.
References CHAR_DEL_LFG_DATA, CharacterDatabase, ClearGroupQueueState(), and PreparedStatement::setUInt32().
|
private |
Definition at line 2318 of file LFGMgr.cpp.
References BootsStore, ClearQueueState(), ObjectAccessor::FindPlayer(), GroupsStore, IS_GROUP_GUID(), lfg::LFG_UPDATETYPE_REMOVED_FROM_QUEUE, RoleChecksStore, SendLfgUpdateStatus(), and SetGroup().
Referenced by ClearDungeonGroupState(), and LeaveLfg().
|
private |
Definition at line 2305 of file LFGMgr.cpp.
References GUID_LOPART(), lfg::LFG_STATE_NONE, QueuesStore, RestoreActiveQueue(), SetState(), and SF_LOG_TRACE.
Referenced by ClearGroupQueueState(), ClearState(), GetLfgStatus(), LeaveLfg(), LeaveSoloLfg(), RemoveGroupData(), and RestoreOrClearState().
|
private |
Definition at line 2300 of file LFGMgr.cpp.
References ClearQueueState().
|
private |
Definition at line 2404 of file LFGMgr.cpp.
References GetKicksLeft(), GroupsStore, GUID_LOPART(), and SF_LOG_TRACE.
Referenced by UpdateBoot().
| std::string lfg::LFGMgr::DumpGroupInfo | ( | uint64 | guid | ) |
Dumps queue-scoped group state - Only for internal testing.
Definition at line 2903 of file LFGMgr.cpp.
References lfg::LfgGroupData::GetActiveQueueId(), lfg::LfgGroupData::GetDungeon(), lfg::LfgGroupData::GetKicksLeft(), lfg::LfgGroupData::GetLeader(), lfg::LfgGroupData::GetOldState(), lfg::LfgGroupData::GetPlayers(), lfg::LfgGroupData::GetQueues(), lfg::LfgGroupData::GetState(), lfg::GetStateString(), GroupsStore, lfg::LfgGroupData::IsLfgGroup(), lfg::LfgGroupData::IsVoteKickActive(), and QueuesStore.
| std::string lfg::LFGMgr::DumpPlayerInfo | ( | uint64 | guid | ) |
Dumps queue-scoped player state - Only for internal testing.
Definition at line 2850 of file LFGMgr.cpp.
References lfg::ConcatenateDungeons(), lfg::LfgPlayerData::GetActiveQueueId(), lfg::LfgPlayerData::GetComment(), lfg::LfgPlayerData::GetGroup(), GetLockedDungeons(), lfg::LfgPlayerData::GetOldState(), lfg::LfgPlayerData::GetQueues(), lfg::LfgPlayerData::GetRoles(), lfg::GetRolesString(), lfg::LfgPlayerData::GetSelectedDungeons(), lfg::LfgPlayerData::GetState(), lfg::GetStateString(), GUID_LOPART(), PlayersStore, QueuesStore, and sGroupMgr.
| std::string lfg::LFGMgr::DumpQueueInfo | ( | bool | full = false | ) |
Dumps the state of the queue - Only for internal testing.
Definition at line 2789 of file LFGMgr.cpp.
References lfg::LfgProposalPlayer::accept, BootsStore, lfg::LfgProposal::cancelTime, lfg::LfgRoleCheck::cancelTime, lfg::ConcatenateDungeons(), lfg::ConcatenateGuids(), lfg::LfgProposal::dungeonId, lfg::LfgRoleCheck::dungeons, lfg::GetRolesString(), lfg::LfgProposal::group, lfg::LfgProposalPlayer::group, lfg::LfgProposal::leader, lfg::LfgRoleCheck::leader, lfg::LfgProposal::players, ProposalsStore, lfg::LfgProposal::queues, QueuesStore, lfg::LfgRoleCheck::rDungeonId, lfg::LfgProposalPlayer::role, RoleChecksStore, lfg::LfgRoleCheck::roles, lfg::LfgProposal::state, and lfg::LfgRoleCheck::state.
Finish the dungeon for the given group. All check are performed using internal lfg data.
Finish a dungeon and give reward, if any.
| [in] | guid | Group guid |
| [in] | dungeonId | Dungeonid |
Definition at line 1903 of file LFGMgr.cpp.
References ACHIEVEMENT_CRITERIA_TYPE_USE_LFD_TO_GROUP_WITH_PLAYERS, Player::CanRewardQuest(), lfg::LFGDungeonData::difficulty, DIFFICULTY_HEROIC, lfg::LFGDungeonData::Entry(), ObjectAccessor::FindPlayer(), lfg::LfgReward::firstQuest, GetDungeon(), Unit::getLevel(), GetLFGDungeon(), WorldLocation::GetMapId(), GetPlayers(), GetRandomDungeonReward(), GetSelectedDungeons(), Player::GetSession(), GetState(), GUID_LOPART(), Object::IsInWorld(), lfg::LFG_STATE_FINISHED_DUNGEON, lfg::LFG_TYPE_RANDOM, lfg::LFGDungeonData::map, lfg::LfgReward::otherQuest, Player::RewardQuest(), lfg::LFGDungeonData::seasonal, WorldSession::SendLfgPlayerReward(), SetState(), SF_LOG_DEBUG, sObjectMgr, lfg::LFGDungeonData::type, and Player::UpdateAchievementCriteria().
Get active LFG queue id.
Definition at line 2119 of file LFGMgr.cpp.
References GroupsStore, GUID_LOPART(), IS_GROUP_GUID(), PlayersStore, and SF_LOG_TRACE.
Referenced by MakeNewGroup(), and SetupGroupMember().
| const std::string & lfg::LFGMgr::GetComment | ( | uint64 | gguid | ) |
Get current player comment (used for LFR).
Definition at line 2150 of file LFGMgr.cpp.
References GetComment(), GUID_LOPART(), PlayersStore, and SF_LOG_TRACE.
Referenced by GetComment(), RemoveProposal(), Update(), and UpdateRoleCheck().
|
private |
Given a list of dungeons remove the dungeons players have restrictions.
| [in,out] | dungeons | Dungeons to check restrictions |
| [in] | players | Set of players to check their dungeon restrictions |
| [out] | lockMap | Map of players Lock status info of given dungeons (Empty if dungeons is not empty) |
Definition at line 1021 of file LFGMgr.cpp.
References ASSERT, lfg::LFGDungeonData::difficulty, ObjectAccessor::FindPlayer(), Player::GetBoundInstance(), GetLFGDungeon(), GetLockedDungeons(), lfg::LFG_LOCKSTATUS_RAID_LOCKED, and lfg::LFGDungeonData::map.
Referenced by JoinLfg().
Get current dungeon.
Definition at line 2093 of file LFGMgr.cpp.
References GroupsStore, GUID_LOPART(), and SF_LOG_TRACE.
Referenced by _SaveToDB(), FinishDungeon(), GetLfgStatus(), inLfgDungeonMap(), JoinLfg(), SetupGroupMember(), TeleportDungeonGroupOut(), and TeleportPlayer().
Get the map id of the current dungeon.
Definition at line 2100 of file LFGMgr.cpp.
References GetLFGDungeon(), GroupsStore, GUID_LOPART(), and SF_LOG_TRACE.
|
private |
Get the dungeon list that can be done given a random dungeon entry.
| [in] | randomdungeon | Random dungeon id (if value = 0 will return all dungeons) |
Definition at line 2005 of file LFGMgr.cpp.
References CachedDungeonMapStore, GetLFGDungeon(), and lfg::LFGDungeonData::group.
Referenced by GetLockedDungeons(), and JoinLfg().
Given a Dungeon id returns the dungeon Type
| [in] | dungeon | dungeon id |
Definition at line 2040 of file LFGMgr.cpp.
References GetLFGDungeon(), lfg::LFG_TYPE_NONE, and lfg::LFGDungeonData::type.
Referenced by JoinLfg().
Gets player group.
Definition at line 2503 of file LFGMgr.cpp.
References PlayersStore.
Referenced by GetLfgStatus(), GetQueueJoinTime(), inLfgDungeonMap(), LeaveLfg(), MakeNewGroup(), Update(), UpdateBoot(), and UpdateProposal().
Get kicks left in current group.
Definition at line 2244 of file LFGMgr.cpp.
References GroupsStore, GUID_LOPART(), and SF_LOG_TRACE.
Referenced by DecreaseKicksLeft().
Get leader of the group (using internal data).
Definition at line 2523 of file LFGMgr.cpp.
References GroupsStore.
Referenced by LeaveLfg().
|
private |
Definition at line 283 of file LFGMgr.cpp.
References LfgDungeonStore.
Referenced by FinishDungeon(), GetCompatibleDungeons(), GetDungeonMapId(), GetDungeonsByRandom(), GetDungeonType(), GetLFGDungeonCategory(), GetLFGDungeonEntry(), GetLockedDungeons(), inLfgDungeonMap(), IsFlexibleRaidDungeon(), IsRaidFinderDungeon(), MakeNewGroup(), selectedRandomLfgDungeon(), TeleportDungeonGroupOut(), TeleportPlayer(), UpdateProposal(), and UpdateRoleCheck().
Return Lfg dungeon category for given dungeon id.
Definition at line 3015 of file LFGMgr.cpp.
References GetLFGDungeon().
Return Lfg dungeon entry for given dungeon id.
Definition at line 3006 of file LFGMgr.cpp.
References GetLFGDungeon().
Referenced by LoadRewards().
| LfgUpdateData lfg::LFGMgr::GetLfgStatus | ( | uint64 | guid | ) |
Returns current lfg status.
Definition at line 2678 of file LFGMgr.cpp.
References ClearQueueState(), GetDungeon(), GetGroup(), lfg::LfgPlayerData::GetSelectedDungeons(), GetState(), lfg::LfgPlayerData::GetState(), GUID_LOPART(), lfg::LFG_STATE_NONE, lfg::LFG_UPDATETYPE_REMOVED_FROM_QUEUE, lfg::LFG_UPDATETYPE_UPDATE_STATUS, PlayersStore, RestoreActiveQueue(), SetGroup(), SF_LOG_DEBUG, and sGroupMgr.
| LfgLockMap const lfg::LFGMgr::GetLockedDungeons | ( | uint64 | guid | ) |
Get locked dungeons.
Definition at line 2162 of file LFGMgr.cpp.
References ALLIANCE, lfg::LFGDungeonData::difficulty, DIFFICULTY_NORMAL, DISABLE_TYPE_MAP, lfg::LFGDungeonData::Entry(), WorldSession::Expansion(), lfg::LFGDungeonData::expansion, ObjectAccessor::FindPlayer(), Player::GetAverageItemLevel(), Player::GetBoundInstance(), GetDungeonsByRandom(), Unit::getLevel(), GetLFGDungeon(), Player::GetQuestRewardStatus(), Player::GetSession(), Player::GetTeam(), GUID_LOPART(), Player::HasAchieved(), Player::HasItemCount(), WorldSession::HasPermission(), HORDE, lfg::LFGDungeonData::id, IsDebugRequirementOverrideEnabled(), DisableMgr::IsDisabledFor(), IsSeasonActive(), lfg::LFG_LOCKSTATUS_INSUFFICIENT_EXPANSION, lfg::LFG_LOCKSTATUS_MISSING_ACHIEVEMENT, lfg::LFG_LOCKSTATUS_MISSING_ITEM, lfg::LFG_LOCKSTATUS_NOT_IN_SEASON, lfg::LFG_LOCKSTATUS_QUEST_NOT_COMPLETED, lfg::LFG_LOCKSTATUS_RAID_LOCKED, lfg::LFG_LOCKSTATUS_TOO_HIGH_LEVEL, lfg::LFG_LOCKSTATUS_TOO_LOW_GEAR_SCORE, lfg::LFG_LOCKSTATUS_TOO_LOW_LEVEL, lfg::LFGDungeonData::map, lfg::LFGDungeonData::maxlevel, lfg::LFGDungeonData::minlevel, rbac::RBAC_PERM_JOIN_DUNGEON_FINDER, lfg::LFGDungeonData::requiredItemLevel, lfg::LFGDungeonData::seasonal, SF_LOG_TRACE, SF_LOG_WARN, and sObjectMgr.
Referenced by DumpPlayerInfo(), and GetCompatibleDungeons().
Get last lfg state (NONE, DUNGEON or FINISHED_DUNGEON).
Definition at line 2077 of file LFGMgr.cpp.
References GroupsStore, GUID_LOPART(), IS_GROUP_GUID(), PlayersStore, and SF_LOG_TRACE.
Referenced by RestoreOrClearState().
| uint32 lfg::LFGMgr::GetOptions | ( | ) |
Gets the player count of given group.
Definition at line 2518 of file LFGMgr.cpp.
References GroupsStore.
|
private |
Definition at line 2513 of file LFGMgr.cpp.
References GroupsStore.
Referenced by FinishDungeon(), and GetQueueId().
Definition at line 2605 of file LFGMgr.cpp.
References GetQueueId(), and QueuesStore.
Referenced by JoinLfg(), LeaveLfg(), LeaveSoloLfg(), RemoveProposal(), UpdateProposal(), and UpdateRoleCheck().
Returns queue id.
Definition at line 2584 of file LFGMgr.cpp.
References lfg::LfgGroupData::GetActiveQueueId(), lfg::LfgPlayerData::GetActiveQueueId(), GetPlayers(), GetQueueId(), lfg::LfgGroupData::GetQueues(), lfg::LfgPlayerData::GetQueues(), GetTeam(), GroupsStore, IS_GROUP_GUID(), and PlayersStore.
Referenced by GetQueue(), GetQueueId(), and GetQueueJoinTime().
| time_t lfg::LFGMgr::GetQueueJoinTime | ( | uint64 | guid | ) |
Gets queue join time.
Definition at line 2629 of file LFGMgr.cpp.
References GetGroup(), GetQueueId(), GetState(), IS_GROUP_GUID(), lfg::LFG_STATE_PROPOSAL, lfg::LFG_STATE_QUEUED, and QueuesStore.
| LfgDungeonSet lfg::LFGMgr::GetRandomAndSeasonalDungeons | ( | uint8 | level, |
| uint8 | expansion ) |
Returns all random and seasonal dungeons for given level and expansion.
Definition at line 3024 of file LFGMgr.cpp.
References lfg::LFGDungeonData::Entry(), lfg::LFGDungeonData::expansion, lfg::LFGDungeonData::id, lfg::LFG_TYPE_RANDOM, LfgDungeonStore, lfg::LFGDungeonData::maxlevel, lfg::LFGDungeonData::minlevel, lfg::LFGDungeonData::seasonal, sLFGMgr, and lfg::LFGDungeonData::type.
Gets the random dungeon reward corresponding to given dungeon and player level.
Get the reward of a given random dungeon at a certain level
| [in] | dungeon | dungeon id |
| [in] | level | Player level |
Definition at line 2019 of file LFGMgr.cpp.
References RewardMapStore.
Referenced by FinishDungeon().
Get current player roles.
Definition at line 2112 of file LFGMgr.cpp.
References GUID_LOPART(), PlayersStore, and SF_LOG_TRACE.
Referenced by UpdateProposal().
| LfgDungeonSet const & lfg::LFGMgr::GetSelectedDungeons | ( | uint64 | guid | ) |
Get selected dungeons.
Definition at line 2156 of file LFGMgr.cpp.
References lfg::ConcatenateDungeons(), GetSelectedDungeons(), GUID_LOPART(), PlayersStore, and SF_LOG_TRACE.
Referenced by FinishDungeon(), GetSelectedDungeons(), inLfgDungeonMap(), RemoveProposal(), selectedRandomLfgDungeon(), Update(), and UpdateProposal().
Get current lfg state.
Definition at line 2061 of file LFGMgr.cpp.
References GroupsStore, GUID_LOPART(), IS_GROUP_GUID(), PlayersStore, and SF_LOG_TRACE.
Referenced by _SaveToDB(), AllQueued(), FinishDungeon(), GetLfgStatus(), GetQueueJoinTime(), JoinLfg(), LeaveLfg(), LeaveSoloLfg(), RemoveGroupData(), selectedRandomLfgDungeon(), SetupGroupMember(), and TeleportDungeonGroupOut().
Definition at line 2473 of file LFGMgr.cpp.
References GUID_LOPART(), PlayersStore, and SF_LOG_TRACE.
Referenced by GetQueueId(), and JoinLfg().
Checks if given players are ignoring each other.
Definition at line 2528 of file LFGMgr.cpp.
References ObjectAccessor::FindPlayer(), Player::GetSocial(), GUID_LOPART(), HasIgnore(), and PlayerSocial::HasIgnore().
Referenced by HasIgnore().
| void lfg::LFGMgr::InitBoot | ( | uint64 | gguid, |
| uint64 | kicker, | ||
| uint64 | victim, | ||
| std::string const & | reason ) |
Inits new proposal to boot a player.
Initialize a boot kick vote
| [in] | gguid | Group the vote kicks belongs to |
| [in] | kicker | Kicker guid |
| [in] | victim | Victim guid |
| [in] | reason | Kick reason |
Definition at line 1615 of file LFGMgr.cpp.
References BootsStore, lfg::LfgPlayerBoot::cancelTime, GroupsStore, GUID_LOPART(), lfg::LfgPlayerBoot::inProgress, lfg::LFG_ANSWER_AGREE, lfg::LFG_ANSWER_DENY, lfg::LFG_ANSWER_PENDING, lfg::LFG_STATE_BOOT, lfg::LFG_TIME_BOOT, lfg::LfgPlayerBoot::reason, SendLfgBootProposalUpdate(), SetState(), SetVoteKick(), SF_LOG_DEBUG, lfg::LfgPlayerBoot::victim, and lfg::LfgPlayerBoot::votes.
| bool lfg::LFGMgr::inLfgDungeonMap | ( | uint64 | guid, |
| uint32 | map, | ||
| DifficultyID | difficulty ) |
Check if given guid applied for given map and difficulty. Used to know.
Definition at line 2979 of file LFGMgr.cpp.
References GetDungeon(), GetGroup(), GetLFGDungeon(), GetSelectedDungeons(), and IS_GROUP_GUID().
|
inline |
Gets the server-wide debug override for flexible raid minimum group size.
Definition at line 367 of file LFGMgr.h.
References m_debugFlexRaidMinimumOverride.
|
inline |
Gets the server-wide debug override for dungeon and raid finder requirements.
Definition at line 363 of file LFGMgr.h.
References IsDebugRequirementOverrideEnabled(), and m_debugRequirementOverride.
Referenced by GetLockedDungeons(), and IsDebugRequirementOverrideEnabled().
| bool lfg::LFGMgr::IsFlexibleRaidDungeon | ( | uint32 | dungeonId | ) |
Check whether the dungeon id belongs to a flexible raid queue entry.
Definition at line 2055 of file LFGMgr.cpp.
References GetLFGDungeon().
Referenced by JoinLfg().
| bool lfg::LFGMgr::IsLfgGroup | ( | uint64 | guid | ) |
Check if given group guid is lfg.
Definition at line 2579 of file LFGMgr.cpp.
References GroupsStore, and IS_GROUP_GUID().
| bool lfg::LFGMgr::isOptionEnabled | ( | uint32 | option | ) |
Checks if given lfg option is enabled.
Definition at line 2663 of file LFGMgr.cpp.
References m_options.
Referenced by Update().
| bool lfg::LFGMgr::IsRaidFinderDungeon | ( | uint32 | dungeonId | ) |
Check whether the dungeon id belongs to a Raid Finder queue entry.
Definition at line 2049 of file LFGMgr.cpp.
References lfg::LFGDungeonData::difficulty, DIFFICULTY_25MAN_LFR, and GetLFGDungeon().
| bool lfg::LFGMgr::IsSeasonActive | ( | uint32 | dungeonId | ) |
Checks if Seasonal dungeon is active.
Definition at line 2773 of file LFGMgr.cpp.
References HOLIDAY_BREWFEST, HOLIDAY_FIRE_FESTIVAL, HOLIDAY_HALLOWS_END, HOLIDAY_LOVE_IS_IN_THE_AIR, and IsHolidayActive().
Referenced by GetLockedDungeons().
| bool lfg::LFGMgr::IsVoteKickActive | ( | uint64 | gguid | ) |
Get current vote kick state.
Definition at line 2136 of file LFGMgr.cpp.
References GroupsStore, GUID_LOPART(), and SF_LOG_TRACE.
| void lfg::LFGMgr::JoinLfg | ( | Player * | player, |
| uint8 | roles, | ||
| LfgDungeonSet & | dungeons, | ||
| std::string const & | comment ) |
Join Lfg with selected roles, dungeons and comment.
Adds the player/group to lfg queue. If player is in a group then it is the leader of the group tying to join the group. Join conditions are checked before adding to the new queue.
| [in] | player | Player trying to join (or leader of group trying to join) |
| [in] | roles | Player selected roles |
| [in] | dungeons | Dungeons the player/group is applying for |
| [in] | comment | Player selected comment |
Definition at line 538 of file LFGMgr.cpp.
References lfg::LFGQueue::AddQueueData(), lfg::LfgRoleCheck::cancelTime, lfg::ConcatenateDungeons(), lfg::LfgRoleCheck::dungeons, GetCompatibleDungeons(), GetDungeon(), GetDungeonsByRandom(), GetDungeonType(), Group::GetFirstMember(), Player::GetGroup(), Group::GetGUID(), Object::GetGUID(), Group::GetMemberRole(), Group::GetMembersCount(), WorldObject::GetName(), GetQueue(), Player::GetSession(), GetState(), GetTeam(), GUID_LOPART(), Unit::HasAura(), WorldSession::HasPermission(), Player::InArena(), Player::InBattleground(), Player::InBattlegroundQueue(), IsFlexibleRaidDungeon(), Group::IsLeader(), Group::isLFGGroup(), lfg::IsValidPlayerRoles(), lfg::LfgRoleCheck::leader, lfg::LFG_JOIN_DESERTER, lfg::LFG_JOIN_DISCONNECTED, lfg::LFG_JOIN_DUNGEON_INVALID, lfg::LFG_JOIN_INTERNAL_ERROR, lfg::LFG_JOIN_MIXED_RAID_DUNGEON, lfg::LFG_JOIN_NOT_MEET_REQS, lfg::LFG_JOIN_OK, lfg::LFG_JOIN_PARTY_DESERTER, lfg::LFG_JOIN_PARTY_RANDOM_COOLDOWN, lfg::LFG_JOIN_RANDOM_COOLDOWN, lfg::LFG_JOIN_ROLE_CHECK_FAILED, lfg::LFG_JOIN_TOO_MUCH_MEMBERS, lfg::LFG_JOIN_USING_BG_SYSTEM, lfg::LFG_ROLECHECK_FINISHED, lfg::LFG_ROLECHECK_INITIALITING, lfg::LFG_ROLECHECK_NO_ROLE, lfg::LFG_SPELL_DUNGEON_COOLDOWN, lfg::LFG_SPELL_DUNGEON_DESERTER, lfg::LFG_STATE_BOOT, lfg::LFG_STATE_DUNGEON, lfg::LFG_STATE_PROPOSAL, lfg::LFG_STATE_QUEUED, lfg::LFG_STATE_ROLECHECK, lfg::LFG_TIME_ROLECHECK, lfg::LFG_TYPE_DUNGEON, lfg::LFG_TYPE_RAID, lfg::LFG_TYPE_RANDOM, lfg::LFG_UPDATETYPE_JOIN_QUEUE, lfg::LfgJoinResultData::lockmap, MAXGROUPSIZE, MAXRAIDSIZE, GroupReference::next(), rbac::RBAC_PERM_JOIN_DUNGEON_FINDER, lfg::LfgRoleCheck::rDungeonId, lfg::LFGQueue::RemoveFromQueue(), lfg::LfgJoinResultData::result, Group::RoleCheckAllResponded(), RoleChecksStore, lfg::LfgRoleCheck::roles, WorldSession::SendLfgJoinResult(), WorldSession::SendLfgUpdateStatus(), SetActiveQueueId(), SetComment(), SetRoles(), SetSelectedDungeons(), SetState(), SF_LOG_DEBUG, lfg::LfgJoinResultData::state, lfg::LfgRoleCheck::state, and UpdateRoleCheck().
| void lfg::LFGMgr::LeaveLfg | ( | uint64 | guid, |
| bool | disconnected = false ) |
Leaves lfg.
Leaves Dungeon System. Player/Group is removed from queue, rolechecks, proposals or votekicks. Player or group needs to be not NULL and using Dungeon System
| [in] | guid | Player or group guid |
Definition at line 778 of file LFGMgr.cpp.
References ClearGroupQueueState(), ClearQueueState(), GetGroup(), GetLeader(), GetQueue(), GetState(), GUID_LOPART(), IS_GROUP_GUID(), lfg::LFG_ANSWER_DENY, lfg::LFG_STATE_DUNGEON, lfg::LFG_STATE_FINISHED_DUNGEON, lfg::LFG_STATE_NONE, lfg::LFG_STATE_PROPOSAL, lfg::LFG_STATE_QUEUED, lfg::LFG_STATE_RAIDBROWSER, lfg::LFG_STATE_ROLECHECK, lfg::LFG_UPDATETYPE_PROPOSAL_DECLINED, lfg::LFG_UPDATETYPE_REMOVED_FROM_QUEUE, ProposalsStore, lfg::LFGQueue::RemoveFromQueue(), RemoveProposal(), SendLfgUpdateStatus(), SF_LOG_DEBUG, and UpdateRoleCheck().
Leaves Solo lfg.
Definition at line 838 of file LFGMgr.cpp.
References ClearQueueState(), GetQueue(), GetState(), GUID_LOPART(), lfg::LFG_ANSWER_DENY, lfg::LFG_STATE_BOOT, lfg::LFG_STATE_DUNGEON, lfg::LFG_STATE_FINISHED_DUNGEON, lfg::LFG_STATE_NONE, lfg::LFG_STATE_PROPOSAL, lfg::LFG_STATE_QUEUED, lfg::LFG_STATE_RAIDBROWSER, lfg::LFG_UPDATETYPE_PROPOSAL_DECLINED, lfg::LFG_UPDATETYPE_REMOVED_FROM_QUEUE, ProposalsStore, lfg::LFGQueue::RemoveFromQueue(), RemoveProposal(), SendLfgUpdateStatus(), and SF_LOG_DEBUG.
| void lfg::LFGMgr::LoadLFGDungeons | ( | bool | reload = false | ) |
Loads dungeons from dbc and adds teleport coords.
Definition at line 292 of file LFGMgr.cpp.
References CachedDungeonMapStore, Field::GetFloat(), getMSTime(), GetMSTimeDiffToNow(), Field::GetUInt32(), lfg::LFGDungeonData::group, lfg::LFGDungeonData::id, MapEntry::IsBattlegroundOrArena(), lfg::LFG_TYPE_DUNGEON, lfg::LFG_TYPE_RAID, lfg::LFG_TYPE_RANDOM, LfgDungeonStore, LFGDungeonEntry::m_ContinentID, LFGDungeonEntry::m_ID, LFGDungeonEntry::m_Type, lfg::LFGDungeonData::map, lfg::LFGDungeonData::name, lfg::LFGDungeonData::o, lfg::LFGDungeonData::requiredItemLevel, SF_LOG_ERROR, SF_LOG_INFO, sLFGDungeonStore, sMapStore, sObjectMgr, AreaTriggerStruct::target_mapId, AreaTriggerStruct::target_Orientation, AreaTriggerStruct::target_X, AreaTriggerStruct::target_Y, AreaTriggerStruct::target_Z, lfg::LFGDungeonData::type, WorldDatabase, lfg::LFGDungeonData::x, lfg::LFGDungeonData::y, and lfg::LFGDungeonData::z.
| void lfg::LFGMgr::LoadRewards | ( | ) |
Loads rewards for random dungeons.
Load rewards for completing dungeons.
Definition at line 224 of file LFGMgr.cpp.
References CONFIG_MAX_PLAYER_LEVEL, GetLFGDungeonEntry(), getMSTime(), GetMSTimeDiffToNow(), Field::GetUInt32(), Field::GetUInt8(), RewardMapStore, SF_LOG_ERROR, SF_LOG_INFO, sObjectMgr, sWorld, and WorldDatabase.
|
private |
Makes a new group given a proposal
| [in] | proposal | Proposal to get info from |
Definition at line 1152 of file LFGMgr.cpp.
References _SaveToDB(), Group::AddMember(), Unit::CastSpell(), Group::ChangeLeader(), Group::ConvertToLFG(), Group::ConvertToRaid(), Group::Create(), lfg::LFGDungeonData::difficulty, lfg::LfgProposal::dungeonId, lfg::LFGDungeonData::Entry(), ObjectAccessor::FindPlayer(), GetActiveQueueId(), Group::GetDbStoreId(), GetGroup(), Player::GetGroup(), Group::GetGUID(), Object::GetGUID(), Group::GetLeaderGUID(), GetLFGDungeon(), Group, lfg::LfgProposal::group, GUID_LOPART(), lfg::LFGDungeonData::id, lfg::LfgProposal::id, Group::IsMember(), lfg::LfgProposal::isNew, Group::isRaidGroup(), lfg::LfgProposal::leader, lfg::LFG_SPELL_DUNGEON_COOLDOWN, lfg::LFG_STATE_DUNGEON, lfg::LFG_STATE_PROPOSAL, lfg::LFG_TYPE_RANDOM, lfg::LFGDungeonData::map, lfg::LfgProposal::players, Group::RemoveMember(), Group::SendUpdate(), SetActiveQueueId(), SetDungeon(), Group::SetDungeonDifficulty(), SetLeader(), Group::SetLfgRoles(), Group::SetRaidDifficulty(), SetState(), SetupGroupMember(), SF_LOG_DEBUG, SF_LOG_ERROR, sGroupMgr, TeleportPlayer(), and lfg::LFGDungeonData::type.
Referenced by UpdateProposal().
| void lfg::LFGMgr::RemoveGroupData | ( | uint64 | guid | ) |
Removes saved group data.
Definition at line 2418 of file LFGMgr.cpp.
References BootsStore, ClearQueueState(), GetState(), GroupsStore, GUID_LOPART(), lfg::LFG_ANSWER_DENY, lfg::LFG_STATE_NONE, lfg::LFG_STATE_PROPOSAL, lfg::LFG_UPDATETYPE_PROPOSAL_DECLINED, lfg::LFG_UPDATETYPE_REMOVED_FROM_QUEUE, ProposalsStore, QueuesStore, RemoveProposal(), RoleChecksStore, SendLfgUpdateStatus(), SetGroup(), and SF_LOG_TRACE.
|
private |
Definition at line 2410 of file LFGMgr.cpp.
References GUID_LOPART(), PlayersStore, and SF_LOG_TRACE.
|
private |
Remove a proposal from the pool, remove the group that didn't accept (if needed) and readd the other members to the queue
| [in] | itProposal | Iterator to the proposal to remove |
| [in] | type | Type of removal (LFG_UPDATETYPE_PROPOSAL_FAILED, LFG_UPDATETYPE_PROPOSAL_DECLINED) |
Definition at line 1490 of file LFGMgr.cpp.
References lfg::LFGQueue::AddToQueue(), GetComment(), GetQueue(), GetSelectedDungeons(), GUID_LOPART(), lfg::LFGQueue::HasQueueData(), lfg::LfgProposal::id, lfg::LFG_ANSWER_AGREE, lfg::LFG_ANSWER_DENY, lfg::LFG_ANSWER_PENDING, lfg::LFG_PROPOSAL_FAILED, lfg::LFG_STATE_QUEUED, lfg::LFG_UPDATETYPE_ADDED_TO_QUEUE, lfg::LFG_UPDATETYPE_PROPOSAL_FAILED, lfg::LFG_UPDATETYPE_REMOVED_FROM_QUEUE, lfg::LfgProposal::players, ProposalsStore, lfg::LfgProposal::queues, lfg::LFGQueue::RemoveFromQueue(), RestoreOrClearState(), SendLfgUpdateProposal(), SendLfgUpdateStatus(), SetState(), SF_LOG_DEBUG, lfg::LfgProposal::state, and lfg::LfgUpdateData::updateType.
Referenced by LeaveLfg(), LeaveSoloLfg(), RemoveGroupData(), Update(), and UpdateProposal().
| bool lfg::LFGMgr::RestoreActiveQueue | ( | uint64 | guid | ) |
Restores the active queue id from saved queue data.
Definition at line 2728 of file LFGMgr.cpp.
References lfg::LfgGroupData::GetActiveQueueId(), lfg::LfgPlayerData::GetActiveQueueId(), lfg::LfgGroupData::GetQueues(), lfg::LfgPlayerData::GetQueues(), GroupsStore, IS_GROUP_GUID(), lfg::LFG_STATE_NONE, PlayersStore, lfg::LfgGroupData::SetActiveQueueId(), and lfg::LfgPlayerData::SetActiveQueueId().
Referenced by ClearQueueState(), and GetLfgStatus().
|
private |
Definition at line 2272 of file LFGMgr.cpp.
References ClearQueueState(), GetOldState(), lfg::LFG_STATE_NONE, and RestoreState().
Referenced by RemoveProposal(), Update(), and UpdateRoleCheck().
|
private |
Definition at line 2251 of file LFGMgr.cpp.
References lfg::LfgGroupData::GetOldState(), lfg::LfgPlayerData::GetOldState(), lfg::LfgGroupData::GetState(), lfg::LfgPlayerData::GetState(), lfg::GetStateString(), GroupsStore, GUID_LOPART(), IS_GROUP_GUID(), PlayersStore, lfg::LfgGroupData::RestoreState(), lfg::LfgPlayerData::RestoreState(), and SF_LOG_TRACE.
Referenced by RestoreOrClearState().
| bool lfg::LFGMgr::selectedRandomLfgDungeon | ( | uint64 | guid | ) |
Check if given guid applied for random dungeon.
Definition at line 2963 of file LFGMgr.cpp.
References GetLFGDungeon(), GetSelectedDungeons(), GetState(), lfg::LFG_STATE_NONE, lfg::LFG_TYPE_RANDOM, lfg::LFGDungeonData::seasonal, and lfg::LFGDungeonData::type.
| bool lfg::LFGMgr::SendActiveProposal | ( | uint64 | guid | ) |
Resends an active dungeon proposal to a player if one exists.
Definition at line 2710 of file LFGMgr.cpp.
References ProposalsStore, and SendLfgUpdateProposal().
|
private |
Definition at line 2561 of file LFGMgr.cpp.
References ObjectAccessor::FindPlayer().
Referenced by InitBoot(), Update(), and UpdateBoot().
|
private |
Definition at line 2555 of file LFGMgr.cpp.
References ObjectAccessor::FindPlayer().
Referenced by Update(), and UpdateRoleCheck().
|
static |
Sends queue status to player.
Definition at line 2573 of file LFGMgr.cpp.
References ObjectAccessor::FindPlayer().
Referenced by lfg::LFGQueue::UpdateQueueTimers().
|
private |
Definition at line 2543 of file LFGMgr.cpp.
References ObjectAccessor::FindPlayer().
Referenced by Update(), and UpdateRoleCheck().
Definition at line 2537 of file LFGMgr.cpp.
References ObjectAccessor::FindPlayer().
Referenced by UpdateRoleCheck().
|
private |
Definition at line 2567 of file LFGMgr.cpp.
References ObjectAccessor::FindPlayer().
Referenced by RemoveProposal(), SendActiveProposal(), Update(), and UpdateProposal().
|
private |
Definition at line 2549 of file LFGMgr.cpp.
References ObjectAccessor::FindPlayer().
Referenced by ClearGroupQueueState(), LeaveLfg(), LeaveSoloLfg(), RemoveGroupData(), RemoveProposal(), Update(), UpdateProposal(), and UpdateRoleCheck().
Definition at line 2366 of file LFGMgr.cpp.
References GroupsStore, GUID_LOPART(), IS_GROUP_GUID(), PlayersStore, and SF_LOG_TRACE.
Referenced by JoinLfg(), MakeNewGroup(), and SetupGroupMember().
| void lfg::LFGMgr::SetComment | ( | uint64 | guid, |
| std::string const & | comment ) |
Sets player lfr comment.
Definition at line 2392 of file LFGMgr.cpp.
References GUID_LOPART(), PlayersStore, and SF_LOG_TRACE.
Referenced by JoinLfg().
|
inline |
Sets the server-wide debug override for flexible raid minimum group size.
Definition at line 369 of file LFGMgr.h.
References m_debugFlexRaidMinimumOverride.
|
inline |
Sets the server-wide debug override for dungeon and raid finder requirements.
Definition at line 365 of file LFGMgr.h.
References m_debugRequirementOverride.
Definition at line 2380 of file LFGMgr.cpp.
References GroupsStore, GUID_LOPART(), and SF_LOG_TRACE.
Referenced by _LoadFromDB(), and MakeNewGroup().
Sets player group.
Definition at line 2508 of file LFGMgr.cpp.
References PlayersStore.
Referenced by ClearGroupQueueState(), GetLfgStatus(), RemoveGroupData(), and SetupGroupMember().
Sets the leader of the group.
Definition at line 2490 of file LFGMgr.cpp.
References GroupsStore.
Referenced by _LoadFromDB(), and MakeNewGroup().
| void lfg::LFGMgr::SetOptions | ( | uint32 | options | ) |
Sets player lfg roles.
Definition at line 2386 of file LFGMgr.cpp.
References GUID_LOPART(), PlayersStore, and SF_LOG_TRACE.
Referenced by JoinLfg(), and UpdateRoleCheck().
|
private |
Definition at line 2398 of file LFGMgr.cpp.
References lfg::ConcatenateDungeons(), GUID_LOPART(), PlayersStore, and SF_LOG_TRACE.
Referenced by JoinLfg(), and SetupGroupMember().
Definition at line 2280 of file LFGMgr.cpp.
References lfg::LfgGroupData::GetOldState(), lfg::LfgPlayerData::GetOldState(), lfg::LfgGroupData::GetState(), lfg::LfgPlayerData::GetState(), lfg::GetStateString(), GroupsStore, GUID_LOPART(), IS_GROUP_GUID(), PlayersStore, lfg::LfgGroupData::SetState(), lfg::LfgPlayerData::SetState(), and SF_LOG_TRACE.
Referenced by _LoadFromDB(), ClearQueueState(), FinishDungeon(), InitBoot(), JoinLfg(), MakeNewGroup(), RemoveProposal(), SetupGroupMember(), Update(), UpdateBoot(), UpdateProposal(), and UpdateRoleCheck().
Sets player team.
Definition at line 2495 of file LFGMgr.cpp.
References CONFIG_ALLOW_TWO_SIDE_INTERACTION_GROUP, PlayersStore, and sWorld.
Initializes player data after loading group data from DB.
Definition at line 2952 of file LFGMgr.cpp.
References AddPlayerToGroup(), GetActiveQueueId(), GetDungeon(), GetState(), SetActiveQueueId(), SetGroup(), SetSelectedDungeons(), and SetState().
Referenced by MakeNewGroup().
|
private |
Definition at line 2143 of file LFGMgr.cpp.
References GroupsStore, GUID_LOPART(), lfg::LfgGroupData::IsVoteKickActive(), lfg::LfgGroupData::SetVoteKick(), and SF_LOG_TRACE.
Referenced by InitBoot(), Update(), and UpdateBoot().
| void lfg::LFGMgr::TeleportDungeonGroupOut | ( | Group * | group | ) |
Teleport online members of an LFG dungeon group back to their saved entry points.
Definition at line 1873 of file LFGMgr.cpp.
References GetDungeon(), Group::GetFirstMember(), Group::GetGUID(), GetLFGDungeon(), WorldLocation::GetMapId(), GetState(), Group::isLFGGroup(), lfg::LFG_STATE_DUNGEON, lfg::LFG_STATE_FINISHED_DUNGEON, lfg::LFGDungeonData::map, GroupReference::next(), and TeleportPlayer().
| void lfg::LFGMgr::TeleportPlayer | ( | Player * | player, |
| bool | out, | ||
| bool | fromOpcode = false, | ||
| bool | forceChangeInstance = false ) |
Teleport a player to/from selected dungeon.
Teleports the player in or out the dungeon
| [in] | player | Player to teleport |
| [in] | out | Teleport out (true) or in (false) |
| [in] | fromOpcode | Function called from opcode handlers? (Default false) |
Definition at line 1738 of file LFGMgr.cpp.
References Player::CleanupAfterTaxiFlight(), lfg::LfgPlayerData::ClearReturnLocation(), FATIGUE_TIMER, Unit::GetCharmGUID(), GetDungeon(), Group::GetFirstMember(), Player::GetGroup(), Group::GetGUID(), Object::GetGUID(), GetLFGDungeon(), WorldObject::GetMap(), WorldLocation::GetMapId(), Unit::GetMotionMaster(), WorldObject::GetName(), Position::GetOrientation(), Position::GetPositionX(), Position::GetPositionY(), Position::GetPositionZ(), lfg::LfgPlayerData::GetReturnLocation(), Player::GetSession(), Unit::GetVehicle(), Unit::HasUnitState(), lfg::LFGDungeonData::id, Unit::IsAlive(), Player::IsBeingTeleported(), Unit::IsFalling(), Unit::IsInCombat(), Unit::IsInFlight(), Map::IsInstance(), Group::isLFGGroup(), Player::IsMirrorTimerActive(), lfg::LfgReturnLocation::IsSet, MapManager::IsValidMapCoord(), lfg::LFG_TELEPORTERROR_CHARMING, lfg::LFG_TELEPORTERROR_FALLING, lfg::LFG_TELEPORTERROR_FATIGUE, lfg::LFG_TELEPORTERROR_IN_COMBAT, lfg::LFG_TELEPORTERROR_IN_VEHICLE, lfg::LFG_TELEPORTERROR_INVALID_LOCATION, lfg::LFG_TELEPORTERROR_OK, lfg::LFG_TELEPORTERROR_PLAYER_DEAD, lfg::LFGDungeonData::map, lfg::LfgReturnLocation::MapId, MotionMaster::MovementExpired(), lfg::LFGDungeonData::name, GroupReference::next(), lfg::LfgReturnLocation::O, lfg::LFGDungeonData::o, PlayersStore, WorldSession::SendLfgTeleportError(), Player::SetBattlegroundEntryPoint(), Player::SetForcedTeleportFar(), Player::SetSemaphoreTeleportForcedFar(), SF_LOG_DEBUG, SF_LOG_ERROR, Player::TeleportTo(), Player::TeleportToBGEntryPoint(), UNIT_STATE_JUMPING, lfg::LfgReturnLocation::X, lfg::LFGDungeonData::x, lfg::LfgReturnLocation::Y, lfg::LFGDungeonData::y, lfg::LfgReturnLocation::Z, and lfg::LFGDungeonData::z.
Referenced by MakeNewGroup(), and TeleportDungeonGroupOut().
| void lfg::LFGMgr::Update | ( | uint32 | diff | ) |
Definition at line 410 of file LFGMgr.cpp.
References BootsStore, lfg::LfgPlayerBoot::cancelTime, lfg::LfgRoleCheck::cancelTime, GetComment(), GetGroup(), GetSelectedDungeons(), GroupsStore, lfg::LfgPlayerBoot::inProgress, IS_GROUP_GUID(), isOptionEnabled(), lfg::LfgRoleCheck::leader, lfg::LFG_JOIN_ROLE_CHECK_FAILED, lfg::LFG_OPTION_ENABLE_DUNGEON_FINDER, lfg::LFG_OPTION_ENABLE_RAID_BROWSER, lfg::LFG_PROPOSAL_SUCCESS, lfg::LFG_QUEUEUPDATE_INTERVAL, lfg::LFG_ROLECHECK_MISSING_ROLE, lfg::LFG_STATE_DUNGEON, lfg::LFG_STATE_PROPOSAL, lfg::LFG_UPDATETYPE_PROPOSAL_BEGIN, lfg::LFG_UPDATETYPE_PROPOSAL_FAILED, lfg::LFG_UPDATETYPE_ROLECHECK_FAILED, m_lfgProposalId, m_QueueTimer, lfg::LfgProposal::players, ProposalsStore, QueuesStore, RemoveProposal(), RestoreOrClearState(), RoleChecksStore, lfg::LfgRoleCheck::roles, SendLfgBootProposalUpdate(), SendLfgJoinResult(), SendLfgRoleCheckUpdate(), SendLfgUpdateProposal(), SendLfgUpdateStatus(), SetState(), SetVoteKick(), SF_LOG_DEBUG, lfg::LfgProposal::state, lfg::LfgRoleCheck::state, UpdateProposal(), lfg::LfgPlayerBoot::victim, and lfg::LfgPlayerBoot::votes.
| void lfg::LFGMgr::UpdateBoot | ( | uint64 | guid, |
| bool | accept ) |
Updates player boot proposal with new player answer.
Update Boot info with player answer
| [in] | guid | Player who has answered |
| [in] | player | answer |
Definition at line 1666 of file LFGMgr.cpp.
References BootsStore, DecreaseKicksLeft(), GetGroup(), GROUP_REMOVEMETHOD_KICK_LFG, GroupsStore, GUID_LOPART(), lfg::LfgPlayerBoot::inProgress, lfg::LFG_ANSWER_AGREE, lfg::LFG_ANSWER_PENDING, lfg::LFG_GROUP_KICK_VOTES_NEEDED, lfg::LFG_STATE_DUNGEON, Player::RemoveFromGroup(), SendLfgBootProposalUpdate(), SetState(), SetVoteKick(), sGroupMgr, lfg::LfgPlayerBoot::victim, and lfg::LfgPlayerBoot::votes.
Updates proposal to join dungeon with player answer.
Update Proposal info with player answer
| [in] | proposalId | Proposal id to be updated |
| [in] | guid | Player guid to update answer |
| [in] | accept | Player answer |
Definition at line 1308 of file LFGMgr.cpp.
References lfg::LfgProposalPlayer::accept, lfg::LfgProposal::dungeonId, ObjectAccessor::FindPlayer(), GetGroup(), lfg::LFGQueue::GetJoinTime(), GetLFGDungeon(), GetQueue(), GetRoles(), GetSelectedDungeons(), lfg::LfgProposalPlayer::group, GUID_LOPART(), lfg::LFGQueue::HasQueueData(), lfg::LFG_ANSWER_AGREE, lfg::LFG_ANSWER_DENY, lfg::LFG_ANSWER_PENDING, lfg::LFG_PROPOSAL_INITIATING, lfg::LFG_PROPOSAL_SUCCESS, lfg::LFG_STATE_DUNGEON, lfg::LFG_UPDATETYPE_GROUP_FOUND, lfg::LFG_UPDATETYPE_GROUP_MEMBER_OFFLINE, lfg::LFG_UPDATETYPE_PROPOSAL_DECLINED, lfg::LFG_UPDATETYPE_PROPOSAL_FAILED, lfg::LFG_UPDATETYPE_REMOVED_FROM_QUEUE, MakeNewGroup(), lfg::PLAYER_ROLE_DAMAGE, lfg::PLAYER_ROLE_HEALER, lfg::PLAYER_ROLE_LEADER, lfg::PLAYER_ROLE_TANK, lfg::LfgProposal::players, ProposalsStore, lfg::LfgProposal::queues, lfg::LFGQueue::RemoveFromQueue(), RemoveProposal(), SendLfgUpdateProposal(), SendLfgUpdateStatus(), SetState(), SF_LOG_DEBUG, SF_LOG_ERROR, lfg::LfgProposal::state, lfg::LFGQueue::UpdateWaitTimeAvg(), lfg::LFGQueue::UpdateWaitTimeDps(), lfg::LFGQueue::UpdateWaitTimeHealer(), and lfg::LFGQueue::UpdateWaitTimeTank().
Referenced by Update().
| void lfg::LFGMgr::UpdateRoleCheck | ( | uint64 | gguid, |
| uint64 | guid = 0, | ||
| uint8 | roles = PLAYER_ROLE_NONE ) |
Updates the role check with player answer.
Update the Role check info with the player selected role.
| [in] | grp | Group guid to update rolecheck |
| [in] | guid | Player guid (0 = rolecheck failed) |
| [in] | roles | Player selected roles |
Definition at line 894 of file LFGMgr.cpp.
References lfg::LFGQueue::AddQueueData(), CheckDpsOnlyRoles(), CheckFlexibleRaidRoles(), CheckGroupRoles(), lfg::LfgRoleCheck::dungeons, GetComment(), GetLFGDungeon(), GetQueue(), lfg::IsValidPlayerRoles(), lfg::LfgRoleCheck::leader, lfg::LFG_JOIN_FAILED, lfg::LFG_JOIN_ROLE_CHECK_FAILED, lfg::LFG_ROLECHECK_ABORTED, lfg::LFG_ROLECHECK_DEFAULT, lfg::LFG_ROLECHECK_FINISHED, lfg::LFG_ROLECHECK_INITIALITING, lfg::LFG_ROLECHECK_MISSING_ROLE, lfg::LFG_ROLECHECK_NO_ROLE, lfg::LFG_ROLECHECK_WRONG_ROLES, lfg::LFG_STATE_QUEUED, lfg::LFG_UPDATETYPE_ADDED_TO_QUEUE, lfg::LFG_UPDATETYPE_ROLECHECK_FAILED, MAXRAIDSIZE, lfg::PLAYER_ROLE_NONE, lfg::LfgRoleCheck::rDungeonId, RestoreOrClearState(), RoleChecksStore, lfg::LfgRoleCheck::roles, SendLfgJoinResult(), SendLfgRoleCheckUpdate(), SendLfgRoleChosen(), SendLfgUpdateStatus(), SetRoles(), SetState(), and lfg::LfgRoleCheck::state.
Referenced by JoinLfg(), and LeaveLfg().
|
friend |
|
private |
Current player kicks.
Definition at line 511 of file LFGMgr.h.
Referenced by Clean(), ClearGroupQueueState(), DumpQueueInfo(), InitBoot(), RemoveGroupData(), Update(), and UpdateBoot().
|
private |
Stores all dungeons by groupType.
Definition at line 504 of file LFGMgr.h.
Referenced by GetDungeonsByRandom(), and LoadLFGDungeons().
|
private |
Group data.
Definition at line 513 of file LFGMgr.h.
Referenced by AddPlayerToGroup(), Clean(), ClearGroupQueueState(), DecreaseKicksLeft(), DumpGroupInfo(), GetActiveQueueId(), GetDungeon(), GetDungeonMapId(), GetKicksLeft(), GetLeader(), GetOldState(), GetPlayerCount(), GetPlayers(), GetQueueId(), GetState(), InitBoot(), IsLfgGroup(), IsVoteKickActive(), RemoveGroupData(), RemovePlayerFromGroup(), RestoreActiveQueue(), RestoreState(), SetActiveQueueId(), SetDungeon(), SetLeader(), SetState(), SetVoteKick(), Update(), and UpdateBoot().
|
private |
Definition at line 507 of file LFGMgr.h.
Referenced by GetLFGDungeon(), GetRandomAndSeasonalDungeons(), and LoadLFGDungeons().
|
private |
allows flexible raid queues to form below normal minimum for debugging
Definition at line 501 of file LFGMgr.h.
Referenced by IsDebugFlexRaidMinimumOverrideEnabled(), LFGMgr(), and SetDebugFlexRaidMinimumOverride().
|
private |
bypasses LFG entry requirements for server-wide debugging
Definition at line 500 of file LFGMgr.h.
Referenced by IsDebugRequirementOverrideEnabled(), LFGMgr(), and SetDebugRequirementOverride().
|
private |
used as internal counter for proposals
Definition at line 498 of file LFGMgr.h.
Referenced by AddProposal(), LFGMgr(), and Update().
|
private |
Stores config options.
Definition at line 499 of file LFGMgr.h.
Referenced by GetOptions(), isOptionEnabled(), LFGMgr(), and SetOptions().
|
private |
|
private |
Player data.
Definition at line 512 of file LFGMgr.h.
Referenced by Clean(), DumpPlayerInfo(), GetActiveQueueId(), GetComment(), GetGroup(), GetLfgStatus(), GetOldState(), GetQueueId(), GetRoles(), GetSelectedDungeons(), GetState(), GetTeam(), RemovePlayerData(), RestoreActiveQueue(), RestoreState(), SetActiveQueueId(), SetComment(), SetGroup(), SetRoles(), SetSelectedDungeons(), SetState(), SetTeam(), and TeleportPlayer().
|
private |
Current Proposals.
Definition at line 510 of file LFGMgr.h.
Referenced by AddProposal(), Clean(), DumpQueueInfo(), LeaveLfg(), LeaveSoloLfg(), RemoveGroupData(), RemoveProposal(), SendActiveProposal(), Update(), and UpdateProposal().
|
private |
Queues.
Definition at line 503 of file LFGMgr.h.
Referenced by Clean(), ClearQueueState(), DumpGroupInfo(), DumpPlayerInfo(), DumpQueueInfo(), GetQueue(), GetQueueJoinTime(), RemoveGroupData(), and Update().
|
private |
Stores rewards for random dungeons.
Definition at line 506 of file LFGMgr.h.
Referenced by GetRandomDungeonReward(), LoadRewards(), and ~LFGMgr().
|
private |
Current Role checks.
Definition at line 509 of file LFGMgr.h.
Referenced by Clean(), ClearGroupQueueState(), DumpQueueInfo(), JoinLfg(), RemoveGroupData(), Update(), and UpdateRoleCheck().