1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-09-27 13:48:15 +00:00

fixed the shape pattern for converted tilings

This commit is contained in:
Zeno Rogue 2024-05-28 13:04:24 +02:00
parent 3b3e9e2de6
commit fcc3cae938
3 changed files with 10 additions and 5 deletions

View File

@ -2007,6 +2007,7 @@ EX void convert() {
sh.vertices.clear();
sh.connections.clear();
sh.cycle_length = id.modval;
sh.orig_id = arcm::get_graphical_id(s);
sh.repeat_value = t / id.modval;
sh.flags = hr::pseudohept(s) ? arcm::sfPH : 0;
#if CAP_ARCM

View File

@ -1570,6 +1570,14 @@ EX bool is_vertex(heptagon *h) {
return id_of(h) >= 2 * current.N;
}
EX int get_graphical_id(cell *c) {
int id = arcm::id_of(c->master);
int tid = arcm::current.tilegroup[id];
int tid2 = arcm::current.tilegroup[id^1];
if(tid2 >= 0) tid = min(tid, tid2);
return tid;
}
bool archimedean_tiling::get_step_values(int& steps, int& single_step) {
int nom = -2;

View File

@ -1607,11 +1607,7 @@ EX namespace ccolor {
EX data shape = data("shape", always_available, CCO {
#if CAP_ARCM
if(arcm::in()) {
int id = arcm::id_of(c->master);
int tid = arcm::current.tilegroup[id];
int tid2 = arcm::current.tilegroup[id^1];
if(tid2 >= 0) tid = min(tid, tid2);
return cco.ctab[tid];
return cco.ctab[arcm::get_graphical_id(c)];
}
#endif
if(arb::in()) {