Cleanup particles slightly
This commit is contained in:
@@ -645,12 +645,16 @@ aTeslaArc :: Creature -> World -> World
|
||||
aTeslaArc cr w
|
||||
= teslaGunFlashAt (pos +.+ 5 *.* unitVectorAtAngle dir)
|
||||
$ set randGen g w
|
||||
& particles %~ (makeTeslaArcAt pos dir :)
|
||||
& particles %~ (makeTeslaArcAt col pos dir :)
|
||||
where
|
||||
pos = _crPos cr +.+ ((_crRad cr +1) *.* unitVectorAtAngle dir)
|
||||
+.+ sideOffset *.* vNormal (unitVectorAtAngle dir)
|
||||
(sideOffset,g) = randomR (-5,5) $ _randGen w
|
||||
pos = _crPos cr +.+ (_crRad cr +1) *.* unitVectorAtAngle dir
|
||||
dir = _crDir cr
|
||||
(colid,g) = randomR (0::Int,3) $ _randGen w
|
||||
col = chooseColor colid
|
||||
chooseColor 0 = white
|
||||
chooseColor 1 = azure
|
||||
chooseColor 2 = blue
|
||||
chooseColor _ = cyan
|
||||
|
||||
remoteShellPic' :: Projectile -> Picture
|
||||
remoteShellPic' pj
|
||||
|
||||
Reference in New Issue
Block a user