package com.vampirehemophile.ghosts.gamestates;

import javax.swing.JPanel;

/** Main game state. */
public class PlayState extends State {

  /** main game state's panel. */
  @SuppressWarnings("serial")
  private class PlayPanel extends JPanel {

    /** Constructs a PlayPanel object. */
    public PlayPanel() {
      super();
    }
  }


  /** states panel. */
  private JPanel panel;


  /** Constructs a PlayState object. */
  public PlayState() {
    super();
    panel = new PlayPanel();
  }

  /** {@inheritDoc} */
  @Override
  public JPanel render() {
    return panel;
  }
}

@@ -68,16 +68,236 @@
 .JPanel;
+%0Aimport javax.imageio.ImageIO;%0Aimport java.awt.Graphics;%0Aimport java.awt.Graphics2D;%0Aimport java.awt.Color;%0Aimport java.awt.image.BufferedImage;%0Aimport java.awt.Dimension;%0Aimport java.io.File;%0Aimport java.io.IOException;
 %0A%0A/** Ma
@@ -540,24 +540,867 @@
    super();%0A
+      setPreferredSize(new Dimension(600, 600));%0A    %7D%0A%0A    /** %7B@inheritDoc%7D */%0A    @Override%0A    protected void paintComponent(Graphics g) %7B%0A      super.paintComponent(g);%0A      Graphics2D g2d = (Graphics2D) g;%0A%0A      BufferedImage lightTile = null;%0A      BufferedImage darkTile = null;%0A      try %7B%0A        lightTile = ImageIO.read(State.getResource(%22/images/lighttile.png%22));%0A        darkTile  = ImageIO.read(State.getResource(%22/images/darktile.png%22));%0A      %7D catch (IOException e) %7B%7D%0A      boolean dark = true;%0A%0A      for (int i = 0; i %3C 6; i++) %7B%0A        for (int j = 0; j %3C 6; j++) %7B%0A          if (dark) %7B%0A            g2d.drawImage(darkTile, i*100, j*100, 100, 100, null);%0A          %7D else %7B%0A            g2d.drawImage(lightTile, i*100, j*100, 100, 100, null);%0A          %7D%0A          dark = !dark;%0A        %7D%0A        dark = !dark;%0A      %7D%0A
     %7D%0A  %7D%0A%0A%0A

Add beginning of PlayState