Changed paddle speed
This commit is contained in:
parent
ee23f2756a
commit
a0a70d69ed
@ -11,7 +11,7 @@
|
||||
#include "include/utilityFunctions.h"
|
||||
|
||||
void updatePaddle(Uint32 tickrate, paddle *thePaddle, char moveX, int winWidth, int winHeight) {
|
||||
thePaddle->x += moveX * 0.5 * tickrate;
|
||||
thePaddle->x += moveX * 0.3 * tickrate;
|
||||
if (thePaddle->x < 0 - (thePaddle->width / 2)) thePaddle->x = 0 - (thePaddle->width / 2);
|
||||
if (thePaddle->x > winWidth - (thePaddle->width / 2)) thePaddle->x = winWidth - (thePaddle->width / 2);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user