@Override
    public void mouseReleased(MouseEvent e) {
        spawned = false;

        //check to see if they have clicked on one of the "buttons"
        if (gameStarted == false) {

            if (instructions == true) {
                //go back from instructions page
                instructions = false;
            } else if (displayHighScore == true) {
                //go back from high scores
                displayHighScore = false;
            } else if (960 < e.getX() && e.getX() < 1500 && 610 < e.getY() && e.getY() < 700) {
                //clicked on instructions
                instructions = true;
            } else if (960 < e.getX() && e.getX() < 1500 && 740 < e.getY() && e.getY() < 820) {
                //clicked on high scores
                displayHighScore = true;
            } else if (1120 < e.getX() && e.getX() < 1300 && 485 < e.getY() && e.getY() < 575) {
                //clicked on play
                gameStarted = true;//start game
                pause = false;
                level = 1;//set level to one

                //if space is being held (cheat is on) jump to level 15
                if (cheatON == true) {
                    level = 15;
                }

                //rest field
                resetField();
            }

        }

        //if you have paused
        if (pause == true) {
            //if you decide to quit

            if (80 < e.getX() && e.getX() < 260 && 725 < e.getY() && e.getY() < 800) {
                pause = false;
                gameOver = true;
            }

        }

        //if you have won the level proced to next level
        if (levelWon == true) {
            //rest field
            resetField();
        }
        //if you have failed replay level
        if (levelFail == true) {
            levelFail = false;
            //rest field
            resetField();
        }
    }