@Override
    public void paintComponent(Graphics g) {
        super.paintComponent(g);

        for (Section s : sections) {
            if (s.isOpened()) {
                if (s.isBomb()) {
                    g.setColor(Color.RED);
                } else
                    g.setColor(Color.GREEN);
            } else {
                g.setColor(Color.LIGHT_GRAY);
            }
            g.fillRect(s.getX() * 50, s.getY() * 50, 50, 50);

            g.setColor(Color.BLACK);
            if (s.isOpened()) {
                if (s.isBomb()) {
                    g.drawString("Bomb!", (s.getX()*50) + 5, (s.getY()*50) + 25);
                } else {
                    g.drawString("+" + s.getPoints(), (s.getX()*50) + 5, (s.getY()*50) + 25);
                    if (s.containsHeart()) {
                        g.drawImage(heart, (s.getX() * 50) + 5, (s.getY()*50) + 35, null);
                    }
                }
            }
            g.drawRect(s.getX() * 50, s.getY() * 50, 50, 50);
        }
        int x = getWidth() - 30;
        for (int i = 0; i < GlobalVars.lives; i++) {
            g.drawImage(heart, x - (i * 20), 20, null);
        }
        g.setColor(Color.BLACK);
        g.drawString("Points: " + GlobalVars.points, x - 100, 50);
    }