Skip to content

Commit

Permalink
Fix incorrect GetMapCoordinates() within housing ward subdivisions (#…
Browse files Browse the repository at this point in the history
…1917)

Co-authored-by: Sabine Lim <[email protected]>
  • Loading branch information
thesabinelim and Sabine Lim committed Jul 16, 2024
1 parent 378ef0a commit c57cc5c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions Dalamud/Utility/MapUtil.cs
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,12 @@ public static unsafe Vector3 GetMapCoordinates(this IGameObject go, bool correct

return WorldToMap(
go.Position,
agentMap->CurrentOffsetX,
agentMap->CurrentOffsetY,
/*
* https://github.com/aers/FFXIVClientStructs/issues/1029
* Our calculations are based on Excel's Map, but AgentMap's offset values are sign-flipped in comparison
*/
-agentMap->CurrentOffsetX,
-agentMap->CurrentOffsetY,
territoryTransient?.OffsetZ ?? 0,
(uint)agentMap->CurrentMapSizeFactor,
correctZOffset);
Expand Down

0 comments on commit c57cc5c

Please sign in to comment.