mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-11-06 08:43:02 +00:00
no more crashes in some Euclidean lands
This commit is contained in:
11
bigstuff.cpp
11
bigstuff.cpp
@@ -720,12 +720,14 @@ void setLandQuotient(cell *c) {
|
|||||||
else
|
else
|
||||||
c->land = specialland, c->landparam = d;
|
c->land = specialland, c->landparam = d;
|
||||||
}
|
}
|
||||||
|
if(specialland == laWestWall) c->land = laCrossroads4;
|
||||||
}
|
}
|
||||||
|
|
||||||
void setLandSphere(cell *c) {
|
void setLandSphere(cell *c) {
|
||||||
setland(c, specialland);
|
setland(c, specialland);
|
||||||
if(specialland == laWarpCoast)
|
if(specialland == laWarpCoast)
|
||||||
setland(c, getHemisphere(c, 0) > 0 ? laWarpCoast : laWarpSea);
|
setland(c, getHemisphere(c, 0) > 0 ? laWarpCoast : laWarpSea);
|
||||||
|
if(specialland == laWestWall) c->land = laCrossroads4;
|
||||||
if(specialland == laClearing)
|
if(specialland == laClearing)
|
||||||
c->land = laClearing;
|
c->land = laClearing;
|
||||||
if(specialland == laElementalWall) {
|
if(specialland == laElementalWall) {
|
||||||
@@ -857,6 +859,15 @@ void setLandEuclid(cell *c) {
|
|||||||
else if(y<0) setland(c, laRlyeh);
|
else if(y<0) setland(c, laRlyeh);
|
||||||
else c->landparam = y;
|
else c->landparam = y;
|
||||||
}
|
}
|
||||||
|
if(specialland == laWestWall) {
|
||||||
|
int x, y;
|
||||||
|
tie(x,y) = cell_to_pair(c);
|
||||||
|
x = -5 - x;
|
||||||
|
if(x == 0)
|
||||||
|
{setland(c, laBarrier); if(ishept(c)) setland(c, laMotion); }
|
||||||
|
else if(x<0) setland(c, laMotion);
|
||||||
|
else c->landparam = x;
|
||||||
|
}
|
||||||
if(specialland == laIvoryTower || specialland == laDungeon) {
|
if(specialland == laIvoryTower || specialland == laDungeon) {
|
||||||
int x, y;
|
int x, y;
|
||||||
tie(x,y) = cell_to_pair(c); y = -5 - y;
|
tie(x,y) = cell_to_pair(c); y = -5 - y;
|
||||||
|
|||||||
Reference in New Issue
Block a user