From 9fe2ef381cf1c899c80e6f0c2b0ad5d19519f5ab Mon Sep 17 00:00:00 2001 From: Kelsi Date: Fri, 13 Mar 2026 08:00:46 -0700 Subject: [PATCH] feat: use zone name in battlefield entry invite message Replace raw bfZoneId integer with getAreaName() lookup in SMSG_BATTLEFIELD_MGR_ENTRY_INVITE so players see "Wintergrasp" instead of "zone 4197" in the invitation prompt. --- src/game/game_handler.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/game/game_handler.cpp b/src/game/game_handler.cpp index 825110a4..6779bff0 100644 --- a/src/game/game_handler.cpp +++ b/src/game/game_handler.cpp @@ -7300,8 +7300,15 @@ void GameHandler::handlePacket(network::Packet& packet) { bfMgrInvitePending_ = true; bfMgrZoneId_ = bfZoneId; char buf[128]; - std::snprintf(buf, sizeof(buf), - "You are invited to the outdoor battlefield in zone %u. Click to enter.", bfZoneId); + std::string bfZoneName = getAreaName(bfZoneId); + if (!bfZoneName.empty()) + std::snprintf(buf, sizeof(buf), + "You are invited to the outdoor battlefield in %s. Click to enter.", + bfZoneName.c_str()); + else + std::snprintf(buf, sizeof(buf), + "You are invited to the outdoor battlefield in zone %u. Click to enter.", + bfZoneId); addSystemChatMessage(buf); LOG_INFO("SMSG_BATTLEFIELD_MGR_ENTRY_INVITE: zoneId=", bfZoneId); break;