Class Sprite


public class Sprite extends GameObject
  • Field Details

    • x

      protected int x
    • y

      protected int y
    • width

      protected int width
    • height

      protected int height
    • image

      protected Image image
  • Constructor Details

    • Sprite

      public Sprite()
  • Method Details

    • loadImage

      protected void loadImage(String name)
    • render

      protected void render(Graphics2D g)
      Description copied from class: GameObject
      Method who render a object on screen (invoke on begin of each frames).
      Overrides:
      render in class GameObject