chore(Core/RBAC): Drop redundant AllowTwoSide configs (#25741)
Co-authored-by: blinkysc <blinkysc@users.noreply.github.com>
This commit is contained in:
@@ -4358,14 +4358,6 @@ AllowTwoSide.Interaction.Calendar = 0
|
|||||||
|
|
||||||
AllowTwoSide.Interaction.Chat = 0
|
AllowTwoSide.Interaction.Chat = 0
|
||||||
|
|
||||||
#
|
|
||||||
# AllowTwoSide.Interaction.Emote
|
|
||||||
# Description: Allow emote messages between factions (e.g. "/e looks into the sky")
|
|
||||||
# Default: 0 - (Disabled)
|
|
||||||
# 1 - (Enabled)
|
|
||||||
|
|
||||||
AllowTwoSide.Interaction.Emote = 0
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# AllowTwoSide.Interaction.Channel
|
# AllowTwoSide.Interaction.Channel
|
||||||
# Description: Allow channel chat between factions.
|
# Description: Allow channel chat between factions.
|
||||||
@@ -4407,30 +4399,6 @@ AllowTwoSide.Interaction.Arena = 0
|
|||||||
|
|
||||||
AllowTwoSide.Interaction.Auction = 0
|
AllowTwoSide.Interaction.Auction = 0
|
||||||
|
|
||||||
#
|
|
||||||
# AllowTwoSide.Interaction.Mail
|
|
||||||
# Description: Allow sending mails between factions.
|
|
||||||
# Default: 0 - (Disabled)
|
|
||||||
# 1 - (Enabled)
|
|
||||||
|
|
||||||
AllowTwoSide.Interaction.Mail = 0
|
|
||||||
|
|
||||||
#
|
|
||||||
# AllowTwoSide.AddFriend
|
|
||||||
# Description: Allow adding friends from other faction the friends list.
|
|
||||||
# Default: 0 - (Disabled)
|
|
||||||
# 1 - (Enabled)
|
|
||||||
|
|
||||||
AllowTwoSide.AddFriend = 0
|
|
||||||
|
|
||||||
#
|
|
||||||
# AllowTwoSide.Trade
|
|
||||||
# Description: Allow trading between factions.
|
|
||||||
# Default: 0 - (Disabled)
|
|
||||||
# 1 - (Enabled)
|
|
||||||
|
|
||||||
AllowTwoSide.Trade = 0
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# TalentsInspecting
|
# TalentsInspecting
|
||||||
# Description: Allow inspecting characters from the opposing faction.
|
# Description: Allow inspecting characters from the opposing faction.
|
||||||
|
|||||||
@@ -214,7 +214,7 @@ void WorldSession::HandleSendMail(WorldPacket& recvData)
|
|||||||
|
|
||||||
uint32 rc_account = receive ? receive->GetSession()->GetAccountId() : sCharacterCache->GetCharacterAccountIdByGuid(receiverGuid);
|
uint32 rc_account = receive ? receive->GetSession()->GetAccountId() : sCharacterCache->GetCharacterAccountIdByGuid(receiverGuid);
|
||||||
|
|
||||||
if (/*!accountBound*/ GetAccountId() != rc_account && !sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_INTERACTION_MAIL) && player->GetTeamId() != rc_teamId && !HasPermission(rbac::RBAC_PERM_TWO_SIDE_INTERACTION_MAIL))
|
if (/*!accountBound*/ GetAccountId() != rc_account && player->GetTeamId() != rc_teamId && !HasPermission(rbac::RBAC_PERM_TWO_SIDE_INTERACTION_MAIL))
|
||||||
{
|
{
|
||||||
player->SendMailResult(0, MAIL_SEND, MAIL_ERR_NOT_YOUR_TEAM);
|
player->SendMailResult(0, MAIL_SEND, MAIL_ERR_NOT_YOUR_TEAM);
|
||||||
return;
|
return;
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ void WorldSession::HandleAddFriendOpcode(WorldPacket& recv_data)
|
|||||||
{
|
{
|
||||||
if (friendGuid == GetPlayer()->GetGUID())
|
if (friendGuid == GetPlayer()->GetGUID())
|
||||||
friendResult = FRIEND_SELF;
|
friendResult = FRIEND_SELF;
|
||||||
else if (GetPlayer()->GetTeamId() != teamId && !sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_ADD_FRIEND) && !HasPermission(rbac::RBAC_PERM_TWO_SIDE_ADD_FRIEND))
|
else if (GetPlayer()->GetTeamId() != teamId && !HasPermission(rbac::RBAC_PERM_TWO_SIDE_ADD_FRIEND))
|
||||||
friendResult = FRIEND_ENEMY;
|
friendResult = FRIEND_ENEMY;
|
||||||
else if (GetPlayer()->GetSocial()->HasFriend(friendGuid))
|
else if (GetPlayer()->GetSocial()->HasFriend(friendGuid))
|
||||||
friendResult = FRIEND_ALREADY;
|
friendResult = FRIEND_ALREADY;
|
||||||
|
|||||||
@@ -723,7 +723,6 @@ void WorldSession::HandleInitiateTradeOpcode(WorldPacket& recvPacket)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (pOther->GetTeamId() != _player->GetTeamId() &&
|
if (pOther->GetTeamId() != _player->GetTeamId() &&
|
||||||
!sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_TRADE) &&
|
|
||||||
!GetPlayer()->GetSession()->HasPermission(rbac::RBAC_PERM_ALLOW_TWO_SIDE_TRADE))
|
!GetPlayer()->GetSession()->HasPermission(rbac::RBAC_PERM_ALLOW_TWO_SIDE_TRADE))
|
||||||
{
|
{
|
||||||
info.Status = TRADE_STATUS_WRONG_FACTION;
|
info.Status = TRADE_STATUS_WRONG_FACTION;
|
||||||
|
|||||||
@@ -204,10 +204,6 @@ void WorldConfig::BuildConfigCache()
|
|||||||
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_INTERACTION_GUILD, "AllowTwoSide.Interaction.Guild", false);
|
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_INTERACTION_GUILD, "AllowTwoSide.Interaction.Guild", false);
|
||||||
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_INTERACTION_ARENA, "AllowTwoSide.Interaction.Arena", false);
|
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_INTERACTION_ARENA, "AllowTwoSide.Interaction.Arena", false);
|
||||||
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_INTERACTION_AUCTION, "AllowTwoSide.Interaction.Auction", false);
|
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_INTERACTION_AUCTION, "AllowTwoSide.Interaction.Auction", false);
|
||||||
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_INTERACTION_MAIL, "AllowTwoSide.Interaction.Mail", false);
|
|
||||||
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_ADD_FRIEND, "AllowTwoSide.AddFriend", false);
|
|
||||||
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_TRADE, "AllowTwoSide.Trade", false);
|
|
||||||
SetConfigValue<bool>(CONFIG_ALLOW_TWO_SIDE_INTERACTION_EMOTE, "AllowTwoSide.Interaction.Emote", false);
|
|
||||||
|
|
||||||
SetConfigValue<uint32>(CONFIG_MIN_PLAYER_NAME, "MinPlayerName", 2, ConfigValueCache::Reloadable::Yes, [](uint32 const& value) { return value > 0 && value <= MAX_PLAYER_NAME; }, "> 0 && <= MAX_PLAYER_NAME");
|
SetConfigValue<uint32>(CONFIG_MIN_PLAYER_NAME, "MinPlayerName", 2, ConfigValueCache::Reloadable::Yes, [](uint32 const& value) { return value > 0 && value <= MAX_PLAYER_NAME; }, "> 0 && <= MAX_PLAYER_NAME");
|
||||||
SetConfigValue<uint32>(CONFIG_MIN_CHARTER_NAME, "MinCharterName", 2, ConfigValueCache::Reloadable::Yes, [](uint32 const& value) { return value > 0 && value <= MAX_CHARTER_NAME; }, "> 0 && <= MAX_CHARTER_NAME");
|
SetConfigValue<uint32>(CONFIG_MIN_CHARTER_NAME, "MinCharterName", 2, ConfigValueCache::Reloadable::Yes, [](uint32 const& value) { return value > 0 && value <= MAX_CHARTER_NAME; }, "> 0 && <= MAX_CHARTER_NAME");
|
||||||
|
|||||||
@@ -35,9 +35,6 @@ enum ServerConfigs
|
|||||||
CONFIG_ALLOW_TWO_SIDE_INTERACTION_GUILD,
|
CONFIG_ALLOW_TWO_SIDE_INTERACTION_GUILD,
|
||||||
CONFIG_ALLOW_TWO_SIDE_INTERACTION_ARENA,
|
CONFIG_ALLOW_TWO_SIDE_INTERACTION_ARENA,
|
||||||
CONFIG_ALLOW_TWO_SIDE_INTERACTION_AUCTION,
|
CONFIG_ALLOW_TWO_SIDE_INTERACTION_AUCTION,
|
||||||
CONFIG_ALLOW_TWO_SIDE_INTERACTION_MAIL,
|
|
||||||
CONFIG_ALLOW_TWO_SIDE_ADD_FRIEND,
|
|
||||||
CONFIG_ALLOW_TWO_SIDE_TRADE,
|
|
||||||
CONFIG_ALL_TAXI_PATHS,
|
CONFIG_ALL_TAXI_PATHS,
|
||||||
CONFIG_INSTANCE_IGNORE_LEVEL,
|
CONFIG_INSTANCE_IGNORE_LEVEL,
|
||||||
CONFIG_INSTANCE_IGNORE_RAID,
|
CONFIG_INSTANCE_IGNORE_RAID,
|
||||||
@@ -118,7 +115,6 @@ enum ServerConfigs
|
|||||||
CONFIG_CLOSE_IDLE_CONNECTIONS,
|
CONFIG_CLOSE_IDLE_CONNECTIONS,
|
||||||
CONFIG_LFG_LOCATION_ALL,
|
CONFIG_LFG_LOCATION_ALL,
|
||||||
CONFIG_PRELOAD_ALL_NON_INSTANCED_MAP_GRIDS,
|
CONFIG_PRELOAD_ALL_NON_INSTANCED_MAP_GRIDS,
|
||||||
CONFIG_ALLOW_TWO_SIDE_INTERACTION_EMOTE,
|
|
||||||
CONFIG_ITEMDELETE_METHOD,
|
CONFIG_ITEMDELETE_METHOD,
|
||||||
CONFIG_ITEMDELETE_VENDOR,
|
CONFIG_ITEMDELETE_VENDOR,
|
||||||
CONFIG_DEBUG_BATTLEGROUND,
|
CONFIG_DEBUG_BATTLEGROUND,
|
||||||
|
|||||||
Reference in New Issue
Block a user