- Create HousingRoomEntity (objectType=18, Housing/2 GUID, fragments [21,31,220])
for each room in SpawnRoomMeshObjects with MeshObjects array and door data
- Send room entities in deferred callback UPDATE_OBJECT (not initial batch —
type-18 entities in initial UPDATE_OBJECT crash without full housing context)
- Fix room GUID format: arg2=roomEntryId matching retail (sniff-verified)
- Load rooms BEFORE decor in Housing::LoadFromDB so decor RoomGuid matches
- Auto-assign RoomGuid for interior decor placement when client sends empty
- Add HousingRoomEntity::AddDoor using MutableFieldReferenceWithChangesMask
- Fix SQL hotfix idempotency for trait_tree columns
Implement SPELL_AURA_MOD_SPELL_CURRENCY_REAGENTS_COUNT_PCT
TrinityCore's PathGenerator uses a shared dtNavMeshQuery which is NOT
thread-safe — calling it from bot worker threads causes ACCESS_VIOLATION
crashes in dtNavMeshQuery::getPathToNode.
ThreadSafePathfinder creates per-thread dtNavMeshQuery instances using
thread_local storage. Each thread gets its own query with independent
node pool and open list, sharing the read-only dtNavMesh. This is safe
because dtNavMesh is read-only after tile loading.
API: ThreadSafePathfinder::IsReachable(mapId, start, dest)
- Returns true if navmesh path exists from start to dest
- Creates query on first use per thread per map
- 64-poly path check (enough for reachability, not full pathfinding)
Re-enabled navmesh reachability check in SearchForQuestGivers using
the thread-safe pathfinder instead of PathGenerator.
Added GetBotPosition(), GetBotDistanceTo(), GetBotDistance2dTo() to
SpatialGridQueryHelpers for thread-safe position reads.
Converted position reads in:
- PositionManager: 15 GetPosition/GetExactDist calls
- CombatStateAnalyzer: 4 GetPositionX/Y/Z calls
Combat distance calculations now use the spatial grid position which
is updated every 100ms from the main thread, eliminating stale position
data that caused bots to walk through walls and air.
Signed-off-by: luis <[email protected]>