added scripts. some other modifications