diff options
author | Shauren <shauren.trinity@gmail.com> | 2015-09-19 17:39:01 +0200 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2015-09-19 17:39:01 +0200 |
commit | f34bae89d3869ddc5f74a85d9a6fa44f67ca4635 (patch) | |
tree | d531e8f336dbf89dd1c7e50794e6e97c0703f1bf /src | |
parent | f1b047b826e92278e566d376b80989b600c0d7c0 (diff) |
Core/PacketIO: Disabled CMSG_TAXI_REQUEST_EARLY_LANDING
Diffstat (limited to 'src')
-rw-r--r-- | src/server/game/Entities/Player/PlayerTaxi.cpp | 2 | ||||
-rw-r--r-- | src/server/game/Handlers/MovementHandler.cpp | 4 | ||||
-rw-r--r-- | src/server/game/Handlers/TaxiHandler.cpp | 26 | ||||
-rw-r--r-- | src/server/game/Server/Protocol/Opcodes.cpp | 2 | ||||
-rw-r--r-- | src/server/game/Server/WorldSession.h | 14 |
5 files changed, 25 insertions, 23 deletions
diff --git a/src/server/game/Entities/Player/PlayerTaxi.cpp b/src/server/game/Entities/Player/PlayerTaxi.cpp index b937d7d6e38..466cb7b947b 100644 --- a/src/server/game/Entities/Player/PlayerTaxi.cpp +++ b/src/server/game/Entities/Player/PlayerTaxi.cpp @@ -170,9 +170,11 @@ void PlayerTaxi::RequestEarlyLanding() return; for (std::deque<uint32>::iterator it = m_TaxiDestinations.begin(); it != m_TaxiDestinations.end(); it++) + { if (IsTaximaskNodeKnown(*it)) { m_TaxiDestinations.erase(++it, m_TaxiDestinations.end()); return; } + } } diff --git a/src/server/game/Handlers/MovementHandler.cpp b/src/server/game/Handlers/MovementHandler.cpp index 4cad8c98e42..279345845a1 100644 --- a/src/server/game/Handlers/MovementHandler.cpp +++ b/src/server/game/Handlers/MovementHandler.cpp @@ -527,9 +527,9 @@ void WorldSession::HandleMoveTimeSkippedOpcode(WorldPackets::Movement::MoveTimeS { } -void WorldSession::HandleMoveSplineDoneOpcode(WorldPackets::Movement::MoveSplineDone& packet) +void WorldSession::HandleMoveSplineDoneOpcode(WorldPackets::Movement::MoveSplineDone& moveSplineDone) { - MovementInfo movementInfo = packet.movementInfo; + MovementInfo movementInfo = moveSplineDone.movementInfo; _player->ValidateMovementInfo(&movementInfo); // in taxi flight packet received in 2 case: diff --git a/src/server/game/Handlers/TaxiHandler.cpp b/src/server/game/Handlers/TaxiHandler.cpp index 9bd2328f8ab..d3612e5a031 100644 --- a/src/server/game/Handlers/TaxiHandler.cpp +++ b/src/server/game/Handlers/TaxiHandler.cpp @@ -27,16 +27,16 @@ #include "TaxiPackets.h" #include "TaxiPathGraph.h" -void WorldSession::HandleEnableTaxiNodeOpcode(WorldPackets::Taxi::EnableTaxiNode& packet) +void WorldSession::HandleEnableTaxiNodeOpcode(WorldPackets::Taxi::EnableTaxiNode& enableTaxiNode) { - Creature* unit = GetPlayer()->GetMap()->GetCreature(packet.Unit); + Creature* unit = GetPlayer()->GetMap()->GetCreature(enableTaxiNode.Unit); SendLearnNewTaxiNode(unit); } -void WorldSession::HandleTaxiNodeStatusQueryOpcode(WorldPackets::Taxi::TaxiNodeStatusQuery& packet) +void WorldSession::HandleTaxiNodeStatusQueryOpcode(WorldPackets::Taxi::TaxiNodeStatusQuery& taxiNodeStatusQuery) { - SendTaxiStatus(packet.UnitGUID); + SendTaxiStatus(taxiNodeStatusQuery.UnitGUID); } void WorldSession::SendTaxiStatus(ObjectGuid guid) @@ -66,13 +66,13 @@ void WorldSession::SendTaxiStatus(ObjectGuid guid) TC_LOG_DEBUG("network", "WORLD: Sent SMSG_TAXI_NODE_STATUS"); } -void WorldSession::HandleTaxiQueryAvailableNodesOpcode(WorldPackets::Taxi::TaxiQueryAvailableNodes& packet) +void WorldSession::HandleTaxiQueryAvailableNodesOpcode(WorldPackets::Taxi::TaxiQueryAvailableNodes& taxiQueryAvailableNodes) { // cheating checks - Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(packet.Unit, UNIT_NPC_FLAG_FLIGHTMASTER); + Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(taxiQueryAvailableNodes.Unit, UNIT_NPC_FLAG_FLIGHTMASTER); if (!unit) { - TC_LOG_DEBUG("network", "WORLD: HandleTaxiQueryAvailableNodes - %s not found or you can't interact with him.", packet.Unit.ToString().c_str()); + TC_LOG_DEBUG("network", "WORLD: HandleTaxiQueryAvailableNodes - %s not found or you can't interact with him.", taxiQueryAvailableNodes.Unit.ToString().c_str()); return; } // remove fake death @@ -156,12 +156,12 @@ void WorldSession::SendDiscoverNewTaxiNode(uint32 nodeid) SendPacket(WorldPackets::Taxi::NewTaxiPath().Write()); } -void WorldSession::HandleActivateTaxiOpcode(WorldPackets::Taxi::ActivateTaxi& packet) +void WorldSession::HandleActivateTaxiOpcode(WorldPackets::Taxi::ActivateTaxi& activateTaxi) { - Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(packet.Vendor, UNIT_NPC_FLAG_FLIGHTMASTER); + Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(activateTaxi.Vendor, UNIT_NPC_FLAG_FLIGHTMASTER); if (!unit) { - TC_LOG_DEBUG("network", "WORLD: HandleActivateTaxiOpcode - %s not found or you can't interact with it.", packet.Vendor.ToString().c_str()); + TC_LOG_DEBUG("network", "WORLD: HandleActivateTaxiOpcode - %s not found or you can't interact with it.", activateTaxi.Vendor.ToString().c_str()); return; } @@ -170,13 +170,13 @@ void WorldSession::HandleActivateTaxiOpcode(WorldPackets::Taxi::ActivateTaxi& pa return; TaxiNodesEntry const* from = sTaxiNodesStore.LookupEntry(curloc); - TaxiNodesEntry const* to = sTaxiNodesStore.LookupEntry(packet.Node); + TaxiNodesEntry const* to = sTaxiNodesStore.LookupEntry(activateTaxi.Node); if (!to) return; if (!GetPlayer()->isTaxiCheater()) { - if (!GetPlayer()->m_taxi.IsTaximaskNodeKnown(curloc) || !GetPlayer()->m_taxi.IsTaximaskNodeKnown(packet.Node)) + if (!GetPlayer()->m_taxi.IsTaximaskNodeKnown(curloc) || !GetPlayer()->m_taxi.IsTaximaskNodeKnown(activateTaxi.Node)) { SendActivateTaxiReply(ERR_TAXINOTVISITED); return; @@ -196,7 +196,7 @@ void WorldSession::SendActivateTaxiReply(ActivateTaxiReply reply) TC_LOG_DEBUG("network", "WORLD: Sent SMSG_ACTIVATETAXIREPLY"); } -void WorldSession::HandleTaxiRequestEarlyLanding(WorldPackets::Taxi::TaxiRequestEarlyLanding& /* packet */) +void WorldSession::HandleTaxiRequestEarlyLanding(WorldPackets::Taxi::TaxiRequestEarlyLanding& /*taxiRequestEarlyLanding*/) { GetPlayer()->m_taxi.RequestEarlyLanding(); } diff --git a/src/server/game/Server/Protocol/Opcodes.cpp b/src/server/game/Server/Protocol/Opcodes.cpp index c7e40c45289..67cbd08369e 100644 --- a/src/server/game/Server/Protocol/Opcodes.cpp +++ b/src/server/game/Server/Protocol/Opcodes.cpp @@ -780,7 +780,7 @@ void OpcodeTable::Initialize() DEFINE_HANDLER(CMSG_TALK_TO_GOSSIP, STATUS_LOGGEDIN, PROCESS_THREADUNSAFE, WorldPackets::NPC::Hello, &WorldSession::HandleGossipHelloOpcode); DEFINE_HANDLER(CMSG_TAXI_NODE_STATUS_QUERY, STATUS_LOGGEDIN, PROCESS_THREADSAFE, WorldPackets::Taxi::TaxiNodeStatusQuery, &WorldSession::HandleTaxiNodeStatusQueryOpcode); DEFINE_HANDLER(CMSG_TAXI_QUERY_AVAILABLE_NODES, STATUS_LOGGEDIN, PROCESS_THREADSAFE, WorldPackets::Taxi::TaxiQueryAvailableNodes, &WorldSession::HandleTaxiQueryAvailableNodesOpcode); - DEFINE_HANDLER(CMSG_TAXI_REQUEST_EARLY_LANDING, STATUS_LOGGEDIN, PROCESS_INPLACE, WorldPackets::Taxi::TaxiRequestEarlyLanding, &WorldSession::HandleTaxiRequestEarlyLanding); + DEFINE_HANDLER(CMSG_TAXI_REQUEST_EARLY_LANDING, STATUS_UNHANDLED, PROCESS_THREADSAFE, WorldPackets::Taxi::TaxiRequestEarlyLanding, &WorldSession::HandleTaxiRequestEarlyLanding); DEFINE_HANDLER(CMSG_TELEPORT_TO_UNIT, STATUS_UNHANDLED, PROCESS_INPLACE, WorldPackets::Null, &WorldSession::Handle_NULL); DEFINE_HANDLER(CMSG_TIME_ADJUSTMENT_RESPONSE, STATUS_UNHANDLED, PROCESS_INPLACE, WorldPackets::Null, &WorldSession::Handle_NULL); DEFINE_HANDLER(CMSG_TIME_SYNC_RESPONSE, STATUS_LOGGEDIN, PROCESS_INPLACE, WorldPackets::Misc::TimeSyncResponse, &WorldSession::HandleTimeSyncResponse); diff --git a/src/server/game/Server/WorldSession.h b/src/server/game/Server/WorldSession.h index 95b66e1aceb..e30f5d030b8 100644 --- a/src/server/game/Server/WorldSession.h +++ b/src/server/game/Server/WorldSession.h @@ -556,7 +556,7 @@ namespace WorldPackets class SetSpecialization; class LearnTalents; } - + namespace Taxi { class ShowTaxiNodes; @@ -1244,13 +1244,13 @@ class WorldSession void HandleGuildFinderRemoveRecruit(WorldPacket& recvPacket); void HandleGuildFinderSetGuildPost(WorldPacket& recvPacket); - void HandleEnableTaxiNodeOpcode(WorldPackets::Taxi::EnableTaxiNode& packet); - void HandleTaxiNodeStatusQueryOpcode(WorldPackets::Taxi::TaxiNodeStatusQuery& packet); - void HandleTaxiQueryAvailableNodesOpcode(WorldPackets::Taxi::TaxiQueryAvailableNodes& packet); - void HandleActivateTaxiOpcode(WorldPackets::Taxi::ActivateTaxi& packet); - void HandleMoveSplineDoneOpcode(WorldPackets::Movement::MoveSplineDone& packet); + void HandleEnableTaxiNodeOpcode(WorldPackets::Taxi::EnableTaxiNode& enableTaxiNode); + void HandleTaxiNodeStatusQueryOpcode(WorldPackets::Taxi::TaxiNodeStatusQuery& taxiNodeStatusQuery); + void HandleTaxiQueryAvailableNodesOpcode(WorldPackets::Taxi::TaxiQueryAvailableNodes& taxiQueryAvailableNodes); + void HandleActivateTaxiOpcode(WorldPackets::Taxi::ActivateTaxi& activateTaxi); + void HandleMoveSplineDoneOpcode(WorldPackets::Movement::MoveSplineDone& moveSplineDone); void SendActivateTaxiReply(ActivateTaxiReply reply); - void HandleTaxiRequestEarlyLanding(WorldPackets::Taxi::TaxiRequestEarlyLanding& packet); + void HandleTaxiRequestEarlyLanding(WorldPackets::Taxi::TaxiRequestEarlyLanding& taxiRequestEarlyLanding); void HandleTabardVendorActivateOpcode(WorldPackets::NPC::Hello& packet); void HandleBankerActivateOpcode(WorldPackets::NPC::Hello& packet); |