Implement wall penetrating bullets
This commit is contained in:
@@ -88,13 +88,14 @@ mvGenBullet' w bt
|
||||
$ set ptPict' (bulLine col wth (p:p:ps))
|
||||
$ set btTimer' (t-1) bt
|
||||
)
|
||||
| otherwise = case thingsHitExceptCr mcr p (p +.+ vel) w of
|
||||
[] -> (w, Just $ set btPassThrough' Nothing
|
||||
$ set btTrail' (p +.+ vel :p:ps)
|
||||
$ set ptPict' (bulLine col wth (p +.+ vel:p:ps))
|
||||
$ set btTimer' (t-1) bt
|
||||
)
|
||||
hits -> hiteff bt hits w
|
||||
| otherwise = hiteff bt (thingsHitExceptCr mcr p (p +.+ vel) w) w
|
||||
-- case thingsHitExceptCr mcr p (p +.+ vel) w of
|
||||
-- [] -> (w, Just $ set btPassThrough' Nothing
|
||||
-- $ set btTrail' (p +.+ vel :p:ps)
|
||||
-- $ set ptPict' (bulLine col wth (p +.+ vel:p:ps))
|
||||
-- $ set btTimer' (t-1) bt
|
||||
-- )
|
||||
-- hits -> hiteff bt hits w
|
||||
where mcr = _btPassThrough' bt
|
||||
col = _btColor' bt
|
||||
(p:ps) = _btTrail' bt
|
||||
|
||||
Reference in New Issue
Block a user