diff --git a/source/create_widgets.py b/source/create_widgets.py index 9766554..e2bf948 100644 --- a/source/create_widgets.py +++ b/source/create_widgets.py @@ -9,7 +9,7 @@ from math import cos, sin, pi def create_widget(name): """Create an empty widget object and return the object""" - prefs = bpy.context.preferences.addons["add_camera_rigs"].preferences + prefs = bpy.context.preferences.addons[__package__].preferences widget_prefix = prefs.widget_prefix obj_name = widget_prefix + name scene = bpy.context.scene diff --git a/source/prefs.py b/source/prefs.py index bdb2a9d..26240cd 100644 --- a/source/prefs.py +++ b/source/prefs.py @@ -7,7 +7,7 @@ from bpy.props import StringProperty class AddCameraRigsPreferences(AddonPreferences): - bl_idname = 'add_camera_rigs' + bl_idname = __package__ # Widget prefix widget_prefix: StringProperty( diff --git a/source/ui_panels.py b/source/ui_panels.py index 14f7ef6..0ffa5de 100644 --- a/source/ui_panels.py +++ b/source/ui_panels.py @@ -93,9 +93,9 @@ class ADD_CAMERA_RIGS_PT_camera_rig_ui(Panel, CameraRigMixin): if rig["rig_id"].lower() == "crane_rig": col = layout.column(align=True) col.label(text="Crane Arm:") - col.prop(pose_bones["Crane_height"], + col.prop(pose_bones["Crane_Height"], 'scale', index=1, text="Arm Height") - col.prop(pose_bones["Crane_arm"], + col.prop(pose_bones["Crane_Arm"], 'scale', index=1, text="Arm Length") # 2D rig stuff