1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-10-14 13:57:38 +00:00

unified the land lists

This commit is contained in:
Zeno Rogue
2017-11-03 19:31:42 +01:00
parent 8498ae7af8
commit f38cf14110
10 changed files with 347 additions and 227 deletions

View File

@@ -124,18 +124,16 @@ bool handleKeyTour(int sym, int uni) {
}
if(sym == '2') {
bool ok = cwt.c->land == laCanvas;
for(int i=0; i<LAND_EUC; i++) if(land_euc[i] == cwt.c->land) ok = true;
if(!ok) {
dynamicval<eGeometry> g(geometry, gEuclid);
if(cwt.c->land != laCanvas && !isLandValid(cwt.c->land)) {
addMessage(XLAT("This land has no Euclidean version."));
return true;
}
}
if(sym == '1') {
bool ok = cwt.c->land == laCanvas;
for(int i=0; i<LAND_SPH; i++) if(land_sph[i] == cwt.c->land) ok = true;
if(!ok) {
dynamicval<eGeometry> g(geometry, gSphere);
if(cwt.c->land != laCanvas && !isLandValid(cwt.c->land)) {
addMessage(XLAT("This land has no spherical version."));
return true;
}