{-# LANGUAGE GeneralizedNewtypeDeriving #-} module Game ( Bullet(..) , GameState(..) ) where import Level import Tank import Control.Monad import Control.Monad.State import Data.Fixed data Bullet = Bullet { bulletX :: !Micro , bulletY :: !Micro , bulletDir :: !Micro , bulletSpeed :: !Micro , bulletBouncesLeft :: !Int , bulletTank :: !Int } deriving (Eq, Show) data GameState = GameState { level :: !Level , tanks :: ![Tank] , bullets :: ![Bullet] } deriving (Show)