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

fixed to_other_side in sphere

This commit is contained in:
Zeno Rogue 2020-06-06 19:11:47 +02:00
parent f8f166eb08
commit f6e617535e

View File

@ -403,7 +403,7 @@ EX transmatrix to_other_side(hyperpoint h1, hyperpoint h2) {
else else
d1 = atan_auto(-v[LDIM] / h1[LDIM]); d1 = atan_auto(-v[LDIM] / h1[LDIM]);
hyperpoint hm = h1 * cos_auto(d1) + v * sin_auto(d1); hyperpoint hm = h1 * cos_auto(d1) + (sphere ? -1 : 1) * v * sin_auto(d1);
return rspintox(hm) * xpush(-hdist0(hm) * 2) * spintox(hm); return rspintox(hm) * xpush(-hdist0(hm) * 2) * spintox(hm);
} }