1
$\begingroup$

I see many examples that attach custom properties to objects eg.

bpy.types.Object.mytype = bpy.props.StringProperty()

What are the other useful places to put custom properties. In particular I want to store a global to the blend file itself?

 len(dir(bpy.types)) # -> 3282!

I see there is a type BlendData

$\endgroup$
0

1 Answer 1

3
$\begingroup$

Only ID types, Bones and PoseBones support properties:

Custom properties can be added to any subclass of an ID, Bone and PoseBone.

http://www.blender.org/documentation/blender_python_api_2_70_release/bpy.props.html

The only type with just a single instance is bpy.types.WindowManager, but its properties aren't serialized to .blend.

$\endgroup$

Not the answer you're looking for? Browse other questions tagged .