89 lines
2.4 KiB
Haskell
89 lines
2.4 KiB
Haskell
module Dodge.Item.Weapon.Utility
|
|
( stopWatch
|
|
, rewindWatch
|
|
, scrollWatch
|
|
, blinkGun
|
|
, unsafeBlinkGun
|
|
, shrinkGun
|
|
) where
|
|
|
|
import Control.Lens
|
|
import Dodge.Data.Item
|
|
import Dodge.Default
|
|
|
|
stopWatch :: Item
|
|
stopWatch =
|
|
defaultLeftItem
|
|
& itUse
|
|
.~ ( defaultLeftUse
|
|
& leftUse .~ LTimePause
|
|
& equipEffect . eeSite .~ GoesOnWrist
|
|
)
|
|
& itEffect . ieInv .~ ChargeIfEquipped
|
|
& itEffect . ieOnDrop .~ SetCharge 0
|
|
& itType . iyBase .~ LEFT STOPWATCH
|
|
& itUse . leftConsumption
|
|
.~ ChargeableAmmo
|
|
{ _wpMaxCharge = 100
|
|
, _wpCharge = 0
|
|
}
|
|
|
|
scrollWatch :: Item
|
|
scrollWatch =
|
|
stopWatch
|
|
& itUse . leftUse .~ LTimeScroll
|
|
& itType . iyBase .~ LEFT SCROLLWATCH
|
|
|
|
rewindWatch :: Item
|
|
rewindWatch =
|
|
stopWatch
|
|
& itUse . leftUse .~ LRewind --useRewindGun
|
|
& itType . iyBase .~ LEFT REWINDWATCH
|
|
|
|
-- needs to shift this item to the current inventory slot
|
|
shrinkGun :: Item
|
|
shrinkGun =
|
|
defaultLeftItem
|
|
& itUse .~ (defaultLeftUse & leftUse .~ LShrink)
|
|
& itParams .~ ShrinkGunParams FullSize
|
|
& itType . iyBase .~ LEFT SHRINKER
|
|
|
|
blinkGun :: Item
|
|
blinkGun =
|
|
defaultLeftItem
|
|
{ _itUse =
|
|
defaultLeftUse
|
|
& leftUse .~ LBlink --hammerCheckL (shootL $ const blinkAction)
|
|
& equipEffect . eeSite .~ GoesOnWrist
|
|
-- , _itFloorPict = const . noPic . colorSH chartreuse $ upperPrismPoly 2 $ square 2
|
|
}
|
|
& itType . iyBase .~ LEFT BLINKER
|
|
|
|
unsafeBlinkGun :: Item
|
|
unsafeBlinkGun =
|
|
blinkGun
|
|
& itType . iyBase .~ LEFT BLINKERUNSAFE
|
|
& itUse . leftUse .~ LUnsafeBlink --hammerCheckL (shootL $ const unsafeBlinkAction)
|
|
& itUse . equipEffect . eeViewDist ?~ 400
|
|
|
|
|
|
-- grapGun = defaultGun
|
|
-- { _itName = "grapGun"
|
|
-- , _itIdentity = GrapGun
|
|
-- , _wpMaxAmmo = 1
|
|
-- , _wpLoadedAmmo = 1
|
|
-- , _wpReloadTime = 40
|
|
-- , _wpReloadState = 0
|
|
-- , _itUseRate = 10
|
|
-- , _itUseTime = 0
|
|
-- , _itUse = grapFire
|
|
-- , _wpSpread = 0.002
|
|
-- , _wpRange = 20
|
|
-- , _wpIsAuto = False
|
|
-- , _itFloorPict = onLayer FlItLayer $ polygon [(-4,-4),(-4,4),(4,4),(4,0),(0,0),(0,-4)]
|
|
-- , _itAmount = 1
|
|
-- , _itMaxStack = 1
|
|
-- , _itAimingSpeed = 1
|
|
-- , _itAimingRange = 0.5
|
|
-- }
|