1
0
mirror of https://github.com/zenorogue/hyperrogue.git synced 2026-03-11 23:59:44 +00:00

improvements to sphere flipping

This commit is contained in:
Zeno Rogue
2022-12-04 14:48:12 +01:00
parent 0770a11164
commit 42f96b768c
5 changed files with 12 additions and 9 deletions

View File

@@ -11,9 +11,11 @@ namespace hr {
hyperpoint ghxy, ghgxy;
shiftpoint ghpm = shiftless(C02);
#if HDR
inline bool sphereflipped() { return sphere && pconf.alpha > 1.1; }
#endif
EX ld flip_limit = 1.1;
EX bool flip_sphere() { return sphere && pconf.alpha > flip_limit; }
EX bool sphere_flipped;
void ghcheck(hyperpoint &ret, const shiftpoint &H) {
if(hypot_d(2, ret-ghxy) < hypot_d(2, ghgxy-ghxy)) {