Maya instancer particles wobble instead of rotate/spin


#1

Hey guys. I’ve searched the net and I can’t seem to find the answer anywhere… Ive been using all the standard rotPP code

most of my particles rotate, but some of my particles “wobble” almost as if they are gimbal locked or something. Here’s my code:

Creation:
nparticle1.RotPP = <<rand(360),rand(360),rand(360)>>;
//ive also tried “= rand(360);”

runtime before dynamics:
nparticle1.RotPP += <<3,3,3>>;
//ive also tried “+= 3;”

is there maybe a rotation order on the instancer node that helps with this? thanks!


#2

The problem is you are adding rotations every frame in all axis. You need to pick a direction like so.

Creation: nparticle1.RotPP = <<rand(360),rand(360),rand(360)>>;
Runtime: nparticle1.RotPP += <<0,3,0>>;

If you want to randomly pick an axis to rotate around you would need to assign a variable that gives each particle a random number between 0 and 2 and write in your runtime expression an if statement that will assign a different axis of rotation based off that attribute.

Example Rotations


#3

Thanks man!! that’s a great idea. Thanks for the file :thumbsup:


#4

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.