Skip to content

Instantly share code, notes, and snippets.

@boyanov83
Created September 16, 2014 16:45
Show Gist options
  • Save boyanov83/5031670c037cfd2abf4a to your computer and use it in GitHub Desktop.
Save boyanov83/5031670c037cfd2abf4a to your computer and use it in GitHub Desktop.
import java.awt.Color;
import java.awt.Graphics;
import javax.swing.JFrame;
public class Main extends JFrame {
private static final long serialVersionUID = 1L;
private Player player;
private Rain rain;
public Main() {
player = new Player(75, 75, 20, 20);
rain = new Rain();
}
public void paint(Graphics g) {
//g.setColor(Color.blue);
//player.draw(g);
while (true) {
rain.draw(g);
}
}
public static void main(String[] args) {
Main main = new Main();
main.setSize(500, 500);
main.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
main.setResizable(false);
main.setVisible(true);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment