Cleanup
This commit is contained in:
@@ -324,8 +324,6 @@ updateMouseContextGame cfig u = case u ^. uvWorld . input . mouseContext of
|
||||
OverInvDragSelect{} -> u
|
||||
_ ->
|
||||
u & uvWorld . input . mouseContext
|
||||
-- .~ fromMaybe aimcontext (overinv <|> overcomb <|> overterm)
|
||||
-- .~ fromMaybe aimcontext (overinv <|> overcomb <|> overterm <|> isrotatedrag)
|
||||
.~ fromMaybe aimcontext (isrotatedrag <|> overinv <|> overcomb <|> overterm)
|
||||
where
|
||||
w = u ^. uvWorld
|
||||
|
||||
@@ -137,14 +137,11 @@ viewDistanceFromItems _ = 1
|
||||
|
||||
rotateCamera :: Configuration -> World -> World
|
||||
rotateCamera cfig w
|
||||
| Just ltime <- pkeys ^? ix SDL.ButtonLeft
|
||||
, Just rtime <- pkeys ^? ix SDL.ButtonRight
|
||||
, rtime > 0
|
||||
, ltime > rtime
|
||||
| MouseGameRotate <- w ^. input . mouseContext
|
||||
, Just rotation <-
|
||||
angleBetween (w ^. input . mousePos)
|
||||
<$> (w ^. input . heldPos . at SDL.ButtonRight) =
|
||||
w & wCam . camRot -~ rotation
|
||||
w & wCam . camRot -~ rotation
|
||||
| _gameplay_rotate_to_wall cfig
|
||||
, isNothing $ pkeys ^? ix SDL.ButtonRight =
|
||||
rotateToOverlappingWall w
|
||||
|
||||
Reference in New Issue
Block a user