Updated detect dawn script