Skip to content

Fix Dynmap area markers always rendering at y=64#2972

Merged
tastybento merged 2 commits into
developfrom
copilot/fix-dynmap-marker-y-value
May 9, 2026
Merged

Fix Dynmap area markers always rendering at y=64#2972
tastybento merged 2 commits into
developfrom
copilot/fix-dynmap-marker-y-value

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 9, 2026

Dynmap defaults ytop/ybottom to 64 when setRangeY is never called, causing all island area markers to appear at sea level regardless of world height — visually wrong in isometric view.

Changes

  • DynmapHook.setMarker() — calls area.setRangeY(world.getMaxHeight(), world.getMinHeight()) after creating the internal island area marker, spanning the full world height range (e.g. -64 → 320 for the overworld)
  • DynmapHook.addPolygonMarker() — same fix applied to the public MapHook API path; covers addAreaMarker() since it delegates here
AreaMarker area = markerSet.createAreaMarker(...);
if (area != null) {
    area.setRangeY(w.getMaxHeight(), w.getMinHeight()); // was missing — defaulted to y=64
    area.setLineStyle(2, 0.8, 0x3388FF);
    area.setFillStyle(0.15, 0x3388FF);
}
  • DynmapHookTest — adds world min/max height stubs (-64/320) and three new tests verifying setRangeY is called correctly for internal island markers, polygon markers, and area markers

Copilot AI linked an issue May 9, 2026 that may be closed by this pull request
Copilot AI changed the title [WIP] Fix Dynmap marker area's y value behavior Fix Dynmap area markers always rendering at y=64 May 9, 2026
Copilot AI requested a review from tastybento May 9, 2026 19:38
@tastybento tastybento marked this pull request as ready for review May 9, 2026 20:58
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented May 9, 2026

@tastybento tastybento merged commit 8dc906b into develop May 9, 2026
3 checks passed
@tastybento tastybento deleted the copilot/fix-dynmap-marker-y-value branch May 9, 2026 21:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Dynmap marker area's seem to ignore the y value

2 participants