1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-12-28 16:09:03 +00:00

3d:: celldistances

This commit is contained in:
?
2019-02-27 15:50:26 +01:00
committed by Zeno Rogue
parent 714ff8462a
commit 9319c3b0fa
2 changed files with 9 additions and 1 deletions

View File

@@ -402,7 +402,7 @@ int celldist(cell *c) {
return torusconfig::cyldist(decodeId(c->master), 0);
if(masterless)
return eudist(decodeId(c->master));
if(sphere || binarytiling || geometry == gCrystal) return celldistance(c, currentmap->gamestart());
if(sphere || binarytiling || DIM == 3 || geometry == gCrystal) return celldistance(c, currentmap->gamestart());
#if CAP_IRR
if(IRREGULAR) return irr::celldist(c, false);
#endif
@@ -439,6 +439,9 @@ int celldistAlt(cell *c) {
if(sphere || quotient) {
return celldist(c) - 3;
}
#if MAXDIM == 4
if(euclid && DIM == 3) return euclid3::dist_alt(c);
#endif
if(!c->master->alt) return 0;
#if CAP_IRR
if(IRREGULAR) return irr::celldist(c, true);