I cannot check right now as I'm at work, but if you look in Ben's Big Shuffle profiles, you'll see a sleep timer. You could probably copy this line of code into yours whenever you want a sleep? Or maybe you'd have to change the quest behaviour somewhere and add it there.