![]() |
TrinityCore
|
#include <SocialMgr.h>
Public Member Functions | |
| SocialMgr (SocialMgr const &)=delete | |
| SocialMgr (SocialMgr &&)=delete | |
| SocialMgr & | operator= (SocialMgr const &)=delete |
| SocialMgr & | operator= (SocialMgr &&)=delete |
| void | RemovePlayerSocial (ObjectGuid const &guid) |
| void | SendFriendStatus (Player *player, FriendsResult result, ObjectGuid const &friendGuid, bool broadcast=false) |
| void | BroadcastToFriendListers (Player *player, WorldPacket const *packet) |
| PlayerSocial * | LoadFromDB (PreparedQueryResult result, ObjectGuid const &guid) |
Static Public Member Functions | |
| static SocialMgr * | instance () |
| static void | GetFriendInfo (Player *player, ObjectGuid const &friendGUID, FriendInfo &friendInfo) |
Private Types | |
| typedef std::map< ObjectGuid, PlayerSocial > | SocialMap |
Private Member Functions | |
| SocialMgr () | |
| ~SocialMgr () | |
Private Attributes | |
| SocialMap | _socialMap |
Definition at line 142 of file SocialMgr.h.
|
private |
Definition at line 169 of file SocialMgr.h.
|
privatedefault |
|
privatedefault |
|
delete |
|
delete |
| void SocialMgr::BroadcastToFriendListers | ( | Player * | player, |
| WorldPacket const * | packet | ||
| ) |
Definition at line 291 of file SocialMgr.cpp.
References _socialMap, ASSERT, CONFIG_GM_LEVEL_IN_WHO_LIST, ObjectAccessor::FindPlayer(), BaseEntity::GetGUID(), WorldSession::GetSecurity(), Player::GetSession(), Player::GetTeam(), WorldSession::HasPermission(), Player::IsVisibleGloballyFor(), rbac::RBAC_PERM_TWO_SIDE_WHO_LIST, rbac::RBAC_PERM_WHO_SEE_ALL_SEC_LEVELS, WorldSession::SendPacket(), SOCIAL_FLAG_FRIEND, and sWorld.
Referenced by SendFriendStatus().
|
static |
Definition at line 220 of file SocialMgr.cpp.
References PlayerSocial::_playerSocialMap, FriendInfo::Area, FriendInfo::Class, CONFIG_GM_LEVEL_IN_WHO_LIST, ObjectAccessor::FindPlayer(), FRIEND_STATUS_AFK, FRIEND_STATUS_DND, FRIEND_STATUS_OFFLINE, FRIEND_STATUS_ONLINE, FRIEND_STATUS_RAF, WorldSession::GetAccountId(), Unit::GetClass(), Unit::GetLevel(), WorldSession::GetRecruiterId(), WorldSession::GetSecurity(), Player::GetSession(), Player::GetSocial(), Player::GetTeam(), WorldObject::GetZoneId(), WorldSession::HasPermission(), Player::isAFK(), Player::isDND(), Player::IsVisibleGloballyFor(), FriendInfo::Level, FriendInfo::Note, rbac::RBAC_PERM_TWO_SIDE_WHO_LIST, rbac::RBAC_PERM_WHO_SEE_ALL_SEC_LEVELS, FriendInfo::Status, and sWorld.
Referenced by SendFriendStatus(), and PlayerSocial::SendSocialList().
|
static |
| PlayerSocial * SocialMgr::LoadFromDB | ( | PreparedQueryResult | result, |
| ObjectGuid const & | guid | ||
| ) |
Definition at line 318 of file SocialMgr.cpp.
References PlayerSocial::_ignoredAccounts, PlayerSocial::_playerSocialMap, _socialMap, Field::GetUInt8(), PlayerSocial::SetPlayerGUID(), and SOCIAL_FLAG_IGNORED.
|
inline |
Definition at line 157 of file SocialMgr.h.
References _socialMap.
| void SocialMgr::SendFriendStatus | ( | Player * | player, |
| FriendsResult | result, | ||
| ObjectGuid const & | friendGuid, | ||
| bool | broadcast = false |
||
| ) |
Definition at line 269 of file SocialMgr.cpp.
References FriendInfo::Area, WorldPackets::Social::FriendStatus::AreaID, BroadcastToFriendListers(), FriendInfo::Class, WorldPackets::Social::FriendStatus::ClassID, WorldPackets::Social::FriendStatus::FriendResult, GetFriendInfo(), GetVirtualRealmAddress(), WorldPackets::Social::FriendStatus::Guid, FriendInfo::Level, WorldPackets::Social::FriendStatus::Level, FriendInfo::Note, WorldPackets::Social::FriendStatus::Notes, Player::SendDirectMessage(), FriendInfo::Status, WorldPackets::Social::FriendStatus::Status, WorldPackets::Social::FriendStatus::VirtualRealmAddress, FriendInfo::WowAccountGuid, WorldPackets::Social::FriendStatus::WowAccountGuid, and WorldPackets::Social::FriendStatus::Write().
|
private |
Definition at line 170 of file SocialMgr.h.
Referenced by BroadcastToFriendListers(), LoadFromDB(), and RemovePlayerSocial().