Tweak explosions
This commit is contained in:
@@ -74,23 +74,18 @@ makeExplosionAt p vel w =
|
||||
w
|
||||
& soundMultiFrom [Explosion 0, Explosion 1] p bangS Nothing
|
||||
& addFlames
|
||||
-- & cWorld . lWorld . tempLightSources .:~ theTLS
|
||||
& cWorld . lWorld . worldEvents .:~ thels
|
||||
& cWorld . lWorld . worldEvents
|
||||
.:~ MakeTempLight (LSParam (addZ 20 p) 150 (V3 1 0.5 0)) 20
|
||||
& makeShockwaveAt [] p 50 50 1 white
|
||||
where
|
||||
thels = MakeTempLight (LSParam (addZ 20 p) 150 (V3 1 0.5 0)) 20
|
||||
-- theTLS = tlsTimeRadColPos 20 150 (V3 1 0.5 0) (addZ 20 p)
|
||||
fVs = replicateM 100 (randInCirc 1) & evalState $ _randGen w
|
||||
--fPs'' = replicateM 100 (fmap (15 *.*.*) randInHemisphere) & evalState $ _randGen w
|
||||
fPs'' = replicateM 100 (fmap (15 *.*.*) randInHemisphere) & evalState $ _randGen w
|
||||
(fPs', zs) =
|
||||
let (a, b, c) = unzip3 $ map fromV3 fPs''
|
||||
in (zipWith V2 a b, c)
|
||||
--fPs = map (pushAgainstWalls . (+.+) p . (*.*) 0.5) fPs'
|
||||
fPs' = replicateM 100 (randInCirc 5) & evalState $ _randGen w
|
||||
inversePushOut v = (15 - magV v) * 0.01 *.* v
|
||||
fVs' = zipWith (+.+) fVs $ map inversePushOut fPs'
|
||||
sizes = randomRs (2, 9) $ _randGen w
|
||||
times = randomRs (15, 20) $ _randGen w
|
||||
mF q z v size time = makeFlamelet (q - vel) z (v + vel) size time
|
||||
newFs = zipWith4 (mF p) zs (zipWith ((+) . xyV3) fPs'' (fmap (3 *.*) fVs')) sizes times
|
||||
mF q v size time = makeFlamelet (q - vel) (v + vel) size time
|
||||
newFs = zipWith3 (mF p) (zipWith (+) fPs' (fmap (3 *.*) fVs')) sizes times
|
||||
-- newFs = zipWith3 (mF p) (fmap (3 *.*) fVs') sizes times
|
||||
-- newFs = zipWith3 (mF p) fPs' sizes times
|
||||
addFlames w' = foldl' (flip ($)) w' newFs
|
||||
|
||||
Reference in New Issue
Block a user