Refactor basic explosion
This commit is contained in:
@@ -34,7 +34,6 @@ bulHitCr' bt p cr w =
|
||||
crKnockBack cid = (/) 1 $ (+) 2 $ _crMass $ _creatures w IM.! cid
|
||||
hasArmour cr = any (\it -> it ^? itIdentity == Just FrontArmour) $ _crInv cr
|
||||
cid = _crID cr
|
||||
sID = newParticleKey w
|
||||
(d1,g) = randomR (-0.7,0.7) $ _randGen w
|
||||
(colID,_) = randomR (0,11) $ _randGen w
|
||||
hitEffect = addDamage
|
||||
@@ -208,7 +207,6 @@ hvBulHitWall' bt p x w = damageBlocks x
|
||||
= case wall ^? blHP of
|
||||
Just hp -> foldr (\j -> over (walls . ix j . blHP) (\y -> y - 20)) w (_blIDs wall)
|
||||
_ -> w
|
||||
sID = newParticleKey w
|
||||
cs = take 10 $ randomRs (0,11) $ _randGen w
|
||||
ds = randomRs (-0.7,0.7) $ _randGen w
|
||||
ts = randomRs (4,8) $ _randGen w
|
||||
|
||||
Reference in New Issue
Block a user