Core/Logging: Removed a bunch of useless "received X" logs

This commit is contained in:
Shauren
2015-04-21 21:26:15 +02:00
parent fc5d2a05df
commit 7e5df6d504
17 changed files with 69 additions and 305 deletions

View File

@@ -1207,7 +1207,6 @@ void WorldSession::HandleTutorialFlag(WorldPackets::Misc::TutorialSetFlag& packe
void WorldSession::HandleSetWatchedFactionOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_SET_WATCHED_FACTION");
uint32 fact;
recvData >> fact;
GetPlayer()->SetUInt32Value(PLAYER_FIELD_WATCHED_FACTION_INDEX, fact);
@@ -1215,7 +1214,6 @@ void WorldSession::HandleSetWatchedFactionOpcode(WorldPacket& recvData)
void WorldSession::HandleSetFactionInactiveOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_SET_FACTION_INACTIVE");
uint32 replistid;
uint8 inactive;
recvData >> replistid >> inactive;
@@ -1412,8 +1410,6 @@ void WorldSession::HandleSetPlayerDeclinedNames(WorldPacket& recvData)
void WorldSession::HandleAlterAppearance(WorldPackets::Character::AlterApperance& packet)
{
TC_LOG_DEBUG("network", "CMSG_ALTER_APPEARANCE");
BarberShopStyleEntry const* bs_hair = sBarberShopStyleStore.LookupEntry(packet.NewHairStyle);
if (!bs_hair || bs_hair->Type != 0 || bs_hair->Race != _player->getRace() || bs_hair->Sex != _player->getGender())
return;
@@ -1632,8 +1628,6 @@ void WorldSession::HandleCharCustomizeCallback(PreparedQueryResult result, World
void WorldSession::HandleEquipmentSetSave(WorldPackets::EquipmentSet::SaveEquipmentSet& packet)
{
TC_LOG_DEBUG("network", "CMSG_EQUIPMENT_SET_SAVE");
if (packet.Set.SetID >= MAX_EQUIPMENT_SET_INDEX) // client set slots amount
return;
@@ -1664,15 +1658,11 @@ void WorldSession::HandleEquipmentSetSave(WorldPackets::EquipmentSet::SaveEquipm
void WorldSession::HandleDeleteEquipmentSet(WorldPackets::EquipmentSet::DeleteEquipmentSet& packet)
{
TC_LOG_DEBUG("network", "CMSG_DELETE_EQUIPMENT_SET");
_player->DeleteEquipmentSet(packet.ID);
}
void WorldSession::HandleUseEquipmentSet(WorldPackets::EquipmentSet::UseEquipmentSet& packet)
{
TC_LOG_DEBUG("network", "CMSG_USE_EQUIPMENT_SET");
ObjectGuid ignoredItemGuid;
ignoredItemGuid.SetRawValue(0, 1);

View File

@@ -641,7 +641,6 @@ void WorldSession::HandleChatIgnoredOpcode(WorldPacket& recvData)
{
ObjectGuid guid;
uint8 unk;
//TC_LOG_DEBUG("network", "WORLD: Received CMSG_CHAT_IGNORED");
recvData >> unk; // probably related to spam reporting
guid[5] = recvData.ReadBit();

View File

@@ -63,8 +63,6 @@ void WorldSession::SendPartyResult(PartyOperation operation, const std::string&
void WorldSession::HandleGroupInviteOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_GROUP_INVITE");
ObjectGuid crossRealmGuid; // unused
recvData.read_skip<uint32>(); // Non-zero in cross realm invites
@@ -326,8 +324,6 @@ void WorldSession::HandleGroupInviteOpcode(WorldPacket& recvData)
void WorldSession::HandleGroupInviteResponseOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_GROUP_INVITE_RESPONSE");
recvData.ReadBit(); // unk always 0
bool accept = recvData.ReadBit();
@@ -403,8 +399,6 @@ void WorldSession::HandleGroupInviteResponseOpcode(WorldPacket& recvData)
void WorldSession::HandleGroupUninviteOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_PARTY_UNINVITE");
ObjectGuid guid;
std::string reason;
recvData >> guid;
@@ -446,8 +440,6 @@ void WorldSession::HandleGroupUninviteOpcode(WorldPacket& recvData)
void WorldSession::HandleGroupSetLeaderOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_SET_ROLE");
ObjectGuid guid;
recvData >> guid;
@@ -467,8 +459,6 @@ void WorldSession::HandleGroupSetLeaderOpcode(WorldPacket& recvData)
void WorldSession::HandleGroupSetRolesOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_GROUP_SET_ROLES");
uint32 newRole;
ObjectGuid guid1; // Assigner GUID
ObjectGuid guid2; // Target GUID
@@ -545,8 +535,6 @@ void WorldSession::HandleGroupSetRolesOpcode(WorldPacket& recvData)
void WorldSession::HandleGroupDisbandOpcode(WorldPacket& /*recvData*/)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_LEAVE_GROUP");
Group* grp = GetPlayer()->GetGroup();
if (!grp)
return;
@@ -568,8 +556,6 @@ void WorldSession::HandleGroupDisbandOpcode(WorldPacket& /*recvData*/)
void WorldSession::HandleLootMethodOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_LOOT_METHOD");
uint32 lootMethod;
ObjectGuid lootMaster;
uint32 lootThreshold;
@@ -645,8 +631,6 @@ void WorldSession::HandleMinimapPingOpcode(WorldPacket& recvData)
void WorldSession::HandleRandomRollOpcode(WorldPackets::Misc::RandomRollClient& packet)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_RANDOM_ROLL");
uint32 minimum, maximum, roll;
minimum = packet.Min;
maximum = packet.Max;
@@ -712,8 +696,6 @@ void WorldSession::HandleRaidTargetUpdateOpcode(WorldPacket& recvData)
void WorldSession::HandleGroupRaidConvertOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_CONVERT_RAID");
Group* group = GetPlayer()->GetGroup();
if (!group)
return;
@@ -750,8 +732,6 @@ void WorldSession::HandleGroupRequestJoinUpdates(WorldPacket& /*recvData*/)
void WorldSession::HandleGroupChangeSubGroupOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_CHANGE_SUB_GROUP");
// we will get correct pointer for group here, so we don't have to check if group is BG raid
Group* group = GetPlayer()->GetGroup();
if (!group)
@@ -788,7 +768,6 @@ void WorldSession::HandleGroupChangeSubGroupOpcode(WorldPacket& recvData)
void WorldSession::HandleGroupSwapSubGroupOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_SWAP_SUB_GROUPS");
std::string unk1;
std::string unk2;
@@ -798,8 +777,6 @@ void WorldSession::HandleGroupSwapSubGroupOpcode(WorldPacket& recvData)
void WorldSession::HandleGroupAssistantLeaderOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_SET_ASSISTANT_LEADER");
Group* group = GetPlayer()->GetGroup();
if (!group)
return;
@@ -851,8 +828,6 @@ void WorldSession::HandlePartyAssignmentOpcode(WorldPacket& recvData)
void WorldSession::HandleRaidReadyCheckOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_DO_READY_CHECK");
Group* group = GetPlayer()->GetGroup();
if (!group)
return;
@@ -1125,7 +1100,6 @@ void WorldSession::BuildPartyMemberStatsChangedPacket(Player* player, WorldPacke
/*this procedure handles clients CMSG_REQUEST_PARTY_MEMBER_STATS request*/
void WorldSession::HandleRequestPartyMemberStatsOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_REQUEST_PARTY_MEMBER_STATS");
ObjectGuid Guid;
recvData >> Guid;
@@ -1310,8 +1284,6 @@ void WorldSession::HandleRequestRaidInfoOpcode(WorldPacket& /*recvData*/)
void WorldSession::HandleOptOutOfLootOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_OPT_OUT_OF_LOOT");
bool passOnLoot;
recvData >> passOnLoot; // 1 always pass, 0 do not pass
@@ -1328,8 +1300,6 @@ void WorldSession::HandleOptOutOfLootOpcode(WorldPacket& recvData)
void WorldSession::HandleRolePollBeginOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_ROLE_POLL_BEGIN");
Group* group = GetPlayer()->GetGroup();
if (!group)
return;

View File

@@ -24,8 +24,6 @@
void WorldSession::HandleGuildFinderAddRecruit(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_LF_GUILD_ADD_RECRUIT");
if (sGuildFinderMgr->GetAllMembershipRequestsForPlayer(GetPlayer()->GetGUID()).size() == 10)
return;
@@ -73,7 +71,6 @@ void WorldSession::HandleGuildFinderAddRecruit(WorldPacket& recvPacket)
void WorldSession::HandleGuildFinderBrowse(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_LF_GUILD_BROWSE");
uint32 classRoles = 0;
uint32 availability = 0;
uint32 guildInterests = 0;
@@ -175,7 +172,6 @@ void WorldSession::HandleGuildFinderBrowse(WorldPacket& recvPacket)
void WorldSession::HandleGuildFinderDeclineRecruit(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_LF_GUILD_DECLINE_RECRUIT");
if (!GetPlayer()->GetGuild())
{
recvPacket.rfinish();
@@ -273,8 +269,6 @@ void WorldSession::HandleGuildFinderGetApplications(WorldPacket& /*recvPacket*/)
// Lists all recruits for a guild - Misses times
void WorldSession::HandleGuildFinderGetRecruits(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_LF_GUILD_GET_RECRUITS");
uint32 unkTime = 0;
recvPacket >> unkTime;
@@ -343,8 +337,6 @@ void WorldSession::HandleGuildFinderGetRecruits(WorldPacket& recvPacket)
void WorldSession::HandleGuildFinderPostRequest(WorldPacket& /*recvPacket*/)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_LF_GUILD_POST_REQUEST"); // Empty opcode
Player* player = GetPlayer();
Guild* guild = player->GetGuild();
@@ -376,8 +368,6 @@ void WorldSession::HandleGuildFinderPostRequest(WorldPacket& /*recvPacket*/)
void WorldSession::HandleGuildFinderRemoveRecruit(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_LF_GUILD_REMOVE_RECRUIT");
ObjectGuid guildGuid;
guildGuid[0] = recvPacket.ReadBit();
@@ -407,8 +397,6 @@ void WorldSession::HandleGuildFinderRemoveRecruit(WorldPacket& recvPacket)
// Sent any time a guild master sets an option in the interface and when listing / unlisting his guild
void WorldSession::HandleGuildFinderSetGuildPost(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_LF_GUILD_SET_GUILD_POST");
uint32 classRoles = 0;
uint32 availability = 0;
uint32 guildInterests = 0;

View File

@@ -66,8 +66,6 @@ void WorldSession::HandleGuildOfficerRemoveMember(WorldPackets::Guild::GuildOffi
void WorldSession::HandleGuildAcceptInvite(WorldPackets::Guild::AcceptGuildInvite& /*invite*/)
{
TC_LOG_DEBUG("guild", "CMSG_ACCEPT_GUILD_INVITE [%s]", GetPlayerInfo().c_str());
if (!GetPlayer()->GetGuildId())
if (Guild* guild = sGuildMgr->GetGuildById(GetPlayer()->GetGuildIdInvited()))
guild->HandleAcceptMember(this);
@@ -75,16 +73,12 @@ void WorldSession::HandleGuildAcceptInvite(WorldPackets::Guild::AcceptGuildInvit
void WorldSession::HandleGuildDeclineInvitation(WorldPackets::Guild::GuildDeclineInvitation& /*decline*/)
{
TC_LOG_DEBUG("guild", "CMSG_GUILD_DECLINE_INVITATION [%s]", GetPlayerInfo().c_str());
GetPlayer()->SetGuildIdInvited(UI64LIT(0));
GetPlayer()->SetInGuild(UI64LIT(0));
}
void WorldSession::HandleGuildGetRoster(WorldPackets::Guild::GuildGetRoster& /*packet*/)
{
TC_LOG_DEBUG("guild", "CMSG_GUILD_ROSTER [%s]", GetPlayerInfo().c_str());
if (Guild* guild = GetPlayer()->GetGuild())
guild->HandleRoster(this);
else
@@ -120,16 +114,12 @@ void WorldSession::HandleGuildAssignRank(WorldPackets::Guild::GuildAssignMemberR
void WorldSession::HandleGuildLeave(WorldPackets::Guild::GuildLeave& /*leave*/)
{
TC_LOG_DEBUG("guild", "CMSG_GUILD_LEAVE [%s]", GetPlayerInfo().c_str());
if (Guild* guild = GetPlayer()->GetGuild())
guild->HandleLeaveMember(this);
}
void WorldSession::HandleGuildDelete(WorldPackets::Guild::GuildDelete& /*packet*/)
{
TC_LOG_DEBUG("guild", "CMSG_GUILD_DELETE [%s]", GetPlayerInfo().c_str());
if (Guild* guild = GetPlayer()->GetGuild())
guild->HandleDelete(this);
}
@@ -220,16 +210,12 @@ void WorldSession::HandleGuildEventLogQuery(WorldPackets::Guild::GuildEventLogQu
void WorldSession::HandleGuildBankMoneyWithdrawn(WorldPackets::Guild::GuildBankRemainingWithdrawMoneyQuery& /*packet*/)
{
TC_LOG_DEBUG("guild", "CMSG_GUILD_BANK_MONEY_WITHDRAWN [%s]", GetPlayerInfo().c_str());
if (Guild* guild = GetPlayer()->GetGuild())
guild->SendMoneyInfo(this);
}
void WorldSession::HandleGuildPermissionsQuery(WorldPackets::Guild::GuildPermissionsQuery& /* packet */)
{
TC_LOG_DEBUG("guild", "CMSG_GUILD_PERMISSIONS_QUERY [%s]", GetPlayerInfo().c_str());
if (Guild* guild = GetPlayer()->GetGuild())
guild->SendPermissions(this);
}
@@ -288,8 +274,6 @@ void WorldSession::HandleGuildBankWithdrawMoney(WorldPackets::Guild::GuildBankWi
void WorldSession::HandleGuildBankSwapItems(WorldPackets::Guild::GuildBankSwapItems& packet)
{
TC_LOG_DEBUG("guild", "CMSG_GUILD_BANK_SWAP_ITEMS [%s]", GetPlayerInfo().c_str());
if (!GetPlayer()->GetGameObjectIfCanInteractWith(packet.Banker, GAMEOBJECT_TYPE_GUILD_BANK))
return;
@@ -373,8 +357,6 @@ void WorldSession::HandleGuildSetRankPermissions(WorldPackets::Guild::GuildSetRa
void WorldSession::HandleGuildRequestPartyState(WorldPackets::Guild::RequestGuildPartyState& packet)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_GUILD_REQUEST_PARTY_STATE");
if (Guild* guild = sGuildMgr->GetGuildByGuid(packet.GuildGUID))
guild->HandleGuildPartyRequest(this);
}
@@ -418,7 +400,6 @@ void WorldSession::HandleRequestGuildRewardsList(WorldPackets::Guild::RequestGui
void WorldSession::HandleGuildQueryNews(WorldPackets::Guild::GuildQueryNews& newsQuery)
{
TC_LOG_DEBUG("guild", "CMSG_GUILD_QUERY_NEWS [%s]", GetPlayerInfo().c_str());
if (Guild* guild = GetPlayer()->GetGuild())
if (guild->GetGUID() == newsQuery.GuildGUID)
guild->SendNewsUpdate(this);

View File

@@ -496,7 +496,6 @@ void WorldSession::HandleBuybackItem(WorldPackets::Item::BuyBackItem& packet)
void WorldSession::HandleBuyItemInSlotOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_BUY_ITEM_IN_SLOT");
ObjectGuid vendorguid, bagguid;
uint32 item, slot, count;
uint8 bagslot;
@@ -566,8 +565,6 @@ void WorldSession::HandleBuyItemOpcode(WorldPackets::Item::BuyItem& packet)
void WorldSession::HandleListInventoryOpcode(WorldPackets::NPC::Hello& packet)
{
TC_LOG_DEBUG("network", "WORLD: Recvd CMSG_LIST_INVENTORY");
if (!GetPlayer()->IsAlive())
return;
@@ -762,8 +759,6 @@ void WorldSession::SendItemEnchantTimeUpdate(ObjectGuid Playerguid, ObjectGuid I
void WorldSession::HandleWrapItem(WorldPackets::Item::WrapItem& packet)
{
TC_LOG_DEBUG("network", "Received opcode CMSG_WRAP_ITEM");
if (packet.Inv.Items.size() != 2)
{
TC_LOG_ERROR("network", "HandleWrapItem - Invalid itemCount (" SZFMTD ")", packet.Inv.Items.size());
@@ -894,8 +889,6 @@ void WorldSession::HandleWrapItem(WorldPackets::Item::WrapItem& packet)
void WorldSession::HandleSocketOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_SOCKET_GEMS");
ObjectGuid item_guid;
ObjectGuid gem_guids[MAX_GEM_SOCKETS];
@@ -1103,8 +1096,6 @@ void WorldSession::HandleSocketOpcode(WorldPacket& recvData)
void WorldSession::HandleCancelTempEnchantmentOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_CANCEL_TEMP_ENCHANTMENT");
uint32 slot;
recvData >> slot;
@@ -1141,7 +1132,6 @@ void WorldSession::HandleGetItemPurchaseData(WorldPackets::Item::GetItemPurchase
void WorldSession::HandleItemRefund(WorldPacket &recvData)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_ITEM_PURCHASE_REFUND");
ObjectGuid guid;
recvData >> guid; // item guid
@@ -1189,7 +1179,6 @@ void WorldSession::HandleItemTextQuery(WorldPacket& recvData )
void WorldSession::HandleTransmogrifyItems(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_TRANSMOGRIFY_ITEMS");
Player* player = GetPlayer();
// Read data

View File

@@ -35,7 +35,6 @@
void WorldSession::HandleAutostoreLootItemOpcode(WorldPackets::Loot::LootItem& packet)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_AUTOSTORE_LOOT_ITEM");
Player* player = GetPlayer();
ObjectGuid lguid = player->GetLootGUID();
@@ -105,8 +104,6 @@ void WorldSession::HandleAutostoreLootItemOpcode(WorldPackets::Loot::LootItem& p
void WorldSession::HandleLootMoneyOpcode(WorldPackets::Loot::LootMoney& /*packet*/)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_LOOT_MONEY");
Player* player = GetPlayer();
ObjectGuid guid = player->GetLootGUID();
if (!guid)
@@ -231,8 +228,6 @@ void WorldSession::HandleLootMoneyOpcode(WorldPackets::Loot::LootMoney& /*packet
void WorldSession::HandleLootOpcode(WorldPackets::Loot::LootUnit& packet)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_LOOT");
// Check possible cheat
if (!GetPlayer()->IsAlive() || !packet.Unit.IsCreatureOrVehicle())
return;
@@ -246,8 +241,6 @@ void WorldSession::HandleLootOpcode(WorldPackets::Loot::LootUnit& packet)
void WorldSession::HandleLootReleaseOpcode(WorldPackets::Loot::LootRelease& packet)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_LOOT_RELEASE");
// cheaters can modify lguid to prevent correct apply loot release code and re-loot
// use internal stored guid
ObjectGuid lguid = GetPlayer()->GetLootGUID();

View File

@@ -47,7 +47,6 @@
#include "ScriptMgr.h"
#include "MapManager.h"
#include "InstanceScript.h"
#include "GameObjectAI.h"
#include "Group.h"
#include "AccountMgr.h"
#include "Spell.h"
@@ -57,14 +56,11 @@
#include "CharacterPackets.h"
#include "ClientConfigPackets.h"
#include "MiscPackets.h"
#include "NPCPackets.h"
#include "AchievementPackets.h"
#include "WhoPackets.h"
void WorldSession::HandleRepopRequest(WorldPackets::Misc::RepopRequest& /*packet*/)
{
TC_LOG_DEBUG("network", "WORLD: Recvd CMSG_REPOP_REQUEST Message");
if (GetPlayer()->IsAlive() || GetPlayer()->HasFlag(PLAYER_FLAGS, PLAYER_FLAGS_GHOST))
return;
@@ -89,91 +85,6 @@ void WorldSession::HandleRepopRequest(WorldPackets::Misc::RepopRequest& /*packet
GetPlayer()->RepopAtGraveyard();
}
void WorldSession::HandleGossipSelectOptionOpcode(WorldPackets::NPC::GossipSelectOption& packet)
{
if (!_player->PlayerTalkClass->GetGossipMenu().GetItem(packet.GossipIndex))
return;
// Prevent cheating on C++ scripted menus
if (_player->PlayerTalkClass->GetGossipMenu().GetSenderGUID() != packet.GossipUnit)
return;
Creature* unit = nullptr;
GameObject* go = nullptr;
if (packet.GossipUnit.IsCreatureOrVehicle())
{
unit = GetPlayer()->GetNPCIfCanInteractWith(packet.GossipUnit, UNIT_NPC_FLAG_NONE);
if (!unit)
{
TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - %s not found or you can't interact with him.", packet.GossipUnit.ToString().c_str());
return;
}
}
else if (packet.GossipUnit.IsGameObject())
{
go = _player->GetMap()->GetGameObject(packet.GossipUnit);
if (!go)
{
TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - %s not found.", packet.GossipUnit.ToString().c_str());
return;
}
}
else
{
TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - unsupported %s.", packet.GossipUnit.ToString().c_str());
return;
}
// remove fake death
if (GetPlayer()->HasUnitState(UNIT_STATE_DIED))
GetPlayer()->RemoveAurasByType(SPELL_AURA_FEIGN_DEATH);
if ((unit && unit->GetCreatureTemplate()->ScriptID != unit->LastUsedScriptID) || (go && go->GetGOInfo()->ScriptId != go->LastUsedScriptID))
{
TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - Script reloaded while in use, ignoring and set new scipt id");
if (unit)
unit->LastUsedScriptID = unit->GetCreatureTemplate()->ScriptID;
if (go)
go->LastUsedScriptID = go->GetGOInfo()->ScriptId;
_player->PlayerTalkClass->SendCloseGossip();
return;
}
if (!packet.PromotionCode.empty())
{
if (unit)
{
unit->AI()->sGossipSelectCode(_player, packet.GossipID, packet.GossipIndex, packet.PromotionCode.c_str());
if (!sScriptMgr->OnGossipSelectCode(_player, unit, _player->PlayerTalkClass->GetGossipOptionSender(packet.GossipIndex), _player->PlayerTalkClass->GetGossipOptionAction(packet.GossipIndex), packet.PromotionCode.c_str()))
_player->OnGossipSelect(unit, packet.GossipIndex, packet.GossipID);
}
else
{
go->AI()->GossipSelectCode(_player, packet.GossipID, packet.GossipIndex, packet.PromotionCode.c_str());
if (!sScriptMgr->OnGossipSelectCode(_player, go, _player->PlayerTalkClass->GetGossipOptionSender(packet.GossipIndex), _player->PlayerTalkClass->GetGossipOptionAction(packet.GossipIndex), packet.PromotionCode.c_str()))
_player->OnGossipSelect(go, packet.GossipIndex, packet.GossipID);
}
}
else
{
if (unit)
{
unit->AI()->sGossipSelect(_player, packet.GossipID, packet.GossipIndex);
if (!sScriptMgr->OnGossipSelect(_player, unit, _player->PlayerTalkClass->GetGossipOptionSender(packet.GossipIndex), _player->PlayerTalkClass->GetGossipOptionAction(packet.GossipIndex)))
_player->OnGossipSelect(unit, packet.GossipIndex, packet.GossipID);
}
else
{
go->AI()->GossipSelect(_player, packet.GossipID, packet.GossipIndex);
if (!sScriptMgr->OnGossipSelect(_player, go, _player->PlayerTalkClass->GetGossipOptionSender(packet.GossipIndex), _player->PlayerTalkClass->GetGossipOptionAction(packet.GossipIndex)))
_player->OnGossipSelect(go, packet.GossipIndex, packet.GossipID);
}
}
}
void WorldSession::HandleWhoOpcode(WorldPackets::Who::WhoRequestPkt& whoRequest)
{
WorldPackets::Who::WhoRequest& request = whoRequest.Request;
@@ -346,8 +257,6 @@ void WorldSession::HandleWhoOpcode(WorldPackets::Who::WhoRequestPkt& whoRequest)
void WorldSession::HandleLogoutRequestOpcode(WorldPackets::Character::LogoutRequest& /*logoutRequest*/)
{
TC_LOG_DEBUG("network", "WORLD: Recvd CMSG_LOGOUT_REQUEST Message, security - %u", GetSecurity());
ObjectGuid lguid = GetPlayer()->GetLootGUID();
if (!lguid.IsEmpty())
DoLootRelease(lguid);
@@ -398,8 +307,6 @@ void WorldSession::HandleLogoutRequestOpcode(WorldPackets::Character::LogoutRequ
void WorldSession::HandleLogoutCancelOpcode(WorldPackets::Character::LogoutCancel& /*logoutCancel*/)
{
TC_LOG_DEBUG("network", "WORLD: Recvd CMSG_LOGOUT_CANCEL Message");
// Player have already logged out serverside, too late to cancel
if (!GetPlayer())
return;
@@ -514,11 +421,6 @@ void WorldSession::HandleBugReportOpcode(WorldPacket& recvData)
recvData >> typelen;
type = recvData.ReadString(typelen);
if (suggestion == 0)
TC_LOG_DEBUG("network", "WORLD: Received CMSG_BUG_REPORT [Bug Report]");
else
TC_LOG_DEBUG("network", "WORLD: Received CMSG_BUG_REPORT [Suggestion]");
TC_LOG_DEBUG("network", "%s", type.c_str());
TC_LOG_DEBUG("network", "%s", content.c_str());
@@ -532,8 +434,6 @@ void WorldSession::HandleBugReportOpcode(WorldPacket& recvData)
void WorldSession::HandleReclaimCorpse(WorldPackets::Misc::ReclaimCorpse& /*packet*/)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_RECLAIM_CORPSE");
if (_player->IsAlive())
return;
@@ -566,8 +466,6 @@ void WorldSession::HandleReclaimCorpse(WorldPackets::Misc::ReclaimCorpse& /*pack
void WorldSession::HandleResurrectResponse(WorldPackets::Misc::ResurrectResponse& packet)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_RESURRECT_RESPONSE");
if (GetPlayer()->IsAlive())
return;
@@ -803,13 +701,12 @@ void WorldSession::HandleSetActionButtonOpcode(WorldPackets::Spells::SetActionBu
void WorldSession::HandleCompleteCinematic(WorldPacket& /*recvData*/)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_COMPLETE_CINEMATIC");
}
void WorldSession::HandleNextCinematicCamera(WorldPacket& /*recvData*/)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_NEXT_CINEMATIC_CAMERA");
}
void WorldSession::HandleSetActionBarToggles(WorldPackets::Character::SetActionBarToggles& packet)
{
if (!GetPlayer()) // ignore until not logged (check needed because STATUS_AUTHED)
@@ -847,8 +744,6 @@ void WorldSession::HandleWorldTeleportOpcode(WorldPacket& recvData)
recvData >> PositionZ;
recvData >> Orientation; // o (3.141593 = 180 degrees)
TC_LOG_DEBUG("network", "WORLD: Received CMSG_WORLD_TELEPORT");
if (GetPlayer()->IsInFlight())
{
TC_LOG_DEBUG("network", "Player '%s' (%s) in flight, ignore worldport command.",
@@ -919,8 +814,6 @@ void WorldSession::HandleWhoIsOpcode(WorldPackets::Who::WhoIsRequest& packet)
void WorldSession::HandleComplainOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_COMPLAIN");
uint8 spam_type; // 0 - mail, 1 - chat
ObjectGuid spammer_guid;
uint32 unk1 = 0;
@@ -961,8 +854,6 @@ void WorldSession::HandleComplainOpcode(WorldPacket& recvData)
void WorldSession::HandleRealmSplitOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "CMSG_REALM_SPLIT");
uint32 unk;
std::string split_date = "01/01/01";
recvData >> unk;
@@ -981,8 +872,6 @@ void WorldSession::HandleRealmSplitOpcode(WorldPacket& recvData)
void WorldSession::HandleFarSightOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_FAR_SIGHT");
bool apply;
recvData >> apply;
@@ -1005,8 +894,6 @@ void WorldSession::HandleFarSightOpcode(WorldPacket& recvData)
void WorldSession::HandleSetTitleOpcode(WorldPackets::Character::SetTitle& packet)
{
TC_LOG_DEBUG("network", "CMSG_SET_TITLE");
// -1 at none
if (packet.TitleID > 0 && packet.TitleID < MAX_TITLE_INDEX)
{
@@ -1021,8 +908,6 @@ void WorldSession::HandleSetTitleOpcode(WorldPackets::Character::SetTitle& packe
void WorldSession::HandleTimeSyncResponse(WorldPackets::Misc::TimeSyncResponse& packet)
{
TC_LOG_DEBUG("network", "CMSG_TIME_SYNC_RESPONSE");
// Prevent crashing server if queue is empty
if (_player->m_timeSyncQueue.empty())
{
@@ -1046,8 +931,6 @@ void WorldSession::HandleTimeSyncResponse(WorldPackets::Misc::TimeSyncResponse&
void WorldSession::HandleResetInstancesOpcode(WorldPacket& /*recvData*/)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_RESET_INSTANCES");
if (Group* group = _player->GetGroup())
{
if (group->IsLeader(_player->GetGUID()))
@@ -1217,8 +1100,6 @@ void WorldSession::HandleSetRaidDifficultyOpcode(WorldPackets::Misc::SetRaidDiff
void WorldSession::HandleMoveSetCanFlyAckOpcode(WorldPacket& /*recvData*/)
{
// fly mode on/off
TC_LOG_DEBUG("network", "WORLD: CMSG_MOVE_SET_CAN_FLY_ACK");
MovementInfo movementInfo;
_player->ValidateMovementInfo(&movementInfo);
@@ -1228,15 +1109,12 @@ void WorldSession::HandleMoveSetCanFlyAckOpcode(WorldPacket& /*recvData*/)
void WorldSession::HandleRequestPetInfoOpcode(WorldPacket& /*recvData */)
{
/*
TC_LOG_DEBUG("network", "WORLD: CMSG_REQUEST_PET_INFO");
recvData.hexlike();
*/
}
void WorldSession::HandleSetTaxiBenchmarkOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_SET_TAXI_BENCHMARK_MODE");
uint8 mode;
recvData >> mode;
@@ -1291,8 +1169,6 @@ void WorldSession::HandleInstanceLockResponse(WorldPacket& recvPacket)
void WorldSession::HandleUpdateMissileTrajectory(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_UPDATE_MISSILE_TRAJECTORY");
ObjectGuid guid;
uint32 spellId;
float pitch, speed;
@@ -1364,8 +1240,6 @@ void WorldSession::HandleObjectUpdateRescuedOpcode(WorldPackets::Misc::ObjectUpd
void WorldSession::HandleSaveCUFProfiles(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_SAVE_CUF_PROFILES");
uint8 count = (uint8)recvPacket.ReadBits(20);
if (count > MAX_CUF_PROFILES)

View File

@@ -36,6 +36,7 @@
#include "Battleground.h"
#include "ScriptMgr.h"
#include "CreatureAI.h"
#include "GameObjectAI.h"
#include "SpellInfo.h"
#include "NPCPackets.h"
#include "MailPackets.h"
@@ -264,8 +265,6 @@ void WorldSession::SendTrainerBuyFailed(ObjectGuid guid, uint32 spellId, uint32
void WorldSession::HandleGossipHelloOpcode(WorldPackets::NPC::Hello& packet)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_GOSSIP_HELLO");
Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(packet.Unit, UNIT_NPC_FLAG_NONE);
if (!unit)
{
@@ -306,28 +305,41 @@ void WorldSession::HandleGossipHelloOpcode(WorldPackets::NPC::Hello& packet)
unit->AI()->sGossipHello(_player);
}
/*void WorldSession::HandleGossipSelectOptionOpcode(WorldPacket& recvData)
void WorldSession::HandleGossipSelectOptionOpcode(WorldPackets::NPC::GossipSelectOption& packet)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_GOSSIP_SELECT_OPTION");
if (!_player->PlayerTalkClass->GetGossipMenu().GetItem(packet.GossipIndex))
return;
uint32 option;
uint32 unk;
uint64 guid;
std::string code = "";
// Prevent cheating on C++ scripted menus
if (_player->PlayerTalkClass->GetGossipMenu().GetSenderGUID() != packet.GossipUnit)
return;
recvData >> guid >> unk >> option;
if (_player->PlayerTalkClass->GossipOptionCoded(option))
Creature* unit = nullptr;
GameObject* go = nullptr;
if (packet.GossipUnit.IsCreatureOrVehicle())
{
TC_LOG_DEBUG("network", "reading string");
recvData >> code;
TC_LOG_DEBUG("network", "string read: %s", code.c_str());
unit = GetPlayer()->GetNPCIfCanInteractWith(packet.GossipUnit, UNIT_NPC_FLAG_NONE);
if (!unit)
{
TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - %s not found or you can't interact with him.", packet.GossipUnit.ToString().c_str());
return;
}
}
Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(guid, UNIT_NPC_FLAG_NONE);
if (!unit)
else if (packet.GossipUnit.IsGameObject())
{
TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - Unit (GUID: %u) not found or you can't interact with him.", uint32(GUID_LOPART(guid)));
go = _player->GetMap()->GetGameObject(packet.GossipUnit);
if (!go)
{
TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - %s not found.", packet.GossipUnit.ToString().c_str());
return;
}
}
else
{
TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - unsupported %s.", packet.GossipUnit.ToString().c_str());
return;
}
@@ -335,22 +347,52 @@ void WorldSession::HandleGossipHelloOpcode(WorldPackets::NPC::Hello& packet)
if (GetPlayer()->HasUnitState(UNIT_STATE_DIED))
GetPlayer()->RemoveAurasByType(SPELL_AURA_FEIGN_DEATH);
if (!code.empty())
if ((unit && unit->GetCreatureTemplate()->ScriptID != unit->LastUsedScriptID) || (go && go->GetGOInfo()->ScriptId != go->LastUsedScriptID))
{
if (!Script->GossipSelectWithCode(_player, unit, _player->PlayerTalkClass->GossipOptionSender (option), _player->PlayerTalkClass->GossipOptionAction(option), code.c_str()))
unit->OnGossipSelect (_player, option);
TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - Script reloaded while in use, ignoring and set new scipt id");
if (unit)
unit->LastUsedScriptID = unit->GetCreatureTemplate()->ScriptID;
if (go)
go->LastUsedScriptID = go->GetGOInfo()->ScriptId;
_player->PlayerTalkClass->SendCloseGossip();
return;
}
if (!packet.PromotionCode.empty())
{
if (unit)
{
unit->AI()->sGossipSelectCode(_player, packet.GossipID, packet.GossipIndex, packet.PromotionCode.c_str());
if (!sScriptMgr->OnGossipSelectCode(_player, unit, _player->PlayerTalkClass->GetGossipOptionSender(packet.GossipIndex), _player->PlayerTalkClass->GetGossipOptionAction(packet.GossipIndex), packet.PromotionCode.c_str()))
_player->OnGossipSelect(unit, packet.GossipIndex, packet.GossipID);
}
else
{
go->AI()->GossipSelectCode(_player, packet.GossipID, packet.GossipIndex, packet.PromotionCode.c_str());
if (!sScriptMgr->OnGossipSelectCode(_player, go, _player->PlayerTalkClass->GetGossipOptionSender(packet.GossipIndex), _player->PlayerTalkClass->GetGossipOptionAction(packet.GossipIndex), packet.PromotionCode.c_str()))
_player->OnGossipSelect(go, packet.GossipIndex, packet.GossipID);
}
}
else
{
if (!Script->OnGossipSelect (_player, unit, _player->PlayerTalkClass->GossipOptionSender (option), _player->PlayerTalkClass->GossipOptionAction (option)))
unit->OnGossipSelect (_player, option);
if (unit)
{
unit->AI()->sGossipSelect(_player, packet.GossipID, packet.GossipIndex);
if (!sScriptMgr->OnGossipSelect(_player, unit, _player->PlayerTalkClass->GetGossipOptionSender(packet.GossipIndex), _player->PlayerTalkClass->GetGossipOptionAction(packet.GossipIndex)))
_player->OnGossipSelect(unit, packet.GossipIndex, packet.GossipID);
}
else
{
go->AI()->GossipSelect(_player, packet.GossipID, packet.GossipIndex);
if (!sScriptMgr->OnGossipSelect(_player, go, _player->PlayerTalkClass->GetGossipOptionSender(packet.GossipIndex), _player->PlayerTalkClass->GetGossipOptionAction(packet.GossipIndex)))
_player->OnGossipSelect(go, packet.GossipIndex, packet.GossipID);
}
}
}*/
}
void WorldSession::HandleSpiritHealerActivate(WorldPackets::NPC::SpiritHealerActivate& packet)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_SPIRIT_HEALER_ACTIVATE");
Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(packet.Healer, UNIT_NPC_FLAG_SPIRITHEALER);
if (!unit)
{
@@ -468,8 +510,6 @@ void WorldSession::SendStablePetCallback(PreparedQueryResult result, ObjectGuid
if (!GetPlayer())
return;
TC_LOG_DEBUG("network", "WORLD: Recv CMSG_REQUEST_STABLED_PETS Send.");
WorldPacket data(SMSG_PET_STABLE_LIST, 200); // guess size
data << guid;
@@ -527,7 +567,6 @@ void WorldSession::SendPetStableResult(uint8 res)
void WorldSession::HandleStablePet(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Recv CMSG_STABLE_PET");
ObjectGuid npcGUID;
recvData >> npcGUID;
@@ -601,7 +640,6 @@ void WorldSession::HandleStablePetCallback(PreparedQueryResult result)
void WorldSession::HandleUnstablePet(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Recv CMSG_UNSTABLE_PET.");
ObjectGuid npcGUID;
uint32 petnumber;
@@ -682,7 +720,6 @@ void WorldSession::HandleUnstablePetCallback(PreparedQueryResult result, uint32
void WorldSession::HandleBuyStableSlot(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Recv CMSG_BUY_STABLE_SLOT.");
ObjectGuid npcGUID;
recvData >> npcGUID;
@@ -720,7 +757,6 @@ void WorldSession::HandleStableRevivePet(WorldPacket &/* recvData */)
void WorldSession::HandleStableSwapPet(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Recv CMSG_STABLE_SWAP_PET.");
ObjectGuid npcGUID;
uint32 petId;

View File

@@ -416,8 +416,6 @@ void WorldSession::HandlePetActionHelper(Unit* pet, ObjectGuid guid1, uint32 spe
void WorldSession::HandleQueryPetName(WorldPackets::Query::QueryPetName& packet)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUERY_PET_NAME");
SendQueryPetNameResponse(packet.UnitGUID);
}
@@ -471,8 +469,6 @@ bool WorldSession::CheckStableMaster(ObjectGuid guid)
void WorldSession::HandlePetSetAction(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_PET_SET_ACTION");
ObjectGuid petguid;
uint8 count;
@@ -588,8 +584,6 @@ void WorldSession::HandlePetSetAction(WorldPacket& recvData)
void WorldSession::HandlePetRename(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_PET_RENAME");
ObjectGuid petguid;
uint8 isdeclined;
@@ -695,7 +689,6 @@ void WorldSession::HandlePetAbandon(WorldPacket& recvData)
void WorldSession::HandlePetSpellAutocastOpcode(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_PET_SPELL_AUTOCAST");
ObjectGuid guid;
uint32 spellid;
uint8 state; //1 for on, 0 for off

View File

@@ -35,8 +35,6 @@
void WorldSession::HandlePetitionBuy(WorldPackets::Petition::PetitionBuy& packet)
{
TC_LOG_DEBUG("network", "Received CMSG_PETITION_BUY");
TC_LOG_DEBUG("network", "Petitioner %s tried sell petition: title %s", packet.Unit.ToString().c_str(), packet.Title.c_str());
// prevent cheating
@@ -140,8 +138,6 @@ void WorldSession::HandlePetitionBuy(WorldPackets::Petition::PetitionBuy& packet
void WorldSession::HandlePetitionShowSignatures(WorldPackets::Petition::PetitionShowSignatures& packet)
{
TC_LOG_DEBUG("network", "Received opcode CMSG_PETITION_SHOW_SIGNATURES");
uint8 signs = 0;
// if has guild => error, return;
@@ -238,9 +234,6 @@ void WorldSession::SendPetitionQueryOpcode(ObjectGuid petitionGUID)
void WorldSession::HandlePetitionRenameGuild(WorldPackets::Petition::PetitionRenameGuild& packet)
{
TC_LOG_DEBUG("network", "Received CMSG_PETITION_RENAME_GUILD");
TC_LOG_DEBUG("network", "Received opcode CMSG_PETITION_RENAME_GUILD");
Item* item = _player->GetItemByGuid(packet.PetitionGuid);
if (!item)
return;
@@ -274,8 +267,6 @@ void WorldSession::HandlePetitionRenameGuild(WorldPackets::Petition::PetitionRen
void WorldSession::HandleSignPetition(WorldPackets::Petition::SignPetition& packet)
{
TC_LOG_DEBUG("network", "Received CMSG_SIGN_PETITION");
PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_SEL_PETITION_SIGNATURES);
stmt->setUInt64(0, packet.PetitionGUID.GetCounter());
@@ -368,8 +359,6 @@ void WorldSession::HandleSignPetition(WorldPackets::Petition::SignPetition& pack
void WorldSession::HandleDeclinePetition(WorldPackets::Petition::DeclinePetition& packet)
{
TC_LOG_DEBUG("network", "Received CMSG_DECLINE_PETITION");
TC_LOG_DEBUG("network", "Petition %s declined by %s", packet.PetitionGUID.ToString().c_str(), _player->GetGUID().ToString().c_str());
PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_SEL_PETITION_OWNER_BY_GUID);
@@ -396,8 +385,6 @@ void WorldSession::HandleDeclinePetition(WorldPackets::Petition::DeclinePetition
void WorldSession::HandleOfferPetition(WorldPackets::Petition::OfferPetition& packet)
{
TC_LOG_DEBUG("network", "Received opcode CMSG_OFFER_PETITION");
Player* player = ObjectAccessor::FindConnectedPlayer(packet.TargetPlayer);
if (!player)
return;
@@ -458,8 +445,6 @@ void WorldSession::HandleOfferPetition(WorldPackets::Petition::OfferPetition& pa
void WorldSession::HandleTurnInPetition(WorldPackets::Petition::TurnInPetition& packet)
{
TC_LOG_DEBUG("network", "Received CMSG_TURN_IN_PETITION");
// Check if player really has the required petition charter
Item* item = _player->GetItemByGuid(packet.Item);
if (!item)
@@ -582,8 +567,6 @@ void WorldSession::HandleTurnInPetition(WorldPackets::Petition::TurnInPetition&
void WorldSession::HandlePetitionShowList(WorldPackets::Petition::PetitionShowList& packet)
{
TC_LOG_DEBUG("network", "Received CMSG_PETITION_SHOW_LIST");
SendPetitionShowList(packet.PetitionUnit);
}

View File

@@ -152,8 +152,6 @@ void WorldSession::HandleGameObjectQueryOpcode(WorldPackets::Query::QueryGameObj
void WorldSession::HandleQueryCorpseLocation(WorldPackets::Query::QueryCorpseLocationFromClient& /*packet*/)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUERY_CORPSE_LOCATION_FROM_CLIENT");
Corpse* corpse = GetPlayer()->GetCorpse();
if (!corpse)
@@ -230,8 +228,6 @@ void WorldSession::HandleNpcTextQueryOpcode(WorldPackets::Query::QueryNPCText& p
/// Only _static_ data is sent in this packet !!!
void WorldSession::HandleQueryPageText(WorldPackets::Query::QueryPageText& packet)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUERY_PAGE_TEXT");
uint32 pageID = packet.PageTextID;
while (pageID)
@@ -269,8 +265,6 @@ void WorldSession::HandleQueryPageText(WorldPackets::Query::QueryPageText& packe
void WorldSession::HandleQueryCorpseTransport(WorldPackets::Query::QueryCorpseTransport& packet)
{
TC_LOG_DEBUG("network", "WORLD: Recv CMSG_QUERY_CORPSE_TRANSPORT");
Corpse* corpse = _player->GetCorpse();
WorldPackets::Query::CorpseTransportQuery response;

View File

@@ -397,8 +397,6 @@ void WorldSession::HandleQuestgiverRequestRewardOpcode(WorldPackets::Quest::Ques
void WorldSession::HandleQuestgiverCancel(WorldPacket& /*recvData*/)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUESTGIVER_CANCEL");
_player->PlayerTalkClass->SendCloseGossip();
}
@@ -557,7 +555,6 @@ void WorldSession::HandleQuestgiverCompleteQuest(WorldPackets::Quest::QuestGiver
void WorldSession::HandleQuestgiverQuestAutoLaunch(WorldPacket& /*recvPacket*/)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUESTGIVER_QUEST_AUTOLAUNCH");
}
void WorldSession::HandlePushQuestToParty(WorldPacket& recvPacket)
@@ -639,8 +636,6 @@ void WorldSession::HandleQuestPushResult(WorldPacket& recvPacket)
uint8 msg;
recvPacket >> guid >> questId >> msg;
TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUEST_PUSH_RESULT");
if (!_player->GetDivider().IsEmpty() && _player->GetDivider() == guid)
{
Player* player = ObjectAccessor::FindPlayer(_player->GetDivider());
@@ -654,8 +649,6 @@ void WorldSession::HandleQuestPushResult(WorldPacket& recvPacket)
void WorldSession::HandleQuestgiverStatusMultipleQuery(WorldPackets::Quest::QuestGiverStatusMultipleQuery& /*packet*/)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUESTGIVER_STATUS_MULTIPLE_QUERY");
WorldPackets::Quest::QuestGiverStatusMultiple response;
for (auto itr = _player->m_clientGUIDs.begin(); itr != _player->m_clientGUIDs.end(); ++itr)

View File

@@ -470,8 +470,6 @@ void WorldSession::HandleTotemDestroyed(WorldPacket& recvPacket)
void WorldSession::HandleSelfResOpcode(WorldPacket& /*recvData*/)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_SELF_RES"); // empty opcode
if (_player->HasAuraType(SPELL_AURA_PREVENT_RESURRECTION))
return; // silent return, client should display error by itself and not send this opcode
@@ -597,8 +595,6 @@ void WorldSession::HandleMirrorImageDataRequest(WorldPacket& recvData)
void WorldSession::HandleUpdateProjectilePosition(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_MISSILE_TRAJECTORY_COLLISION");
ObjectGuid casterGuid;
uint32 spellId;
uint8 castCount;

View File

@@ -30,8 +30,6 @@
void WorldSession::HandleTaxiNodeStatusQueryOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_TAXINODE_STATUS_QUERY");
ObjectGuid guid;
recvData >> guid;
@@ -65,8 +63,6 @@ void WorldSession::SendTaxiStatus(ObjectGuid guid)
void WorldSession::HandleTaxiQueryAvailableNodes(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_TAXIQUERYAVAILABLENODES");
ObjectGuid guid;
recvData >> guid;
@@ -165,8 +161,6 @@ void WorldSession::SendDiscoverNewTaxiNode(uint32 nodeid)
void WorldSession::HandleActivateTaxiExpressOpcode (WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_ACTIVATETAXIEXPRESS");
ObjectGuid guid;
uint32 node_count;
@@ -205,8 +199,6 @@ void WorldSession::HandleActivateTaxiExpressOpcode (WorldPacket& recvData)
void WorldSession::HandleMoveSplineDoneOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_MOVE_SPLINE_DONE");
recvData.read_skip<uint32>(); // unk
MovementInfo movementInfo; // used only for proper packet read
@@ -280,8 +272,6 @@ void WorldSession::HandleMoveSplineDoneOpcode(WorldPacket& recvData)
void WorldSession::HandleActivateTaxiOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_ACTIVATETAXI");
ObjectGuid guid;
std::vector<uint32> nodes;
nodes.resize(2);

View File

@@ -24,7 +24,6 @@
void WorldSession::HandleVoiceSessionEnableOpcode(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_VOICE_SESSION_ENABLE");
// uint8 isVoiceEnabled, uint8 isMicrophoneEnabled
recvData.read_skip<uint8>();
recvData.read_skip<uint8>();
@@ -32,7 +31,6 @@ void WorldSession::HandleVoiceSessionEnableOpcode(WorldPacket& recvData)
void WorldSession::HandleSetActiveVoiceChannel(WorldPacket& recvData)
{
TC_LOG_DEBUG("network", "WORLD: CMSG_SET_ACTIVE_VOICE_CHANNEL");
recvData.read_skip<uint32>();
recvData.read_skip<char*>();
}

View File

@@ -911,14 +911,11 @@ bool WorldSession::IsAddonRegistered(const std::string& prefix) const
void WorldSession::HandleUnregisterAddonPrefixesOpcode(WorldPacket& /*recvPacket*/) // empty packet
{
_registeredAddonPrefixes.clear();
}
void WorldSession::HandleAddonRegisteredPrefixesOpcode(WorldPacket& recvPacket)
{
TC_LOG_DEBUG("network", "WORLD: Received CMSG_ADDON_REGISTERED_PREFIXES");
// This is always sent after CMSG_UNREGISTER_ALL_ADDON_PREFIXES
uint32 count = recvPacket.ReadBits(25);