apoc519
03-21-2010, 11:33 AM
when an instance is set to velocity aim direction and changes direction quickly theres usually an ugly pop. I'd love to find a way to smooth that rotation transition. Like a maximum amount of rotation per frame or something
I've found this code which replicates the aim direction set to velocity when applied to regular rotation. Any ideas how to modify this to do what I want?
vector $velocity = particleShape1.velocity;
float $angBet[] = `angleBetween -euler -v1 1 0 0 -v2 ($velocity.x) ($velocity.y) ($velocity.z)`;
particleShape1.rotPP = << $angBet[0] , $angBet[1], $angBet[2] >> ;
I've found this code which replicates the aim direction set to velocity when applied to regular rotation. Any ideas how to modify this to do what I want?
vector $velocity = particleShape1.velocity;
float $angBet[] = `angleBetween -euler -v1 1 0 0 -v2 ($velocity.x) ($velocity.y) ($velocity.z)`;
particleShape1.rotPP = << $angBet[0] , $angBet[1], $angBet[2] >> ;
