private void stats(Graphics g) {
        Player player = game.getPlayer();

        int rows = 5;

        int width = per * 128;
        int height = per * 16 * rows;
        int x = (getWidth() - width) / 2;
        int y = getHeight() - height;

        g.setFont(new Font(Font.SANS_SERIF, Font.PLAIN, per * 12));

        for (int xx = x; xx < x + width; xx += 32) {
            g.drawImage(ResourceManager.getImage("bdown"), xx, y - 10, null);
        }
        for (int yy = y; yy < y + height; yy += 32) {
            g.drawImage(ResourceManager.getImage("bright"), x - 10, yy, null);
            g.drawImage(ResourceManager.getImage("bleft"), x + width, yy, null);
        }
        g.drawImage(ResourceManager.getImage("cdr"), x - 10, y + height - 10, null);
        g.drawImage(ResourceManager.getImage("cdl"), x + width - 10, y + height - 10, null);

        g.drawImage(ResourceManager.getImage("cdro"), x - 12, y - 12, null);
        g.drawImage(ResourceManager.getImage("cdlo"), x + width, y - 12, null);

        g.setColor(Color.black);
        g.fillRect(x, y, width, height);

        int[] vals = new int[]{
            (int) (((double) width / (double) player.maxhp()) * ((double) player.hp())),
            (int) (((double) width / (double) player.maxXP()) * ((double) player.XP())),
            (int) (((double) width) * (double) (1 - player.hunger())),
            0, 0
        };
        Color[] cols = new Color[]{
            Color.red,
            Color.blue,
            Color.yellow,
            Color.white,
            Color.white
        };
        for (int i = 0; i < vals.length; i++) {
            g.setColor(new Color(1f, 1f, 1f, 0.25f));
            g.fillRect(x, y + height / rows * i, width, height / rows);
            g.setColor(cols[i]);
            g.fillRect(x, y + height / rows * i, vals[i], height / rows);
            g.setColor(new Color(1f, 1f, 1f, 0.5f));
            g.fillRect(x, y + height / rows * i, vals[i], (height / rows) / 3);
            g.setColor(Color.black);
            g.drawRect(x, y + height / rows * i, width, height / rows);
        }

        String[] msgs = new String[]{
            "HP " + player.hp() + "/" + player.maxhp(),
            "(LVL " + player.level() + ") XP " + player.XP() + "/" + player.maxXP(),
            String.format("Fullness %d%%", 100 - (int) (player.hunger() * 100)),
            "DMG " + (player.dmg().min() + player.dmg().max()) / 2 + "  ACC " + (int) (player.hitrate() * 100) + "%",
             player.dungeon() + ". dungeon "
        };
        for (int i = 1; i <= msgs.length; i++) {
            Rectangle2D r2d = g.getFontMetrics().getStringBounds(msgs[i - 1], g);
            Rectangle drec = new Rectangle(getWidth() / 2 - (int) r2d.getWidth() / 2,
                    y + height / rows * i - (per * 4), 0, 0);
            GraphicsUtils.drawTextOutlined(g, drec, msgs[i - 1], Color.WHITE, Color.BLACK);
        }
    }