Advertisement
far_light

Game11

Apr 18th, 2018
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.37 KB | None | 0 0
  1. // Cycle for updating and game logic
  2. for (int i = 0; i < 7; i++) {
  3.     prizes[i].draw(graph);
  4.  
  5.     if (prizes[i].isActivity && prizes[i].y + prizes[i].image.getHeight(null) >= 470) {
  6.         if (Math.abs(prizes[i].x - x) > 75) {
  7.             graph.drawImage(end, 300, 300, null);
  8.             timer.stop();
  9.             timerUpdate.stop();
  10.             break;
  11.         } else {
  12.             prizes[i].isActivity = false;
  13.         }
  14.     }
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement