View Single Post
  #2319  
Old 15.06.2022, 17:45
mgpai mgpai is offline
Script Master
 
Join Date: Sep 2013
Posts: 1,528
Default

Quote:
Originally Posted by StefanM View Post
(Random) delay while downloading
Quote:
Originally Posted by Jiaz View Post
@mgpai: synchronous script
Code:
/*
    Random delay before download
    Trigger : A Download Started
    IMPORTANT : Enable "Synchronous execution" checkbox in the top panel
*/

var seconds = Math.floor(Math.random() * 5) + 1 // 1 to 5 seconds

while (seconds && !link.aborting) {
    sleep(seconds * 1000);
    seconds--;
}
Reply With Quote