From ce390de0d2e2e0830f254c7e9c1758b70c8cae8b Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Fri, 28 Sep 2018 12:27:44 +0200 Subject: [PATCH] fixed curr_dist and horocycles in Canvas for Euclidedan --- bigstuff.cpp | 4 ++-- cell.cpp | 3 --- expansion.cpp | 2 +- hyper.h | 1 + 4 files changed, 4 insertions(+), 6 deletions(-) diff --git a/bigstuff.cpp b/bigstuff.cpp index 5cc92e3b..af61d4db 100644 --- a/bigstuff.cpp +++ b/bigstuff.cpp @@ -44,7 +44,7 @@ int celldistAltRelative(cell *c) { } int euclidAlt(short x, short y) { - if(specialland == laTemple || specialland == laClearing) { + if(among(specialland, laTemple, laClearing, laCanvas)) { if(euclid6) return max(int(x), x+y); else if(PURE) @@ -1169,7 +1169,7 @@ void moreBigStuff(cell *c) { if(d <= PRADIUS1) generateAlts(c->master); } - if(c->land == laCanvas && c->master->alt) + if(c->land == laCanvas && !eubinary && c->master->alt) generateAlts(c->master); if(c->land == laStorms) diff --git a/cell.cpp b/cell.cpp index 78b1b768..9c4c89cd 100644 --- a/cell.cpp +++ b/cell.cpp @@ -1063,9 +1063,6 @@ int celldist(cell *c) { #define ALTDIST_ERROR 90000 -// defined in 'game' -int euclidAlt(short x, short y); - int celldistAlt(cell *c) { if(masterless) { if(torus) return celldist(c); diff --git a/expansion.cpp b/expansion.cpp index f49da9d3..d2b4cd7d 100644 --- a/expansion.cpp +++ b/expansion.cpp @@ -416,7 +416,7 @@ int curr_dist(cell *c) { case dfWorld: if(!mod_allowed() && !among(c->land, laOcean, laIvoryTower, laEndorian, laDungeon, laTemple, laWhirlpool, laCanvas)) return 0; - if(c->master->alt) return celldistAlt(c); + if(eubinary || c->master->alt) return celldistAlt(c); return inmirror(c) ? (c->landparam & 255) : c->landparam; } return 0; diff --git a/hyper.h b/hyper.h index 38990bf3..20267cf4 100644 --- a/hyper.h +++ b/hyper.h @@ -4228,6 +4228,7 @@ namespace ts { } void generate_around(cell *c); +int euclidAlt(short x, short y); }