mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-11-17 06:07:12 +00:00
pointing-to-directions now checks for the cell which is the most towards the given direction
This commit is contained in:
@@ -7246,9 +7246,10 @@ EX void precise_mouseover() {
|
||||
if(WDIM == 3) {
|
||||
mouseover2 = mouseover = viewcenter();
|
||||
ld best = HUGE_VAL;
|
||||
hyperpoint h = direct_exp(lp_iapply(ztangent(1)), 100);
|
||||
hyperpoint h = direct_exp(lp_iapply(ztangent(0.01)), 100);
|
||||
forCellEx(c1, mouseover2) {
|
||||
ld dist = hdist(tC0(ggmatrix(c1)), h);
|
||||
hyperpoint h1 = tC0(ggmatrix(c1));
|
||||
ld dist = geo_dist(h1, h, iTable) - geo_dist(C0, h1, iTable);
|
||||
if(dist < best) mouseover = c1, best = dist;
|
||||
}
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user