1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-06-18 19:29:59 +00:00

line patterns:: 'triangle grid: rings' renamed to 'lines of equal distance' and also work better now

This commit is contained in:
Zeno Rogue 2022-09-14 18:01:26 +02:00
parent f537abf71c
commit c637dd4322

View File

@ -2852,12 +2852,20 @@ EX namespace linepatterns {
} }
) )
); );
EX linepattern patTriRings = linepattern("triangle grid: rings", 0xFFFFFF00, always_available, EX linepattern patTriRings = linepattern("lines of equal distance", 0xFFFFFF00, trees_known,
ALLCELLS( ALLCELLS(
forCellIdEx(c2, i, c) { if(valence() == 3) {
if(S3 == 4) c2 = (cellwalker(c, i) + wstep + 1).cpeek(); forCellIdEx(c2, i, c) {
if(c2 > c) if(curr_dist(c) == curr_dist(c2)) if(c2 > c) if(curr_dist(c) == curr_dist(c2))
gridlinef(V, C0, V * currentmap->adj(c, i), C0, col, 2 + vid.linequality); gridlinef(V, C0, V * currentmap->adj(c, i), C0, col, 2 + vid.linequality);
}
}
else {
dynamicval<int> dmar(mine_adjacency_rule, 1);
int d = curr_dist(c);
for(auto p: adj_minefield_cells_full(c))
if(p.c < c && d == curr_dist(p.c))
gridlinef(V, C0, V, tC0(p.T), col, 2 + vid.linequality);
} }
) )
); );