Cuneyt Ozdas Forum
Cuneyt Ozdas Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 English - General
 Software Support
 variations on rolling ball script
 Forum Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

MalikDrako
Starting Member

1 Posts

Posted - 02/04/2006 :  23:37:06  Show Profile
I am trying to create an object with two half spheres, each connected to a central object, but not attached (separate objects)
I need them to rotate like the wheels on a car, never tipping over as the center object moves
with the current script, they tip over as the center object turns
see http://malikdrako.zeeblo.com/rolling.avi

Admin
Forum Admin

Turkey
649 Posts

Posted - 11/04/2006 :  00:45:33  Show Profile  Visit Admin's Homepage
Hi,

Wheels are different from a free rolling ball so that in wheel case the rotation axis is fixed and known. Therefore no axis or quaternion calculation is needed. You should probably assign Euler rotation controller to the wheel, assign a script (or even expression) controller to the proper axis (X, Y or Z depending on your model) and in the controller calculate and return 360*len/(r*pi) . This is similar to the angle calculation in the rolling ball tutorial.

Rotating wheel problem is a simpler case therefore there may even be simpler solutions which can be achieved by standard max tools without any coding and such. I'm not doing animations anymore (it has been lots of years) herefore can't think of a simple way at the moment but I sense that this can ben done with little or no code at all.

/Cuneyt
Go to Top of Page

horsepower
Starting Member

3 Posts

Posted - 05/05/2006 :  20:44:32  Show Profile  Visit horsepower's Homepage
Cuneyt, can you help me step by step, to put the script into Max interface?
I have create a cylinder, animate its X position from frame 0 to 100: at frame 0 it are 0m in X and at frame 100 it are 10m in X.
The radius of cylinder are 0,3m.
I have put in Float Script Controller (Y axis):
360*10/(0.3*3.14)
where 10 are the meters in X followed by cylinder, and 0.3 are the radius of cylinder; 3.14 are pi.

Your script are:
360*len/(r*pi)

len: are lenght followed by cylinder?
r: are the radius of cylinder?
The script works automatically? Or I should set the keyframes at the start and at the end of my animation (rotation)? I think not, because the Y Rotation are "Float Script Controller"! True?
Please help me!

Horsepower.
Go to Top of Page

horsepower
Starting Member

3 Posts

Posted - 26/05/2006 :  18:25:12  Show Profile  Visit horsepower's Homepage
Hey Cuneyt! Can you help me?
Go to Top of Page
  Previous Topic Topic Next Topic  
 Forum Locked
 Printer Friendly
Jump To:
Cuneyt Ozdas Forum © 2000 - 2003 Cuneyt Ozdas Go To Top Of Page
This page was generated in 0.06 seconds. Snitz Forums 2000