http://jerome.le.chat.free.fr

Home > Blender > Scripts > wheel rotation - Documentation

wheel rotation - Documentation

Article Index
wheel rotation
Installation
Quick setup
Documentation
Configuration examples

when it reaches frame 1, the script initializes itself everytime. go there everytime you change an object name, edit a script value, add a new wheel etc..
when debug is enabled, the console displays something similar to the following message :

.wheel rotation script v0.5 - init

  auto-select :
  -------------
  found wheel_FT.R
  found wheel_FTDK.L
  found wheel_BK.R
  found wheel_BK.L
  found plane

  wheel list :
  ------------
   wheel_FT.R : diameter auto,steering True, OutOfTrue 0
   wheel_FTDK.L : diameter auto,steering True, OutOfTrue 10
   wheel_BK.R : diameter auto,steering False, OutOfTrue 0
   wheel_BK.L : diameter auto,steering False, OutOfTrue 0
   plane : follow mode

in the present case it means that 5 objects has been selected as wheels.
except for the plane object, the objects will spin, and their diameters will be retrieved automatically, and evaluated at each frame ('diameter auto').

'steering True' means that the objects will turn 'left' or 'right'. False means that the steering is inherited or done apart from the script. (follow path, a parent car object that already turn..).
you can notice that the objects with a FT keyword have steering equals toTrue.

'OutOfTrue' is equal to zero excepted for the second object : it means that the second wheel will be put out of true (10 degrees).
you can notice that the objects has a DK keyword.

'plane follow mode'means the object won't spin, but will follow the path of the trajectory like this :

Dim lights Download Embed Embed this video on your site

to change the behaviour of the script, you can edit the script in the text editor in the 'USER CONFIGURATION' section.

the most important variables are :

  • wheelNames (list. default : ['wheel'] )
    family of names (first characters) of the 'wheel' object.
  • wheelList (list. default : [] )
    exact names of the 'wheel' object.

for each list, the object description is :

[ wheel_name/family_name_1, Diameter, Steering, OutOfTrueAngle ]
  • wheel_name/family_name (string)
    an exact name (wheelList) or the first characters of the wheel objects (wheelNames)
  • Diameter ( float / 'auto' / 'follow' - default 'auto' - optional )
    object diameter in Blender Unit. in most of the case equals to dimZ x scaleZ.
    'auto' : the script evaluates the diameter object at every frame. (snow ball)
    'follow' : the object does not spin and follows the path of the trajectory. if 'follow', there's no need to use the following arguments.
  • Steering ( boolean - default False - optional )
    True : the wheel steers.
    False : it doesn't (rear wheels of a car)
  • OutOfTrueAngle ( float - default 0 - optional )
    degrees value to put the wheel out of true.

the following values can influence the wheel objects whom optional arguments are missing :

  • RotateZ ( string - default 'FT' )
    if this keyword is in the object name, and if there's no steering argument for this object, it will be a steering wheel.
    won't apply to object with a path constraint.
  • OutOfTrue ( string - default 'DK' )
    if this keyword is in the object name, and if there's no OuOfTrue argument for this object, it will be an out of true.
  • ootAngle ( float - default 10.0 )
    out of true value in degrees.

the following values can influence any 'wheel' object :

  • angle ( float - default 130.0 )
    for a steering wheel, from on frame to the next one, the orentation offset is greater than this value, the wheel won't step but will go backwards.
  • initFrame (int - default 1 )
    initialization frame : the script (re)generates the wheel lists and the other parameters.
  • debug ( boolean - défaut True )
    display initialization  info in the console. False for nothing.
  • verbose ( boolean - default False )
    noisy BLender Console for debug and curious. info about 'steering' wheels. 6 lines per wheel..

steering wheels parenting :

the script runs smoothly when the wheels are parented to another object (CTRL-P) but not for steering wheels :
you have to parent them thanks to a copy location constraint.
if at frame init + 1, the wheel begins to spin in the opposite way, turn it in the direction of the trajectory of the animation to help the script.



Last Updated on Friday, 09 October 2009 02:42  
Comments (1)
promo
1 Sunday, 17 November 2013 06:00
bosantos
There are no translations available.

hai Visit My Blog http://blenderengine3d.blogspot.com/