mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-01-20 06:03:01 +00:00
sphere:: get_where did not memoize
This commit is contained in:
parent
131b9f656e
commit
c43df41a7d
@ -166,8 +166,12 @@ struct hrmap_spherical : hrmap_standard {
|
|||||||
int d = celldist(c);
|
int d = celldist(c);
|
||||||
if(d == 0) return where[c] = Id;
|
if(d == 0) return where[c] = Id;
|
||||||
else forCellIdCM(c1, i, c)
|
else forCellIdCM(c1, i, c)
|
||||||
if(celldist(c1) < d)
|
if(celldist(c1) < d) {
|
||||||
return get_where(c1) * iadj(c, i);
|
transmatrix T = get_where(c1);
|
||||||
|
T = T * iadj(c, i);
|
||||||
|
where[c] = T;
|
||||||
|
return T;
|
||||||
|
}
|
||||||
return Id;
|
return Id;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user