Skip to content

Part 6 - collision detection "player vs snowball"

Compare
Choose a tag to compare
@ped7g ped7g released this 06 Feb 13:33
· 16 commits to master since this release
fe6ce5e

calculating the collision based on distance between the centre point player sprite and snowball (not pixel-level collision masking individual pixels of sprites, just two "virtual circles", when overlap = collision)

When collision happens, the code will add extra "sparks" sprite over the snowball, and change palette offset of the main character.

(the effects are for debug/educative purposes, probably not to remain for final version)