Closed TetoTheSquirrelFox closed 4 years ago
Unfortunately, your posted code is corrupted by the loss of indentation. Try posting a patch as an attachment, or using Markdown formatting.
Let's try... edit : much better... thanks for the help !
def is_ik_armature(armature=None):
if not armature:
armature = get_active_armature()
if armature and armature.type == 'ARMATURE':
for b in armature.data.bones:
if 'IK' in b.name:
return True
elif armature and armature.type != 'ARMATURE':
logger.warning("Cannot get the bones because the obj is not an armature")
return False
return False
Wow. So simple it hurts lol.
I just changed this on my local system, will be committing this change to the repo soon.
Describe the bug When user wants to use IK kinematics, the poses don't work properly after character creation. The case is expected but doesn't work properly, user should not be able to choose a pose, and he can actually. With MB-Lab-dev version at least.
Where is the problem + Screenshot The guilty is function is_"ik_armature(armature=None)" in utils.py.
We can see that if armature != None, function always return false...
Commit by a screenshot![image](https://user-images.githubusercontent.com/59537161/71928759-766f0a00-3198-11ea-8a1f-0d2ba24fe882.png)
Commit in code def is_ik_armature(armature=None): if not armature: armature = get_active_armature() if armature and armature.type == 'ARMATURE': for b in armature.data.bones: if 'IK' in b.name: return True elif armature and armature.type != 'ARMATURE': logger.warning("Cannot get the bones because the obj is not an armature") return False return False
See ya' ^^ (by the way, if someone can explain to me how to format correctly a code to allow it to be copy/pasted directly... On to pull requests maybe? I really don't know how to do that)