Files
loop/src/Dodge/Default.hs
T
justin dae0e0591c Fix bugs in equipment allocation using hotkeys
The behaviour is still not perfect, should be able to cycle through all
options by pressing one key. There is unnecessary memory of past state
going on here
2025-01-01 14:48:17 +00:00

87 lines
2.1 KiB
Haskell

{- |
Module : Dodge.Default
Description : Instances of data structures
This module contains prototypical data structures.
-}
module Dodge.Default (
module Dodge.Default,
module Dodge.Default.Item,
module Dodge.Default.Wall,
module Dodge.Default.Creature,
module Dodge.Default.Terminal,
) where
import Control.Lens
import Dodge.Data.World
import Dodge.Default.Creature
import Dodge.Default.Item
import Dodge.Default.Terminal
import Dodge.Default.Wall
import Dodge.SoundLogic
import Geometry
import Picture
defaultEquipment :: Item
defaultEquipment = defaultHeldItem & itUse .~ defaultEquipUse
-- & itUseFocus .~ UseFromLocation
defaultFlIt :: FloorItem
defaultFlIt = FlIt{_flItRot = 0, _flIt = defaultHeldItem, _flItPos = V2 0 0, _flItID = 0}
defaultMachine :: Machine
defaultMachine =
Machine
{ _mcID = 0
, _mcWallIDs = mempty
, _mcColor = white
, _mcPos = V2 0 0
, _mcDir = 0
, _mcHP = 1000
, _mcMaterial = Electronics
, _mcDamage = []
, _mcType = McStatic
, _mcName = ""
, _mcMounts = mempty
, _mcCloseSound = Nothing
, _mcWidth = 10
}
defaultButton :: Button
defaultButton =
Button
{ _btPict = DefaultDrawButton (dark red)
, _btPos = V2 0 0
, _btRot = 0
, _btEvent = ButtonPress BtInactive ButtonDoNothing click1S NoWorldEffect
, _btID = 0
, _btText = "Button"
, _btState = BtOff
, _btTermMID = Nothing
, _btName = ""
, _btColor = red
}
defaultPP :: PressPlate
defaultPP =
PressPlate
{ _ppPict = setDepth 1 . color (dim . dim $ bright blue) $ circleSolid 5
, _ppPos = V2 0 0
, _ppRot = 0
, _ppEvent = PressPlateId
, _ppID = -1
, _ppText = "Pressure plate"
}
--upHammer :: HammerType
--upHammer = HasHammer HammerUp
defaultProximitySensor :: Sensor
defaultProximitySensor =
ProximitySensor
{ _proxStatus = NotClose
, _proxDist = 40
, _proxRequirement = RequireImpossible
, _sensToggle = False
}