Remove force fields, cleanup
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
{- |
|
||||
Effects of bullets upon impact with walls or creatures, and possibly force fields.
|
||||
Effects of bullets upon impact with walls or creatures.
|
||||
-}
|
||||
module Dodge.Particle.Bullet.HitEffect
|
||||
where
|
||||
@@ -22,9 +22,6 @@ import Picture
|
||||
import System.Random
|
||||
import Control.Lens
|
||||
import Control.Monad.State
|
||||
--import Data.Maybe
|
||||
--import qualified Data.IntMap.Strict as IM
|
||||
--
|
||||
-- | Basic bullet hit creature effect.
|
||||
bulHitCr :: Particle -> Point2 -> Creature -> World -> World
|
||||
bulHitCr bt p cr w
|
||||
@@ -187,14 +184,13 @@ bulConWall'
|
||||
bulConWall' _ p wl = damageBlocksBy 1 wl .
|
||||
over worldEvents ( makeShockwaveAt [] p 15 4 1 white . )
|
||||
|
||||
|
||||
hvBulHitWall'
|
||||
hvBulHitWall
|
||||
:: Particle
|
||||
-> Point2 -- ^ Impact point
|
||||
-> Wall
|
||||
-> World
|
||||
-> World
|
||||
hvBulHitWall' bt p x w = damageBlocksBy 5 x $ set randGen g $ foldr ($) w (sparks pOut sv)
|
||||
hvBulHitWall bt p x w = damageBlocksBy 5 x $ set randGen g $ foldr ($) w (sparks pOut sv)
|
||||
where
|
||||
sp = head $ _btTrail' bt
|
||||
pOut = p +.+ safeNormalizeV (sp -.- p)
|
||||
|
||||
Reference in New Issue
Block a user