From b3137ae26483a5eabe6cdc75ea9fadf93358e6bc Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Fri, 17 Apr 2026 23:55:30 +0200 Subject: [PATCH] fixed the distances in bitruncated {4,5} --- heptagon.cpp | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/heptagon.cpp b/heptagon.cpp index 6bcdf40f..de497af2 100644 --- a/heptagon.cpp +++ b/heptagon.cpp @@ -131,24 +131,17 @@ heptagon *buildHeptagon(heptagon *parent, int d, hstate s, int pard = 0, int fix else if(S3 == 4 && BITRUNCATED) { h->distance = parent->distance + 2; if(h->c.spin(0) == 2 || (h->c.spin(0) == 3 && S7 <= 5)) - h->distance = min(h->distance, createStep(h->move(0), 0)->distance + 3); + h->distance = min(h->distance, h->move(0)->cmove(0)->distance + 3); if(h->c.spin(0) == 2 && h->move(0)) { int d = h->c.spin(0); int d1 = (d+S7-1)%S7; - bool missing0 = !h->move(0)->move(d1); - if(missing0) { - if(s == 1 && h->move(0)->s != hsOrigin) - h->distance = h->move(0)->distance + 1; - } - else { - heptagon* h1 = createStep(h->move(0), d1); - if(h1->distance <= h->move(0)->distance) - h->distance = h->move(0)->distance+1; - } + heptagon* h1 = h->move(0)->cmove(d1); + if(h1->distance <= h->move(0)->distance) + h->distance = h->move(0)->distance+1; } if((h->s == hsB && h->move(0)->s == hsB) || h->move(0)->s == hsA) { int d = h->c.spin(0); - heptagon* h1 = createStep(h->move(0), (d+1)%S7); + heptagon* h1 = h->move(0)->cmove((d+1)%S7); if(h1->distance <= h->move(0)->distance) h->distance = h->move(0)->distance+1; }