1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2024-07-05 19:43:17 +00:00

fixed a bug causing not compiling in C++20

This commit is contained in:
Zeno Rogue 2024-05-16 21:06:28 +02:00
parent 879549ca5d
commit a70a9dc663

View File

@ -213,7 +213,7 @@ template<class T> struct walker {
int spin;
/** \brief are we mirrored */
bool mirrored;
walker<T> (T *at = NULL, int s = 0, bool m = false) : at(at), spin(s), mirrored(m) { if(at) s = at->c.fix(s); }
walker(T *at = NULL, int s = 0, bool m = false) : at(at), spin(s), mirrored(m) { if(at) s = at->c.fix(s); }
/** \brief spin by i to the left (or right, when mirrored */
walker<T>& operator += (int i) {
spin = at->c.fix(spin+(mirrored?-i:i));