Auto ores, mining and nullpointer fix