document.write('
Data hosted with ♥ by Pastebin.com - Download Raw - See Original
  1. import java.awt.geom.Rectangle2D;
  2. import java.util.prefs.Preferences;
  3. import javax.sound.sampled.AudioInputStream;
  4. import javax.sound.sampled.AudioSystem;
  5. import javax.sound.sampled.Clip;
  6. import javax.sound.sampled.LineUnavailableException;
  7. import javax.sound.sampled.UnsupportedAudioFileException;
  8. import javax.swing.AbstractAction;
  9. import javax.swing.Action;
  10. import javax.swing.JComponent;
  11. import javax.swing.JFrame;
  12. import javax.swing.Timer;
  13. import java.util.Random;
  14. /**
  15.  * Write a description of class Player here.
  16.  * Class yang berisikan Paddle/ papan untuk memantulkan bola
  17.  * @author Fitrah Arie Ramadhan dan Ivan Muhammad Nizar
  18.  * @version Final Version, 8 Januari 2021
  19.  */
  20. public class Player
  21. {
  22.     public double x, y;  // 2d coordinates of the player for position
  23.     public double width, height; // width and height of the player
  24.     public Player(double x, double y, double width, double height)
  25.     {
  26.         this.x = x;
  27.         this.y = y;
  28.         this.width = width;
  29.         this.height = height;
  30.     }
  31. }
');