Commit efb9edad authored by Rominho15's avatar Rominho15
Browse files

Version 4 :

- Gestion des méthodes "Curseur" et "Rotation"
- Gestion du niveau 1 et 2, + transition
parent 9ab12018
Pipeline #1011 skipped
......@@ -148,8 +148,9 @@ public class GameController {
}
public void moveBatAccelerometer(float x) {
int newX = gameModel.getBat().getX()+(int)x;
gameModel.getBat().setX(newX);
int addX = (int)-x;
int oldX = gameModel.getBat().getX() + gameModel.getBat().getWidth()/2;
gameModel.getBat().setX(oldX+addX);
}
public int collides(Ball ba, Bat bt) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment