Browse Source

Calculate position of item highlighting

pull/882/head
Anders Jenbo 6 years ago
parent
commit
e9de54fb5a
  1. 4
      Source/automap.cpp

4
Source/automap.cpp

@ -544,8 +544,8 @@ void SearchAutomapItem()
px = i - 2 * AutoMapXOfs - ViewX;
py = j - 2 * AutoMapYOfs - ViewY;
x = (ScrollInfo._sxoff * AutoMapScale / 100 >> 1) + (px - py) * AmLine16 + 384;
y = (ScrollInfo._syoff * AutoMapScale / 100 >> 1) + (px + py) * AmLine8 + 336;
x = (ScrollInfo._sxoff * AutoMapScale / 100 >> 1) + (px - py) * AmLine16 + SCREEN_WIDTH / 2 + SCREEN_X;
y = (ScrollInfo._syoff * AutoMapScale / 100 >> 1) + (px + py) * AmLine8 + (SCREEN_HEIGHT - PANEL_HEIGHT) / 2 + SCREEN_Y;
if (invflag || sbookflag)
x -= 160;

Loading…
Cancel
Save