Send CMSG_QUESTGIVER_STATUS_QUERY when quest NPCs spawn

The server only sends quest status packets in response to client queries. Send the query for each NPC with the questgiver flag (0x02) when it enters view so the ! and ? markers actually appear.
This commit is contained in:
Kelsi 2026-02-06 20:13:28 -08:00
parent e6a80c68c1
commit 2889e412b3

View file

@ -2668,6 +2668,12 @@ void GameHandler::handleUpdateObject(network::Packet& packet) {
creatureSpawnCallback_(block.guid, unit->getDisplayId(),
unit->getX(), unit->getY(), unit->getZ(), unit->getOrientation());
}
// Query quest giver status for NPCs with questgiver flag (0x02)
if ((unit->getNpcFlags() & 0x02) && socket) {
network::Packet qsPkt(static_cast<uint16_t>(Opcode::CMSG_QUESTGIVER_STATUS_QUERY));
qsPkt.writeUInt64(block.guid);
socket->send(qsPkt);
}
}
}
// Track online item objects