1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2025-12-18 03:58:04 +00:00

added some exports to hyper.h and rogueviz.h

This commit is contained in:
Zeno Rogue
2019-03-15 12:45:57 +01:00
parent 1e27888f7d
commit 0e10dec9e2
4 changed files with 44 additions and 2 deletions

View File

@@ -295,6 +295,14 @@ inline hyperpoint xspinpush0(ld alpha, ld x) {
return h;
}
bool eqmatrix(transmatrix A, transmatrix B, ld eps) {
for(int i=0; i<MDIM; i++)
for(int j=0; j<MDIM; j++)
if(std::abs(A[i][j] - B[i][j]) > 1e-2)
return false;
return true;
}
// push alpha units vertically
transmatrix ypush(ld alpha) { return cpush(1, alpha); }