From 860ade77ef9bbbb96a2c8e3f6b2d85bedeb14cec Mon Sep 17 00:00:00 2001 From: luis Date: Tue, 7 Apr 2026 13:54:20 -0300 Subject: [PATCH] remove wrong handlers --- .../game/Handlers/NeighborhoodHandler.cpp | 66 ------------------- src/server/game/Server/WorldSession.h | 2 - 2 files changed, 68 deletions(-) diff --git a/src/server/game/Handlers/NeighborhoodHandler.cpp b/src/server/game/Handlers/NeighborhoodHandler.cpp index 3d0b6e215..514ddae0b 100644 --- a/src/server/game/Handlers/NeighborhoodHandler.cpp +++ b/src/server/game/Handlers/NeighborhoodHandler.cpp @@ -2385,69 +2385,3 @@ void WorldSession::HandleNeighborhoodCancelInvitationAlt(WorldPackets::Neighborh response.InviteeGuid = neighborhoodCancelInvitationAlt.InviteeGuid; SendPacket(response.Write()); } - -void WorldSession::HandleNeighborhoodInviteNotificationAck(WorldPackets::Neighborhood::NeighborhoodInviteNotificationAck const& neighborhoodInviteNotificationAck) -{ - Player* player = GetPlayer(); - if (!player) - return; - - TC_LOG_DEBUG("housing", "CMSG_NEIGHBORHOOD_INVITE_NOTIFICATION_ACK Player: {} NeighborhoodGuid: {}", - player->GetGUID().ToString(), neighborhoodInviteNotificationAck.NeighborhoodGuid.ToString()); - - // Acknowledgment only ? no response needed - // The client is confirming it received the invite notification -} - -void WorldSession::HandleNeighborhoodOfferOwnershipResponse(WorldPackets::Neighborhood::NeighborhoodOfferOwnershipResponsePacket const& neighborhoodOfferOwnershipResponse) -{ - Player* player = GetPlayer(); - if (!player) - return; - - TC_LOG_DEBUG("housing", "CMSG_NEIGHBORHOOD_OFFER_OWNERSHIP_RESPONSE Player: {} NeighborhoodGuid: {} Accept: {}", - player->GetGUID().ToString(), neighborhoodOfferOwnershipResponse.NeighborhoodGuid.ToString(), - neighborhoodOfferOwnershipResponse.Accept); - - Neighborhood* neighborhood = sNeighborhoodMgr.ResolveNeighborhood( - neighborhoodOfferOwnershipResponse.NeighborhoodGuid, player); - - WorldPackets::Neighborhood::NeighborhoodOfferOwnershipResponse response; - - if (!neighborhood) - { - response.Result = static_cast(HOUSING_RESULT_NEIGHBORHOOD_NOT_FOUND); - SendPacket(response.Write()); - return; - } - - if (neighborhoodOfferOwnershipResponse.Accept) - { - HousingResult result = neighborhood->AcceptOwnershipTransfer(player->GetGUID()); - response.Result = static_cast(result); - - if (result == HOUSING_RESULT_SUCCESS) - { - // Broadcast roster update ? role change for both old owner and new owner - WorldPackets::Neighborhood::NeighborhoodRosterResidentUpdate rosterUpdate; - rosterUpdate.Residents.push_back({ player->GetGUID(), 1 /*RoleChanged*/, true /*owner = privileged*/ }); - neighborhood->BroadcastPacket(rosterUpdate.Write()); - - // Refresh NeighborhoodMirrorData (OwnerGUID + Managers changed) - neighborhood->RefreshMirrorDataForOnlineMembers(); - - TC_LOG_INFO("housing", "CMSG_NEIGHBORHOOD_OFFER_OWNERSHIP_RESPONSE: Player {} accepted ownership of neighborhood {}", - player->GetGUID().ToString(), neighborhood->GetGuid().ToString()); - } - } - else - { - HousingResult result = neighborhood->RejectOwnershipTransfer(player->GetGUID()); - response.Result = static_cast(result); - - TC_LOG_INFO("housing", "CMSG_NEIGHBORHOOD_OFFER_OWNERSHIP_RESPONSE: Player {} rejected ownership of neighborhood {}", - player->GetGUID().ToString(), neighborhood->GetGuid().ToString()); - } - - SendPacket(response.Write()); -} diff --git a/src/server/game/Server/WorldSession.h b/src/server/game/Server/WorldSession.h index 4e5e85698..4fdaec92e 100644 --- a/src/server/game/Server/WorldSession.h +++ b/src/server/game/Server/WorldSession.h @@ -1911,8 +1911,6 @@ class TC_GAME_API WorldSession // Phase 7 Neighborhood handlers void HandleNeighborhoodCancelInvitationAlt(WorldPackets::Neighborhood::NeighborhoodCancelInvitationAlt const& neighborhoodCancelInvitationAlt); - void HandleNeighborhoodInviteNotificationAck(WorldPackets::Neighborhood::NeighborhoodInviteNotificationAck const& neighborhoodInviteNotificationAck); - void HandleNeighborhoodOfferOwnershipResponse(WorldPackets::Neighborhood::NeighborhoodOfferOwnershipResponsePacket const& neighborhoodOfferOwnershipResponse); void HandleNeighborhoodInitiativeServiceStatusCheck(WorldPackets::Neighborhood::NeighborhoodInitiativeServiceStatusCheck const& packet); void HandleGetAvailableInitiativeRequest(WorldPackets::Neighborhood::GetAvailableInitiativeRequest const& getAvailableInitiativeRequest);