send SMSG_INIT_WORLD_STATES

This commit is contained in:
luis
2026-09-23 13:35:00 -03:00
parent de14780789
commit 721396ef88
@@ -189,6 +189,14 @@ void WorldStateMgr::LoadFromDB()
}
TC_LOG_INFO("server.loading", ">> Loaded {} saved world state values {} ms", savedValueCount, GetMSTimeDiffToNow(oldMSTime));
// SMSG_INIT_WORLD_STATES copies this cache. It used to stay empty until some later realm-state
// change, so a login before that change never received the loaded values. The Eversong captures
// include every Prey hunt slot (set or zero) in the initial packet while the player is in Silvermoon.
data.RealmWorldStatePacketCache.clear();
data.RealmWorldStatePacketCache.reserve(data.RealmWorldStateValues.size());
for (auto const& [worldStateId, value] : data.RealmWorldStateValues)
data.RealmWorldStatePacketCache.emplace_back(worldStateId, value);
}
void WorldStateMgr::Update()