Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Collision detection #9

Open
ArtskydJ opened this issue Jan 14, 2017 · 0 comments
Open

Collision detection #9

ArtskydJ opened this issue Jan 14, 2017 · 0 comments

Comments

@ArtskydJ
Copy link
Contributor

Right now, the collision detection isn't a circle o, it's more of a plus sign +. So you're able to overlap the corner of the ball with a block.

If you're not moving left or right, then it doesn't check for x collisions.

If you're not moving up or down, then it doesn't check for y collisions.

capture

I wonder if we should use some sort of game engine. http://craftyjs.com/ looks interesting.

Or maybe we need to figure out a better algorithm.

I messed with an algorithm which you can see here https://github.com/ArtskydJ/html5-mulg/commit/2241ddfbd6aff956b6fbc1c171d2f5d326546eeb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant