Rigify regenerate with keep previous driver

I worked on it without knowing that if I regenerate the rigify, the existing driver disappears. Is there any way to keep the driver even if I regenerate the rigify?

Hi, i donā€™t know the answer to that, but are you able to copy and paste the drivers?

Itā€™s possible, but i have to rework every time i regenerate the rig.

If you know your ways around Python Iā€™d recommend writing a script that restores all the custom stuff you did.
Thatā€™s what I usually do, and in the long run, itā€™s the least painful option ā€¦

1 Like

i have no knowledge of Python, itā€™s almost impossible. Still, Iā€™ll investigate

Yeah the point of an auto-rig is that you are not supposed to edit the rigā€™s drivers or internals. Everything needs to be setup from the beginning.
Maybe there is a better way to configure the meta-rig in a way you donā€™t have to tweak the final rig.

If there is no other way, well you have to do that in the very end, or as Helmut said itā€™s something one might solve with a python script.
It depends what you do with these drivers but chances are that the python code isnā€™t that difficult to write and to adapt. And basically once you know whatā€™s needed for one driver the rest is copy/paste and changing names. It might be a learning opportunity to start looking into python if nothing better comes out !
In that case maybe ask in the python section of the forum how to edit a driver or how to create one. Explaining well your case and maybe someone will come up with some bits of code.

Good luck !

Or get AI to write it, itā€™s what I do, since I really canā€™t code to save myself.

1 Like

Indeed good idea ! However this might makes it a bit more difficult to edit and adapt to your needs as AI might put some random, useless junk code there.
Iā€™d say that nowadays every advanced artists especially ones that tend to touch different areas should at least be able to edit or write a few lines of python.

These kind of challenges are good opportunities to dives into that, Iā€™m not saying about writing an addon, but something that takes less than 5 lines of code can be eventually broken down in understandable chunks.

Seems like a giant pain and slow down at first but this makes things really simpler in the long run.
What Iā€™m saying is that using AI is fine, but itā€™s even better to be able to decipher
and adapt what code it generates. Therefore you use AI for inspiration and getting faster to the result rather than being ā€œenslavedā€ to it.
Just my 2 cents on the subject :slight_smile:

I was thinking of suggesting that, however if it doesnā€™t run as intended straight out of the box, AI wonā€™t debug it for you. Without any Python or general programming experience youā€™ll end up lost in the forest pretty quickly.

It can take a few tries, etc and it sure helps to have a fairly good knowledge of using Blender and maybe some sort of ā€˜coding logicā€™, but it sure is doable, since itā€™s what Iā€™ve done.

You can partly ā€˜cheatā€™, in that if you have the scripting workspace selected and manually do what you want to do, Blender should put some of the ā€˜codeā€™ in the console. So you can feed that into AI, along with a detailed explanation and usually get the few lines of python you need.

As you say, itā€™s not an addon, itā€™s just the code to replicate the manual steps.
And in fact you can get AI to debug it for you. You cut and paste the error text back into the AI and it will start to try and figure it out.

The biggest issue, well, two really, is access to the most advance models usually isnā€™t free and in some cases, all the free ones and even some paid ones, arenā€™t exactly up to date with the Blender API.

So for simple stuff that hasnā€™t really changed, it can work fairly well, but say try to do something with Bones Collections, then you are in trouble.

Even if they say the model was trained up to Feb 2024, chances are the Blender training data will still be 2-3 years.

1 Like

Interesting ! I think itā€™s great use of AI, we should see it as a partner here to help rather than ā€œsomeoneā€ thatā€™s going to do everything for you.
Anyway itā€™s even better if you use that as a learning opportunity so eventually youā€™re able to fill the gaps when the API is updated or the AI failā€¦

ok iā€™m just copy paste and back up the driver value

1 Like