fix: multiple drivers with same data_path on different index

This commit is contained in:
Swann 2020-12-24 14:46:18 +01:00
parent a0c0f781e2
commit 7920f67aea
No known key found for this signature in database
GPG Key ID: E1D3641A7C43AACB

View File

@ -56,7 +56,7 @@ def load_driver(target_datablock, src_driver):
loader = Loader()
drivers = target_datablock.animation_data.drivers
src_driver_data = src_driver['driver']
new_driver = drivers.new(src_driver['data_path'])
new_driver = drivers.new(src_driver['data_path'], index=src_driver['array_index'])
# Settings
new_driver.driver.type = src_driver_data['type']