Welcome to mirror list, hosted at ThFree Co, Russian Federation.

bpy.app.timers.3.py « examples « python_api « doc - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: a738f9ca01ca14708dbdf7ae5c69d1750f134c3f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
"""
Run a Function n times every x seconds
--------------------------------------
"""
import bpy

counter = 0


def run_10_times():
    global counter
    counter += 1
    print(counter)
    if counter == 10:
        return None
    return 0.1


bpy.app.timers.register(run_10_times)