1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-12-24 17:10:36 +00:00

fixed Hall of Mirrors with high sightrange

This commit is contained in:
Zeno Rogue 2017-09-30 11:41:29 +02:00
parent 3e494f40f5
commit e2c66abf5b

View File

@ -1378,6 +1378,11 @@ namespace mirror {
cellwalker reflect(const cellwalker& cw) { cellwalker reflect(const cellwalker& cw) {
if(!cw.c) return cw; if(!cw.c) return cw;
if((cw.c->landparam & 255) == 0) {
bool cando = false;
forCellEx(c2, cw.c) if(c2->landparam & 255) cando = true;
if(cando) buildEquidistant(cw.c);
}
int cid = (cw.c->landparam >> 8) & CACHEMASK; int cid = (cw.c->landparam >> 8) & CACHEMASK;
if(cache[cid].first != cw.c) { if(cache[cid].first != cw.c) {
cid = nextcache++; cid = nextcache++;