1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-10-31 19:36:16 +00:00

in be_solid check that c1 is not null (not sure how it could happen)

This commit is contained in:
Zeno Rogue 2021-08-24 12:55:56 +02:00
parent 510c28227b
commit 42d87d39ac

View File

@ -568,8 +568,10 @@ void be_solid(tcell *c) {
throw rulegen_failure("set solid but no dist");
}
c->is_solid = true;
if(c->dist > 0 && !(flags & w_near_solid))
be_solid(c->move(c->any_nearer));
if(c->dist > 0 && !(flags & w_near_solid)) {
tcell *c1 = c->move(c->any_nearer);
if(c1) be_solid(c1);
}
}
EX void look_for_shortcuts(tcell *c, shortcut& sh) {