script work and some writeup rearranging