Cleanup, improve auto wall rotate

This commit is contained in:
2026-03-24 11:28:11 +00:00
parent be2f7160ba
commit 32f1740577
25 changed files with 226 additions and 252 deletions
+1 -9
View File
@@ -221,20 +221,12 @@ rotateToOverlappingWall w =
(overlapCircWallsClosest p r (filter _wlRotateTo $ wlsNearCirc p r w))
w
where
r = (crRad (cr ^. crType) + 10)
r = crRad (cr ^. crType) + 10
cr = you w
p = you w ^. crPos . _xy
doWallRotate :: Wall -> World -> World
doWallRotate = rotateTo8 . argV . uncurry (-) . _wlLine
--doWallRotate wl w = rotateTo8
-- | b - b' > 0.01 = w & wCam . camRot +~ 0.01
-- | b - b' < negate 0.01 = w & wCam . camRot -~ 0.01
-- | otherwise = w
-- where
-- a = argV (uncurry (-.-) $ _wlLine wl) - w ^. wCam . camRot
-- b = a * (4 / pi) -- for 8 way cardinal orientation wrt wall
-- b' = fromIntegral (round b :: Int)
clipZoom ::
-- | Furthest viewable distance