Merge pull request #655 from NeroBurner/paddle_hor_fix
Paddle: compare ballX coordinate with horizontal resolution
This commit is contained in:
commit
fafb998b8c
|
@ -47,8 +47,8 @@ void Paddle::Refresh() {
|
|||
dy *= -1;
|
||||
}
|
||||
|
||||
// checks if it has touched the side (left side)
|
||||
if (ballX >= LV_VER_RES - ballSize - 1) {
|
||||
// checks if it has touched the side (right side)
|
||||
if (ballX >= LV_HOR_RES - ballSize - 1) {
|
||||
dx *= -1;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user