{- Helper functions for particles.  -}
module Dodge.WorldEvent.HelperParticle
    ( ptSimpleTime
    ) where
import Dodge.Data

{- A simple timer update for particles.  -}
ptSimpleTime :: Int -> World -> Particle -> (World, Maybe Particle)
ptSimpleTime 0 w _ = (w, Nothing)
ptSimpleTime n w pt = (w, Just $ pt {_ptUpdate = ptSimpleTime (n-1)})
