Files
loop/src/Dodge/PrWdLsLs.hs
T

14 lines
425 B
Haskell

module Dodge.PrWdLsLs where
import Control.Lens
import Dodge.Data.World
import Dodge.WdP2f
import Geometry.Vector3D
doPrWdLsLs :: PrWdLsLs -> Prop -> World -> LightSource -> LightSource
doPrWdLsLs x = case x of
PrWdLsId -> \_ _ -> id
PrWdLsSetPosition y off -> \_ w ->
lsParam . lsPos .~ addZ 0 (fst (doWdP2f y w)) +.+.+ rotate3z (snd (doWdP2f y w)) off
PrWdLsSetColor c -> \_ _ -> lsParam . lsCol .~ c