diff options
author | Alexander Gavrilov <angavrilov@gmail.com> | 2020-11-10 19:30:01 +0300 |
---|---|---|
committer | Alexander Gavrilov <angavrilov@gmail.com> | 2020-11-10 19:30:01 +0300 |
commit | 35c23b4db494e58538a677c4fb0ec9ec1e8ffaa8 (patch) | |
tree | 9c5b9af9ac62fe3eff6d100a2c00f442069b12f1 /rigify/utils | |
parent | fa9e1d797972ae7a13bd6dc7849625c24fcf108a (diff) | |
parent | 8b555809bb31d7bfa929681f396d9a836f7e8acc (diff) |
Merge branch 'blender-v2.91-release'
Diffstat (limited to 'rigify/utils')
-rw-r--r-- | rigify/utils/naming.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/rigify/utils/naming.py b/rigify/utils/naming.py index 0339e523..415dddaf 100644 --- a/rigify/utils/naming.py +++ b/rigify/utils/naming.py @@ -314,4 +314,12 @@ def choose_derived_bone(generator, original, subtype, *, by_owner=True, recursiv if len(matching) > 0: return matching[0] + # Try matching bones created by legacy rigs just by name - there is no origin data + from ..base_generate import LegacyRig + + if isinstance(generator.bone_owners.get(direct), LegacyRig): + if not by_owner or generator.bone_owners.get(original) is generator.bone_owners[direct]: + assert direct in bones + return direct + return None |