Problem with python and driver

posted to: Wheel Drivers

Hi Wayne,

I use Blender 3.6 and I a problem with the driver "DEF-Wheel_Front.L" (and the others 3 bones) when I write "auto_rotate(0)" in the driver: error Python.

  • Martin Bergwerf replied

    Hi Massimiliano mmazinga ,

    That could be almost anything...

    Can you please provide a link to your .blend file (after uploading it to Dropbox, Googledrive, or so)?

  • Massimiliano Grasso(mazinga) replied

    Thank you Martin,

    here is the file: https://www.dropbox.com/s/d2bjglqffybm2fh/32%20-%20monster-truck_model.21.blend.zip?dl=0


  • Adrian Bellworthy replied
    Solution

    The issue is in the naming, it usually is.
    The names used in the script need to match exactly to the names of the rig/bones.

    Check your spelling of Monster_Truck_RIG, I see an extra t, Montster in several places.
    Once you go through and check the spelling of each Monster in the outliner,
    right click the y rotation (purple) for each DEF-Wheel, select edit driver, check the expression is correct for each wheel, then click update dependencies.

    The wheel rotation should now work correctly.

    • Thanks Adrian!
  • Massimiliano Grasso(mazinga) replied

    Thank you very much

    you are right, I had made a lot of mistakes, the fault of my bad English.

    Now it works.

    • 👍
  • Wayne Dixon replied

    I'm glad you all got it working.

    Tu sei Englese non cativo ma il mio italiano e molte cativo!

    (I'm guessing you are Italian, and that you can read my bad grammar and spelling - I may be wrong on both of those things.)

    • 🤜🤛
    1 love
  • Adrian Bellworthy replied

    I would never have been able to help solve this problem without your courses Wayne!