4 ms·
Not trying to steal anyone's thunder here, but I was so taken with this little program when I saw it earlier today on Twitter that I thought it might be fun to
by eigenvalue 3y ago
Not trying to steal anyone's thunder here, but I was so taken with this little program when I saw it earlier today on Twitter that I thought it might be fun to make it somewhat interactive, so that the players could actually influence the path of the balls using the keyboard, and also activate a "speedup" (mode but at the expense of their ability to influence the path). I also added some charts to track the state over time. You can "play" it here:
https://dicklesworthstone.github.io/ball_fighters/ https://dicklesworthstone.github.io/ball_fighters/
And code is here:
https://github.com/Dicklesworthstone/ball_fighters https://github.com/Dicklesworthstone/ball_fighters
I give full credit to the original author of this post FWIW.
- voisin 3y agoSomething seems off in the behaviour, at least on mobile. The bouncing doesn’t seem to be the same.
- eigenvalue 3y agoThe original collision behavior glitched (the ball would skip through blocks of the opposite color)when the velocity was higher, so I tweaked it a bit so that wouldn’t happen. That probably explains the difference.
- notfed 3y agoI just did my own mod, hosted here: https://identity.pub/pong-wars-web/ https://identity.pub/pong-wars-web/ Control the paddles with: - Q (Player 1, Up) - A (Player 1, Down) - P (Player 2, Up) - L (Player 2, Down) Pull request opened: https://github.com/vnglst/pong-wars/pull/5 https://github.com/vnglst/pong-wars/pull/5 > I give full credit to the original author of this post FWIW. Ditto :)
- starshadowx2 3y agoSometimes a ball gets stuck behind the paddle in your version.
- deleted 3y ago[deleted]