add threads to script