Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: Caffeen on January 05, 2014, 03:04:06 PM
-
Hi, I'm pretty new to Playmaker, and I've been trying to redo a project using Playmaker. I have an object that the player can rotate left and right, and I want a second object to slowly rotate to match the rotation of the first object. I used Quaternion.RotateTowards in my old script, and that worked perfectly, but I can't for the life of me figure out how to create the same behavior in Playmaker.
Thanks!
-
Hi,
you'll need the quaternion package from the wiki:
https://hutonggames.fogbugz.com/default.asp?W967
Essentially you can use QuaternionSlerp to achieve the same as Quaternion.RotateTowards. however if it's still this very function you need, let me know, I'll add it to the package.
bye,
Jean
-
Oooh, great, thanks!! I didn't even know that existed. But actually, yeah, Slerp was the first thing I had tried prior to Playmaker, and it didn't give me the desired effect. (Takes way longer than intended, and the rotation angles never actually match up, which is essential.) So Quaternion.RotateTowards being added would actually be ideal.
Thank you for your response!
-
Hi,
ok, I have added that RotateTowards action, please redownload the package from the wiki:
https://hutonggames.fogbugz.com/default.asp?W967
bye,
Jean