Browse Source

update

main
Justin Senn 2 years ago
parent
commit
989a614829
  1. 25
      src/main/java/Snake/GameView.java
  2. 8
      src/main/java/Snake/Window.java

25
src/main/java/Snake/GameView.java

@ -0,0 +1,25 @@
package Snake;
import javax.swing.*;
import java.awt.*;
import java.util.ArrayList;
public class GameView extends JPanel
{
private final int gridSize;
private ArrayList<Drawable> views;
public GameView(int viewSize, int gridSize)
{
super();
setPreferredSize(new Dimension(viewSize, viewSize));
setDoubleBuffered(true);
setBackground(Color.BLACK);
views = new ArrayList<>();
this.gridSize = gridSize;
}
}

8
src/main/java/Snake/Window.java

@ -0,0 +1,8 @@
package Snake;
import javax.swing.*;
public class Window extends JFrame
{
}
Loading…
Cancel
Save