Added the line frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); to chessgame so the program quits when  the window is closed. Just a little pet peeve I was having.