| |
|
|
| 22 Apr 2015 10:33 PM |
CFrame - CFrame.p
CFrame:toEulerAnglesXYZ()
|
|
|
| Report Abuse |
|
|
| |
|
NotAshley
|
  |
| Joined: 16 Jan 2014 |
| Total Posts: 14257 |
|
|
| 22 Apr 2015 11:38 PM |
toEulerAnglesXYZ()
^ This is not accurate and is bound to cause mistakes if you're trying to copy one rotation to another. |
|
|
| Report Abuse |
|
|
|
| 22 Apr 2015 11:43 PM |
| It sure isn't which is why I never use it. I just listed it because he didn't specify how he wanted them. |
|
|
| Report Abuse |
|
|
|
| 22 Apr 2015 11:51 PM |
| Well, the CLerp function I'm using uses toEulerAnglesXYZ. Should I change it? |
|
|
| Report Abuse |
|
|
|
| 22 Apr 2015 11:55 PM |
| You could use the module uploaded by stravant if you want. And if the 'CLerp' function interpolates the angles using :toEulerAnglesXYZ(), I definitely recommend you change it (I once used to do it before I realized you can't interpolate angles that way). |
|
|
| Report Abuse |
|
|
|
| 22 Apr 2015 11:59 PM |
I just tried to change it, and it ended up not working with angles at all
I guess I don't have a choice right now because I've already made so many animations off of the function anyways |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 23 Apr 2015 12:36 AM |
| for CLERP why not use the actual CFrame components? |
|
|
| Report Abuse |
|
|
anaIyze
|
  |
| Joined: 29 May 2014 |
| Total Posts: 2048 |
|
|
| 23 Apr 2015 01:31 PM |
| @cnt stop, they are inexperienced |
|
|
| Report Abuse |
|
|
|
| 23 Apr 2015 03:04 PM |
| You don't interpolate the components either. |
|
|
| Report Abuse |
|
|
MrNicNac
|
  |
| Joined: 29 Aug 2008 |
| Total Posts: 26567 |
|
|
| 23 Apr 2015 03:14 PM |
"for CLERP why not use the actual CFrame components?"
What....
"You don't interpolate the components either."
Bingo.
You have to change the matrix into a more suitable form. Such as axis angles, quaternion rep, or the "Translate, scale, and skew" format. |
|
|
| Report Abuse |
|
|
NotAshley
|
  |
| Joined: 16 Jan 2014 |
| Total Posts: 14257 |
|
|
| 23 Apr 2015 03:25 PM |
| Spherical interpolation is your friend. |
|
|
| Report Abuse |
|
|
rayk999
|
  |
| Joined: 18 Feb 2011 |
| Total Posts: 4705 |
|
| |
|
MrNicNac
|
  |
| Joined: 29 Aug 2008 |
| Total Posts: 26567 |
|
|
| 23 Apr 2015 03:29 PM |
"Quaternions ftw"
Um no. I feel like people only say that because that's what the majority of everyone else finds when they Google that.
Axis-angles are far superior. |
|
|
| Report Abuse |
|
|
rayk999
|
  |
| Joined: 18 Feb 2011 |
| Total Posts: 4705 |
|
|
| 23 Apr 2015 03:30 PM |
I've never really worked with axis angles tho Quaternions ftw for people who are as advanced as me in math |
|
|
| Report Abuse |
|
|
cntkillme
|
  |
| Joined: 07 Apr 2008 |
| Total Posts: 44956 |
|
|
| 23 Apr 2015 03:36 PM |
| I didn't mean the components from cframe:components() -_- |
|
|
| Report Abuse |
|
|
MrNicNac
|
  |
| Joined: 29 Aug 2008 |
| Total Posts: 26567 |
|
|
| 23 Apr 2015 03:55 PM |
"Quaternions ftw for people who are as advanced as me in math"
Advanced as you? What is the logarithmic difference between an axis angle and a quaternion? |
|
|
| Report Abuse |
|
|
|
| 23 Apr 2015 04:25 PM |
Could someone give me a CLerp function that would work with the arguments:
CLerp(mainC0, modifiedVarC0, speed) |
|
|
| Report Abuse |
|
|
NotAshley
|
  |
| Joined: 16 Jan 2014 |
| Total Posts: 14257 |
|
|
| 23 Apr 2015 04:27 PM |
"CLerp(mainC0, modifiedVarC0, speed)"
You're looking for a tweening function, not clerp. Lerp (linear interpolation) is usually to simply get a new CFrame between two CFrames, which you can use with loops to animate. |
|
|
| Report Abuse |
|
|
NotAshley
|
  |
| Joined: 16 Jan 2014 |
| Total Posts: 14257 |
|
|
| 23 Apr 2015 04:28 PM |
If you're animating welds, this could help:
http://www.roblox.com/Weld-Tweening-Function-w-Cosine-Interpolation-item?id=219384784 |
|
|
| Report Abuse |
|
|