-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathstartup_handler.py
37 lines (34 loc) · 1.25 KB
/
startup_handler.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import bpy
from bpy.app.handlers import persistent
# create properties
def createDummyProperties():
wm = bpy.context.window_manager
chk_creation = 0
if not wm.fcurvehelper_commonproperties:
wm.fcurvehelper_commonproperties.add()
chk_creation = 1
if not wm.fcurvehelper_steppedproperties:
wm.fcurvehelper_steppedproperties.add()
chk_creation = 1
if not wm.fcurvehelper_generatorproperties:
wm.fcurvehelper_generatorproperties.add()
chk_creation = 1
if not wm.fcurvehelper_fngeneratorproperties:
wm.fcurvehelper_fngeneratorproperties.add()
chk_creation = 1
if not wm.fcurvehelper_envelopeproperties:
wm.fcurvehelper_envelopeproperties.add()
chk_creation = 1
if not wm.fcurvehelper_cyclesproperties:
wm.fcurvehelper_cyclesproperties.add()
chk_creation = 1
if not wm.fcurvehelper_noiseproperties:
wm.fcurvehelper_noiseproperties.add()
chk_creation = 1
if not wm.fcurvehelper_limitsproperties:
wm.fcurvehelper_limitsproperties.add()
chk_creation = 1
if chk_creation == 1: print("FCurveHelper --- dummy properties created") ###debug
@persistent
def fcurvehelper_startup(scene):
createDummyProperties()