Cleanup
This commit is contained in:
@@ -17,7 +17,7 @@ import LensHelp
|
||||
putTerminalImediateAccess :: Color -> Machine -> Terminal -> Placement
|
||||
putTerminalImediateAccess = putTerminalFull f
|
||||
where
|
||||
f tmpl _ _ = Just $ sps0 $ PutWorldUpdate $ const $ over gwWorld $ accessTerminal (tmpl ^?! plMID . _Just)
|
||||
f tmpl _ _ = Just $ sps0 $ PutWorldUpdate $ const $ const $ over gwWorld $ accessTerminal (tmpl ^?! plMID . _Just)
|
||||
|
||||
putTerminalFull ::
|
||||
(Placement -> Placement -> Placement -> Maybe Placement) ->
|
||||
@@ -39,7 +39,7 @@ putTerminalFull f col mc tm =
|
||||
defaultSensorWall
|
||||
Nothing
|
||||
)
|
||||
$ \mcpl -> Just $ pt0 (PutWorldUpdate $ const $ over gwWorld (setids tmpl btpl mcpl)) (\_ -> f tmpl btpl mcpl)
|
||||
$ \mcpl -> Just $ pt0 (PutWorldUpdate $ const $ const $ over gwWorld (setids tmpl btpl mcpl)) (\_ -> f tmpl btpl mcpl)
|
||||
where
|
||||
setids tmpl btpl mcpl w =
|
||||
w
|
||||
|
||||
@@ -122,7 +122,7 @@ placeSpotID rm ps pt w = case pt of
|
||||
PutWall qs wl -> (0, over gwWorld (placeWallPoly (map doShift qs) wl) w)
|
||||
PutNothing -> (0, w)
|
||||
PutID i -> (i, w)
|
||||
PutWorldUpdate f -> (0, w & f ps)
|
||||
PutWorldUpdate f -> (0, w & f rm ps)
|
||||
PutChasm ps' -> (0, w & gwWorld . cWorld . chasms .:~ map doShift ps')
|
||||
where
|
||||
p@(V2 px py) = _psPos ps
|
||||
|
||||
Reference in New Issue
Block a user