Simplify item placement during generation
This commit is contained in:
+3
-33
@@ -4,6 +4,7 @@
|
||||
module Dodge.Data
|
||||
( module Dodge.Data
|
||||
, module Dodge.Data.Menu
|
||||
, module Dodge.Data.DamageType
|
||||
, module Dodge.Data.SoundOrigin
|
||||
, module Dodge.Creature.Data
|
||||
, module Dodge.Creature.State.Data
|
||||
@@ -16,6 +17,7 @@ import Dodge.Creature.Data
|
||||
import Dodge.Creature.State.Data
|
||||
import Dodge.Data.Menu
|
||||
import Dodge.Data.SoundOrigin
|
||||
import Dodge.Data.DamageType
|
||||
import Dodge.Config.Data
|
||||
import Dodge.Config.KeyConfig
|
||||
import Preload.Data
|
||||
@@ -162,10 +164,9 @@ data Creature = Creature
|
||||
, _crInvSel :: Int
|
||||
, _crState :: CreatureState
|
||||
, _crCorpse :: Picture
|
||||
, _crIsAnimate :: Bool
|
||||
, _crApplyDamage :: [DamageType] -> Creature -> (World -> World,Creature)
|
||||
}
|
||||
|
||||
|
||||
data WorldState
|
||||
= DoorNumOpen Int
|
||||
| CrNumAlive Int
|
||||
@@ -410,7 +411,6 @@ data Particle'
|
||||
type HitEffect = Particle' -> [(Point2, (Either3 Creature Wall ForceField))] -> World
|
||||
-> (World,Maybe Particle')
|
||||
|
||||
|
||||
data Projectile
|
||||
= Projectile
|
||||
{ _pjPos :: Point2
|
||||
@@ -430,24 +430,6 @@ data Projectile
|
||||
, _pjPayload :: Point2-> World -> World
|
||||
}
|
||||
|
||||
data DamageType
|
||||
= Piercing {_dmAmount :: Int , _dmFrom :: Point2 , _dmAt :: Point2 , _dmTo :: Point2 }
|
||||
| Blunt {_dmAmount :: Int , _dmFrom :: Point2 , _dmAt :: Point2 , _dmTo :: Point2 }
|
||||
| SparkDam {_dmAmount :: Int , _dmFrom :: Point2 , _dmAt :: Point2 , _dmTo :: Point2 }
|
||||
| Flaming {_dmAmount :: Int , _dmFrom :: Point2 , _dmAt :: Point2 , _dmTo :: Point2 }
|
||||
| Lasering {_dmAmount :: Int , _dmFrom :: Point2 , _dmAt :: Point2 , _dmTo :: Point2 }
|
||||
| Concussive
|
||||
{ _dmAmount :: Int
|
||||
, _dmFrom :: Point2
|
||||
, _dmPush :: Float
|
||||
, _dmPushExp :: Float
|
||||
, _dmPushRadius :: Float
|
||||
}
|
||||
| TorqueDam {_dmAmount :: Int , _dmTorque :: Float }
|
||||
| PushDam {_dmAmount :: Int , _dmPushBack :: Point2 }
|
||||
| PoisonDam {_dmAmount :: Int}
|
||||
deriving (Eq,Ord,Show)
|
||||
|
||||
data Either3 a b c = E3x1 a | E3x2 b | E3x3 c
|
||||
|
||||
data Wall
|
||||
@@ -500,21 +482,9 @@ data ForceField = FF
|
||||
}
|
||||
data FFState = FFDestroyable { _ffsHP :: Int }
|
||||
|
||||
data CreatureState = CrSt
|
||||
{ _goals :: [[Goal]]
|
||||
, _stance :: Stance
|
||||
, _faction :: Faction
|
||||
, _crDamage :: [DamageType]
|
||||
, _crPastDamage :: Int
|
||||
, _crSpState :: CrSpState
|
||||
, _crApplyDamage :: [DamageType] -> Creature -> (World -> World,Creature)
|
||||
, _crDropsOnDeath :: ItemDropType
|
||||
}
|
||||
|
||||
makeLenses ''World
|
||||
makeLenses ''Cloud
|
||||
makeLenses ''Creature
|
||||
makeLenses ''CreatureState
|
||||
makeLenses ''LightSource
|
||||
makeLenses ''TempLightSource
|
||||
makeLenses ''Stance
|
||||
|
||||
Reference in New Issue
Block a user