Changed mine generation logic