mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2024-10-31 19:36:16 +00:00
fixed a crash in hat reversing
This commit is contained in:
parent
bf6220913c
commit
3416f09381
2
cell.cpp
2
cell.cpp
@ -1502,7 +1502,7 @@ EX vector<cell*> adj_minefield_cells(cell *c) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
EX vector<int> reverse_directions(cell *c, int dir) {
|
EX vector<int> reverse_directions(cell *c, int dir) {
|
||||||
if(PURE && !(kite::in() && WDIM == 2)) return reverse_directions(c->master, dir);
|
if(PURE && !(aperiodic && WDIM == 2)) return reverse_directions(c->master, dir);
|
||||||
int d = c->degree();
|
int d = c->degree();
|
||||||
if(d & 1)
|
if(d & 1)
|
||||||
return { gmod(dir + c->type/2, c->type), gmod(dir + (c->type+1)/2, c->type) };
|
return { gmod(dir + c->type/2, c->type), gmod(dir + (c->type+1)/2, c->type) };
|
||||||
|
Loading…
Reference in New Issue
Block a user