1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-06-07 17:04:06 +00:00

rU:: compute_scrm in render_the_map for correct mousepxy

This commit is contained in:
Zeno Rogue 2025-05-02 21:52:27 +02:00
parent b2b72be306
commit a3c42c89be

View File

@ -187,6 +187,7 @@ void render_the_map() {
drawmessages();
nomsg = false;
if(1) {
compute_scrm();
ld& scale = scrm.T[0][0];
mousepx = (mousex - current_display->xcenter) * 2 / scale / current_display->radius + screen_x/2;
mousepy = (mousey - current_display->ycenter) * 2 / scale / current_display->radius + screen_y/2;