Find the coordinates of the sprites ie top right, top left, bottom right, bottom left corners. Then check whether any of those points overlap. Here's a tutorial on it that should be helpful. https://developer.mozilla.org/en-US/docs/Games/Tutorials/2D_Breakout_game_pure_J...
VonHendrik
Creator of
Recent community posts
Yeah i think both of those play off each other right. Like it's hard to get your head around a good strategy when you're spending so much time just getting to a destination . I think this one of those ideas that's come out of these jams that would be simply improved by having a little more pixel space to play with. Great idea, that's just a bit hampered by the design restrictions.
Whoa this is such a creative game, the mechanics nice and polished, the art is great to look at, but why am i cursing your name as i fall through the air trying to land on those dang platforms the size of a fleas breakfast for what is honestly like the fiftieth time. And then why did i go back and play trough them all over again? Just fantastic.
All these dang bugs have finally gotten on Sir Reginald last nerves, so it's off to the garden shed to nip together a thorium powered laser that'll steal the very essence of those fanddangled little critters. But can he survive their enveloping swarm. Thankfully the writers just decided he would get special regeneration powers, and didn't even bother to explain it. So enjoy exploding yourself to high and reloading.
------------------------
- For every bug you hit you gain a life
- Each life you only have 6 bullets
- If you're hit by a bug, you will explode
- But if you die you get all your bullets back
- Try to survive as long as you can
------------------------
CONTROLS
W,A,S,D - Movement
Arrow keys - Fire
Explode to reload
Awesome thanks! Yeah im just scaling it up and working from there.
Yeah in testing out the implementation i had to find work arounds to keep everything snapped to the pixel grid and constrained down to the nokia's fps. I ended up turning every pixel into a 1x1 rectangle and the scaling methods in Löve2d seemed to handle it. For the fps i just gated any calls inside the update and draw functions to happen only on the specific frames.
Plus homebrew collision detection are so much easier when you're dealing with movements expresed in integers.