Refactor beams

This commit is contained in:
2022-07-21 00:32:29 +01:00
parent 39117b4dfe
commit e2ccf7296a
10 changed files with 94 additions and 54 deletions
+12 -2
View File
@@ -1,14 +1,24 @@
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE StrictData #-}
module Dodge.Data.Targeting where
import Geometry.Data
import Control.Lens
data Targeting
= NoTargeting
| Targeting
{ _tgPos :: Maybe Point2
, _tgUpdate :: TargetUpdate --Item -> Creature -> World -> Targeting -> (World, Targeting)
, _tgDraw :: TargetDraw --Item -> Creature -> Configuration -> World -> Picture
, _tgID :: Maybe Int
, _tgActive :: Bool
}
data TargetUpdate = NoTargetUpdate
| TargetLaserUpdate
| TargetRBPressUpdate
| TargetRBCreatureUpdate
| TargetCursorUpdate
data TargetDraw = NoTargetDraw
| TargetDistanceDraw
| SimpleDrawTarget
| TargetRBCreatureDraw
makeLenses ''Targeting