aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Handlers/MiscHandler.cpp
diff options
context:
space:
mode:
authorSpp <spp@jorge.gr>2013-03-08 13:15:25 +0100
committerSpp <spp@jorge.gr>2013-03-08 13:15:25 +0100
commit377cfdb5602cec4ce13d9d50937836aa7e03c446 (patch)
tree87ff543f2f3b6324bdeef491344b97a7394d82aa /src/server/game/Handlers/MiscHandler.cpp
parentb4542c65048344019007a666a2bd35f9453d5664 (diff)
Core/RBAC: Fix multiple permissions and remove multiple config options that are currently implementes by RBAC
- Remove config options: CONFIG_ALLOW_TWO_SIDE_INTERACTION_CHAT, CONFIG_ALLOW_TWO_SIDE_INTERACTION_MAIL, CONFIG_GM_LOG_TRADE, CONFIG_ALLOW_TWO_SIDE_ACCOUNTS, CONFIG_ALLOW_TWO_SIDE_WHO_LIST, CONFIG_ALLOW_GM_FRIEND, CONFIG_ALLOW_TWO_SIDE_ADD_FRIEND, CONFIG_SILENTLY_GM_JOIN_TO_CHANNEL - Fix RBAC_PERM_SKIP_CHECK_CHAT_SPAM (Was checking spam for those that had the permission) - Only check RBAC_PERM_TWO_SIDE_INTERACTION_CHAT for sender of whispers (Restores GM being able to whisper players) - Only check RBAC_PERM_TWO_SIDE_INTERACTION_MAIL for sender - Fix .ticket assign <Player>, with last RBAC change it was changed by mistake from Player to Account
Diffstat (limited to 'src/server/game/Handlers/MiscHandler.cpp')
-rw-r--r--src/server/game/Handlers/MiscHandler.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/server/game/Handlers/MiscHandler.cpp b/src/server/game/Handlers/MiscHandler.cpp
index 3cd937216b8..475d3474391 100644
--- a/src/server/game/Handlers/MiscHandler.cpp
+++ b/src/server/game/Handlers/MiscHandler.cpp
@@ -242,7 +242,6 @@ void WorldSession::HandleWhoOpcode(WorldPacket& recvData)
uint32 team = _player->GetTeam();
- bool allowTwoSideWhoList = sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_WHO_LIST);
uint32 gmLevelInWhoList = sWorld->getIntConfig(CONFIG_GM_LEVEL_IN_WHO_LIST);
uint32 displaycount = 0;
@@ -256,7 +255,7 @@ void WorldSession::HandleWhoOpcode(WorldPacket& recvData)
{
Player* target = itr->second;
// player can see member of other team only if CONFIG_ALLOW_TWO_SIDE_WHO_LIST
- if (target->GetTeam() != team && !allowTwoSideWhoList && !HasPermission(RBAC_PERM_TWO_SIDE_WHO_LIST))
+ if (target->GetTeam() != team && !HasPermission(RBAC_PERM_TWO_SIDE_WHO_LIST))
continue;
// player can see MODERATOR, GAME MASTER, ADMINISTRATOR only if CONFIG_GM_IN_WHO_LIST
@@ -573,14 +572,13 @@ void WorldSession::HandleAddFriendOpcodeCallBack(PreparedQueryResult result, std
team = Player::TeamForRace(fields[1].GetUInt8());
friendAccountId = fields[2].GetUInt32();
- if (HasPermission(RBAC_PERM_ALLOW_GM_FRIEND) || sWorld->getBoolConfig(CONFIG_ALLOW_GM_FRIEND) ||
- AccountMgr::IsPlayerAccount(AccountMgr::GetSecurity(friendAccountId, realmID)))
+ if (HasPermission(RBAC_PERM_ALLOW_GM_FRIEND) || AccountMgr::IsPlayerAccount(AccountMgr::GetSecurity(friendAccountId, realmID)))
{
if (friendGuid)
{
if (friendGuid == GetPlayer()->GetGUID())
friendResult = FRIEND_SELF;
- else if (GetPlayer()->GetTeam() != team && !sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_ADD_FRIEND) && !HasPermission(RBAC_PERM_TWO_SIDE_ADD_FRIEND))
+ else if (GetPlayer()->GetTeam() != team && !HasPermission(RBAC_PERM_TWO_SIDE_ADD_FRIEND))
friendResult = FRIEND_ENEMY;
else if (GetPlayer()->GetSocial()->HasFriend(GUID_LOPART(friendGuid)))
friendResult = FRIEND_ALREADY;