Cleanup, hlints
This commit is contained in:
@@ -19,7 +19,7 @@ useItem :: Int -> PressType -> World -> Maybe World
|
||||
useItem invid pt w = fmap (worldEventFlags . at InventoryChange ?~ ()) $ do
|
||||
cr <- w ^? cWorld . lWorld . creatures . ix 0
|
||||
itmloc <- invIndents (_crInv cr) ^? ix invid . _2
|
||||
useItemLoc cr (itmloc) pt w
|
||||
useItemLoc cr itmloc pt w
|
||||
|
||||
useItemLoc :: Creature -> LocationDT OItem -> PressType -> World -> Maybe World
|
||||
useItemLoc cr loc pt w
|
||||
@@ -30,13 +30,13 @@ useItemLoc cr loc pt w
|
||||
| LaserWeaponSF <- sf
|
||||
, fromMaybe False $ loc ^? locDT . dtValue . _1 . itLocation . ilIsAttached
|
||||
, Aiming{} <- cr ^. crStance . posture =
|
||||
return $ gadgetEffect pt (loc) cr w
|
||||
return $ gadgetEffect pt loc cr w
|
||||
| GadgetPlatformSF <- sf =
|
||||
return $ gadgetEffect pt (loc) cr w
|
||||
return $ gadgetEffect pt loc cr w
|
||||
| UnderBarrelPlatformSF <- sf
|
||||
, fromMaybe False $ loc ^? locDT . dtValue . _1 . itLocation . ilIsAttached
|
||||
, Aiming{} <- cr ^. crStance . posture =
|
||||
return $ gadgetEffect pt (loc) cr w
|
||||
return $ gadgetEffect pt loc cr w
|
||||
| RemoteDetonatorSF <- sf
|
||||
, pt == InitialPress =
|
||||
return $ activateDetonator ldt w
|
||||
|
||||
Reference in New Issue
Block a user