mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-01-11 18:00:34 +00:00
fixed mousedist with nonisotropic mouseaim_sensitivity
This commit is contained in:
parent
45d2a2c4bb
commit
d7f7f567f7
@ -4056,9 +4056,9 @@ EX int get_darkval(cell *c, int d) {
|
||||
EX ld mousedist(shiftmatrix T) {
|
||||
if(GDIM == 2) return hdist(mouseh, tC0(T));
|
||||
shiftpoint T1 = orthogonal_move_fol(T, cgi.FLOOR) * tile_center();
|
||||
if(mouseaim_sensitivity) return sqhypot_d(2, T1.h) + (point_behind(T1) ? 1e10 : 0);
|
||||
hyperpoint h1;
|
||||
applymodel(T1, h1);
|
||||
if(mouseaim_sensitivity) return sqhypot_d(2, h1) + (point_behind(T1) ? 1e10 : 0);
|
||||
h1 = h1 - point2((mousex - current_display->xcenter) / current_display->radius, (mousey - current_display->ycenter) / current_display->radius);
|
||||
return sqhypot_d(2, h1) + (point_behind(T1) ? 1e10 : 0);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user