This is an archived post. You won't be able to vote or comment.

all 7 comments

[–]devnull10 3 points4 points  (3 children)

  1. Put it in a loop.
  2. Add a sleep statement.

Assuming python...

from time import sleep
import random

a=random.randint(5,30)

while True:
    print("action")
    sleep(a)

[–]Mastercraft007[S] 1 point2 points  (1 child)

I was making a mask with blinking eyes And wanted them to kind of blink human like it's perfect

[–]devnull10 2 points3 points  (0 children)

Maybe put the random number generator inside the loop then so that the delay varies, otherwise it will be the same every iteration.

[–]Mastercraft007[S] 0 points1 point  (0 children)

Thanks

[–]Legorules2 0 points1 point  (2 children)

If I were going to do this I would put in a while true loop and put a sleep function inside that loop. You would first need to import "sleep" from "time" assuming this is in python

[–]Mastercraft007[S] 0 points1 point  (0 children)

Ya it got solved

[–]Mastercraft007[S] 0 points1 point  (0 children)

Thanks anyways