1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2026-04-25 02:01:23 +00:00
This commit is contained in:
Zeno Rogue
2022-07-11 17:32:27 +02:00
parent 3318c1e4b4
commit cdb2a001ca
4 changed files with 168 additions and 7 deletions

View File

@@ -1732,6 +1732,16 @@ EX namespace reg3 {
}
};
EX int get_aid(cell *c) {
auto m = dynamic_cast<hrmap_h3*> (currentmap);
if(!m) throw hr_exception("get_aid incorrect");
return m->cell_id[c];
}
EX int get_size_of_aid(int aid) {
auto m = dynamic_cast<hrmap_h3*> (currentmap);
if(!m) throw hr_exception("get_size_of_fv incorrect");
return m->quotient_map->acells[aid]->type;
};
struct hrmap_sphere3 : hrmap_closed3 {
@@ -2206,6 +2216,10 @@ EX int quotient_count() {
return isize(hypmap()->quotient_map->allh);
}
EX int quotient_count_sub() {
return isize(hypmap()->quotient_map->acells);
}
/** This is a generalization of hyperbolic_celldistance in expansion.cpp to three dimensions.
It still assumes that there are at most 4 cells around every edge, and that distances from
the origin are known, so it works only in {5,3,4}.