SHARE
TWEET

Untitled

a guest Mar 24th, 2019 51 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.     public static void repaint(int w, int h, float accelerotmetre[]) {
  2.  
  3.         float Vx=3;
  4.         float Vy=3;
  5.  
  6.         /*{
  7.             radius +=3;
  8.             x1=300;
  9.             y1=400;
  10.         }*/
  11.  
  12.                 if (accelerotmetre[1] < -2 && y >= 60 ) {
  13.                     y -= Vy - (accelerotmetre[1]);
  14.                 }
  15.  
  16.                 if (accelerotmetre[1] > 2 &&y <= h-61) {
  17.                     y += Vy + (accelerotmetre[1]);
  18.                 }
  19.  
  20.  
  21.                 if (accelerotmetre[0] < -2 && x <= w-61) {
  22.                     x += Vx - (accelerotmetre[0] );
  23.                 }
  24.                 if (accelerotmetre[0] > 2 && x >=60) {
  25.                     x -= Vx + (accelerotmetre[0]);
  26.                 }
  27.  
  28.     }
  29. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top