10 Commits

Author SHA1 Message Date
Kelsi
2de06c267a add map trackers and fix spell and mount state 2026-07-21 02:23:51 -07:00
Kelsi
c548c18f65 Revert "diag: log why a zone map shows full fog (explore-bit state)"
This reverts commit 719f934e99.
2026-07-20 22:12:05 -07:00
Kelsi
719f934e99 diag: log why a zone map shows full fog (explore-bit state)
When the world map has a server exploration mask but the viewed zone reveals none
of its overlays (full fog), log once per zone: total mask bits set, the zone's own
AreaBit and whether it's set, and each overlay's first AreaID -> ExploreFlag -> bit
state. Distinguishes 'server never sent the bits' from a client mapping bug for the
Darkshore-stays-dark report. One-shot per viewed zone, so not spammy.
2026-07-20 21:48:27 -07:00
Kelsi
56d7c6e71b feat: rare tracker — mark nearby spawned rares on the world map
Adds an opt-in world-map layer that marks every rare (rank 4) and rare-elite
(rank 2) creature the client currently has loaded, so a rare that is out shows
as a gold/silver diamond with its name in the current zone. Entities only exist
near the player, so a marker means that rare is genuinely spawned right now.

New RareTrackerLayer follows the existing overlay-layer pattern; the HUD feeds it
the filtered live units each frame. Gated behind a new 'Show Rare Tracker'
Interface setting (persisted), off by default.
2026-07-20 20:56:39 -07:00
Kelsi
955c04e385 fix: stabilize transports and world integration 2026-07-20 03:15:37 -07:00
Kelsi
5d9a8c2c8c feat: interactive flight map for taxi destination selection
Selecting a flight destination now opens the world map in a dedicated
flight-map mode: green marker at the current node, gold markers at reachable
destinations, hover tooltips with flight cost, dotted route lines through the
actual hops, click to fly. The taxi BFS records predecessors for route chains,
only routes through known nodes (matching server behavior), and taxi node
markers convert TaxiNodes.dbc wire-order coords to canonical before map
projection — fixing the transposed placement of the world map's taxi diamonds.
The legacy list window remains as a fallback when the world map is unavailable.
2026-07-19 02:34:47 -07:00
Kelsi
4d9a36dae5 Fix quest marker types on maps 2026-07-12 18:56:34 -07:00
Kelsi
70e46bfe1a fix(map): use Rotating-MinimapCorpseArrow.blp for corpse marker
Replace the procedural X with the actual WoW corpse icon texture loaded
from game data. Falls back to the X if the BLP fails to load.
2026-07-11 11:16:41 -07:00
Pavel Okhlopkov
97c95941f4 feat(world-map): remove kVOffset hack, ZMP hover, textured player arrow
- Remove the -0.15 vertical offset (kVOffset) from coordinate_projection,
  coordinate_display, and zone_highlight_layer; continent UV math is now
  identical to zone UV math
- Switch world_map_facade aspect ratio to MAP_W/MAP_H (1002×668) and crop
  the FBO image with MAP_U_MAX/MAP_V_MAX instead of stretching the full
  1024×768 FBO
- Account for ImGui title bar height (GetFrameHeight) in window sizing and
  zone highlight screen-space rect coordinates
- Add ZMP 128×128 grid pixel-accurate hover detection in zone_highlight_layer;
  falls back to AABB when ZMP data is unavailable
- Upgrade PlayerMarkerLayer with full Vulkan lifecycle (initialize,
  clearTexture, destructor); loads MinimapArrow.blp and renders a rotated
  32×32 textured quad via AddImageQuad; red triangle retained as fallback
- Expose arrowRotation_ / arrowDS_ accessors on Minimap; clean up arrow DS
  and texture in Minimap::shutdown()
- Wire PlayerMarkerLayer::initialize() into WorldMapFacade::initialize()
- Update coordinate-projection test: continent and zone UV are now equal

Signed-off-by: Pavel Okhlopkov <pavel.okhlopkov@flant.com>
2026-04-12 20:02:50 +03:00
Pavel Okhlopkov
fff06fc932 refactor: decompose world map into modular component architecture
Break the monolithic 1360-line world_map.cpp into 16 focused modules
under src/rendering/world_map/:

Architecture:
- world_map_facade: public API composing all components (PIMPL)
- world_map_types: Vulkan-free domain types (Zone, ViewLevel, etc.)
- data_repository: DBC zone loading, ZMP pixel map, POI/overlay storage
- coordinate_projection: UV projection, zone/continent lookups
- composite_renderer: Vulkan tile pipeline + off-screen compositing
- exploration_state: server mask + local exploration tracking
- view_state_machine: COSMIC→WORLD→CONTINENT→ZONE navigation
- input_handler: keyboard/mouse input → InputAction mapping
- overlay_renderer: layer-based ImGui overlay system (OCP)
- map_resolver: cross-map navigation (Outland, Northrend, etc.)
- zone_metadata: level ranges and faction data

Overlay layers (each an IOverlayLayer):
- player_marker, party_dot, taxi_node, poi_marker, quest_poi,
  corpse_marker, zone_highlight, coordinate_display, subzone_tooltip

Fixes:
- Player marker no longer bleeds across continents (only shown when
  player is in a zone belonging to the displayed continent)
- Zone hover uses DBC-projected AABB rectangles (restored from
  original working behavior)
- Exploration overlay rendering for zone view subzones

Tests:
- 6 new test files covering coordinate projection, exploration state,
  map resolver, view state machine, zone metadata, and integration

Signed-off-by: Pavel Okhlopkov <pavel.okhlopkov@flant.com>
2026-04-12 09:52:51 +03:00