pong: fix which bot should idle
This commit is contained in:
parent
be4eb906c5
commit
51ec729979
@ -122,7 +122,7 @@ class PongCore {
|
||||
|
||||
// Simulate game logic
|
||||
simulate() {
|
||||
if (this.ball.dx > 0) {
|
||||
if (this.ball.dx < 0) {
|
||||
this.botInput(this.left);
|
||||
this.botIdle(this.right);
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user