CGTalk > Software > Autodesk Maya > Maya Dynamics
Login register
Thread Closed share thread « Previous Thread | Next Thread »  
Thread Tools Search this Thread Display Modes
Old 07-14-2008, 01:18 PM   #1
Benjamin Jürgens
CG Artist
NHB Düsseldorf
Dusseldorf, Germany
Join Date: Apr 2008
Posts: 34
Controll the random spin of particle Instaces?

Hey all,

I'm building a space scene right now. It's a POV flight through a asteroid field. I realized it over a Particle field, the instancer and a little PP Array Attribute.

Under Creation it's:
Asteroiden_GroßShape.RandomSpinPPBIG = rand(-1,1);

under runtime before dynamics it's:
float $spin = Asteroiden_GroßShape.RandomSpinPPBIG;
Asteroiden_GroßShape.BigAsteroidRotation += 0.6*$spin;

The asteroids are now spinning randomly in all 3 possible spinning directions. The result is a really strange rotation movement. It looks like a force is changing the rotation direction from time to time. In space as far as I know such a force doesn't exist, so i want to get rid of it.

I'm new to Maya Dynamics and don't really know how to get the asteroids spinning in one or two directions only.

Hope my english is good enough to make you understand what's my problem.

Old 07-14-2008, 06:42 PM   #2
The Red Scarlet One
CarlRiver's Avatar
Reinhold Rittinger
Join Date: Jul 2006
Posts: 130
the way I would go about this would be to create a creation expression that assigned a random spin-vector to each particle:

RandomSpinPPBig = sphrand(1);

The value in the brackets controls the speed of the rotation. Then as a runtime-before expression you could write something like this:

BigAsteroidRotation += RandomSpoinPPBig;

This should about do it and should work fine.

And a small tip: don't use non-standard characters like ß or ä,ö,ü in Maya.
Old 07-15-2008, 12:11 AM   #3
Benjamin Jürgens
CG Artist
NHB Düsseldorf
Dusseldorf, Germany
Join Date: Apr 2008
Posts: 34
Thank you!
I'll try it tomorrow.

greezt from Cologne
Old 07-15-2008, 12:11 AM   #4
CGTalk Moderation
CGTalk Forum Leader
Join Date: Sep 2003
Posts: 1,066,478
Thread automatically closed

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
Thread Closed share thread

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Society of Digital Artists

Powered by vBulletin
Copyright ©2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump

All times are GMT. The time now is 09:05 AM.

Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.