mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-11-27 14:37:16 +00:00
flag 'experimental' for new geometries
This commit is contained in:
parent
50e4990a76
commit
437c4e4cdd
@ -1259,7 +1259,7 @@ EX int wallchance(cell *c, bool deepOcean) {
|
||||
|
||||
EX bool horo_ok() {
|
||||
// do the horocycles work in the current geometry?
|
||||
return hyperbolic && !binarytiling && !archimedean && !penrose;
|
||||
return hyperbolic && !binarytiling && !archimedean && !penrose && !experimental;
|
||||
}
|
||||
|
||||
EX bool gp_wall_test() {
|
||||
@ -1309,7 +1309,7 @@ EX bool good_for_wall(cell *c) {
|
||||
}
|
||||
|
||||
EX void buildBigStuff(cell *c, cell *from) {
|
||||
if(sphere || quotient || nonisotropic || (penrose && !binarytiling)) return;
|
||||
if(sphere || quotient || nonisotropic || (penrose && !binarytiling) || experimental) return;
|
||||
if(chaosmode > 1) return;
|
||||
bool deepOcean = deep_ocean_at(c, from);
|
||||
|
||||
|
4
cell.cpp
4
cell.cpp
@ -448,6 +448,7 @@ EX int compdist(int dx[]) {
|
||||
}
|
||||
|
||||
EX int celldist(cell *c) {
|
||||
if(experimental) return 0;
|
||||
if(fulltorus && WDIM == 2)
|
||||
return torusmap()->dists[decodeId(c->master)];
|
||||
if(nil) return DISTANCE_UNKNOWN;
|
||||
@ -477,6 +478,7 @@ static const int ALTDIST_ERROR = 90000;
|
||||
#endif
|
||||
|
||||
EX int celldistAlt(cell *c) {
|
||||
if(experimental) return 0;
|
||||
if(masterless) {
|
||||
if(fulltorus) return celldist(c);
|
||||
if(euwrap) return cylinder_alt(c);
|
||||
@ -1014,7 +1016,7 @@ EX int celldistance(cell *c1, cell *c2) {
|
||||
if(geometry == gCrystal) return crystal::precise_distance(c1, c2);
|
||||
#endif
|
||||
|
||||
if(masterless || archimedean || quotient || sol || (penrose && euclid)) {
|
||||
if(masterless || archimedean || quotient || sol || (penrose && euclid) || experimental) {
|
||||
|
||||
if(saved_distances.count(make_pair(c1,c2)))
|
||||
return saved_distances[make_pair(c1,c2)];
|
||||
|
@ -249,6 +249,8 @@ static const flagtype qELLIPTIC = 128;
|
||||
static const flagtype qBINARY = 256;
|
||||
static const flagtype qPENROSE = 512;
|
||||
|
||||
static const flagtype qEXPERIMENTAL = 32768;
|
||||
|
||||
// note: dnext assumes that x&7 equals 7
|
||||
static const int SEE_ALL = 50;
|
||||
static const int FORBIDDEN = -1;
|
||||
|
3
hyper.h
3
hyper.h
@ -113,6 +113,9 @@ void addMessage(string s, char spamtype = 0);
|
||||
#define archimedean (geometry == gArchimedean)
|
||||
#define penrose (ginf[geometry].flags & qPENROSE)
|
||||
|
||||
/** convenience flag for geometries with major aspects missing */
|
||||
#define experimental (ginf[geometry].flags & qEXPERIMENTAL)
|
||||
|
||||
// these geometries do not feature alternate structures for horocycles
|
||||
#define eubinary (euclid || binarytiling || geometry == gCrystal || nil)
|
||||
|
||||
|
@ -371,7 +371,8 @@ EX pair<int, bool> fieldval(cell *c) {
|
||||
}
|
||||
|
||||
EX int fieldval_uniq(cell *c) {
|
||||
if(sphere) {
|
||||
if(experimental) return 0;
|
||||
else if(sphere) {
|
||||
if(archimedean) return c->master->fiftyval;
|
||||
#if CAP_IRR
|
||||
else if(IRREGULAR) return irr::cellindex[c];
|
||||
|
Loading…
Reference in New Issue
Block a user