Mwni / blender-animation-retargeting

Add-on for Blender that allows the transfer of animations and poses from one armature to another
484 stars 48 forks source link

Error on blender 2.91 #12

Closed tlf30 closed 3 years ago

tlf30 commented 3 years ago

Hello, I am getting an error on blender 2.91:

Python: Traceback (most recent call last):
  File "C:\Users\Trevor\AppData\Roaming\Blender Foundation\Blender\2.91\scripts\addons\blender-animation-retargeting-master\alignment.py", line 136, in execute
    leave_edit()
  File "C:\Users\Trevor\AppData\Roaming\Blender Foundation\Blender\2.91\scripts\addons\blender-animation-retargeting-master\alignment.py", line 75, in leave_edit
    s.update_drivers()
  File "C:\Users\Trevor\AppData\Roaming\Blender Foundation\Blender\2.91\scripts\addons\blender-animation-retargeting-master\addon.py", line 219, in update_drivers
    drivers.build()
  File "C:\Users\Trevor\AppData\Roaming\Blender Foundation\Blender\2.91\scripts\addons\blender-animation-retargeting-master\drivers.py", line 153, in build
    clear()
  File "C:\Users\Trevor\AppData\Roaming\Blender Foundation\Blender\2.91\scripts\addons\blender-animation-retargeting-master\drivers.py", line 116, in clear
    dest_pose.driver_remove('location')
AttributeError: 'NoneType' object has no attribute 'driver_remove'

location: <unknown location>:-1
tlf30 commented 3 years ago

I'm getting the same error on Blender 2.83.

Mwni commented 3 years ago

At which step did this occur?

tlf30 commented 3 years ago

The error occurs at ever step after selecting the source and destination. The first appearance of the error is when adding the bone map, and it will occur every step following, including baking and attempting to remove the bone map. Baking does not work. I tested several models, but all FBX exported from the same tool. A friend of mine using one of the same models on blender 2.91 does not get this error. I have tried importing a working bone map, and building a new one.

Mwni commented 3 years ago

I tested the addon on 2.92 and got no errors either. I'm going to need a copy of your armature to test it out myself.

tlf30 commented 3 years ago

@Mwni I think I have finally figured out what I was doing wrong. In my tests I hade accidently deleted some of the leaf bones on the target. I am going to assume the error was that it was unable to find the bone, which consequently means I cannot remove mapping to that bone.

Mwni commented 3 years ago

The bones you deleted were mapped beforehand? If so, yes that would definitely throw an exception. Thanks for reporting. Will add to to-do list.

tlf30 commented 3 years ago

Yep, that is exactly what I did wrong. Thank you