From 746103d9e9213a1638db1e6bc6cd5292404a517c Mon Sep 17 00:00:00 2001 From: Roman Volodin Date: Thu, 8 Dec 2022 14:59:15 +0300 Subject: [PATCH] Show message 'Armature objects must be in Pose mode' --- dynamic_parent.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dynamic_parent.py b/dynamic_parent.py index 7b72cc0..c802fcb 100755 --- a/dynamic_parent.py +++ b/dynamic_parent.py @@ -21,7 +21,7 @@ bl_info = { "name": "Dynamic Parent", "author": "Roman Volodin, roman.volodin@gmail.com", - "version": (1, 0, 0), + "version": (1, 0, 1), "blender": (2, 83, 0), "location": "View3D > Tool Panel", "description": "Allows to create and disable an animated ChildOf constraint", @@ -247,6 +247,9 @@ def execute(self, context): frame = context.scene.frame_current if obj.type == 'ARMATURE': + if obj.mode != 'POSE': + self.report({'ERROR'}, "Armature objects must be in Pose mode.") + return {'CANCELLED'} obj = bpy.context.active_pose_bone const = get_last_dymanic_parent_constraint(obj) if const: