Added the possibility to define a sleeptime to a lot of .pl scripts and code cleanup.