Allow for equipment items to set a minimum view distance

This commit is contained in:
2022-06-05 01:50:18 +01:00
parent 5e144b1cd5
commit 65fcea0f50
13 changed files with 76 additions and 61 deletions
+3 -2
View File
@@ -32,7 +32,7 @@ rewindGun = defaultGun
, _itEffect = ItRewindEffect rewindEffect []
, _itUse = defaultlUse
& lUse .~ useRewindGun
& eqSite .~ GoesOnChest
& eqEq . eqSite .~ GoesOnChest
}
rewindEffect :: Item -> Creature -> World -> World
rewindEffect itm cr w
@@ -106,7 +106,7 @@ blinkGun = defaultGun
, _itUse = defaultlUse
& lUse .~ hammerCheckL (shootL $ const blinkAction)
& useHammer .~ upHammer
& eqSite .~ GoesOnWrist
& eqEq . eqSite .~ GoesOnWrist
-- , _itFloorPict = const . noPic . colorSH chartreuse $ upperPrismPoly 2 $ square 2
}
@@ -115,6 +115,7 @@ unsafeBlinkGun = blinkGun
& itName .~ "BLINKER-UNSAFE"
& itType .~ BLINKERUNSAFE
& itUse . lUse .~ hammerCheckL (shootL $ const unsafeBlinkAction)
& itUse . eqEq . eqViewDist ?~ 400
effectGun :: String -> (Creature -> World -> World) -> Item
effectGun name eff = defaultGun