I could have sworn that I saw a page stating that this constructor is being deprecated but I can’t find it. Did they change their minds on making it deprecated?
Well that’s unfortunate. Is there a reason why this is deprecated? This is going to break a lot of games that rely on this constructor.
I’ve seen the alternative route, but honestly it looks like they just overcomplicated it.
It’s deprecated, not removed. It’s been deprecated a while, so it doesn’t seem like they have any immediate plans to remove it. I don’t know why they removed it, but I know a lot of people found it confusing and did stuff like CFrame.new(position, orientation)
with the two vector constructor instead of (origin, lookAt)
. It might’ve been related to that? Either way, the fromMatrix
approach is a mess and isn’t really a great solution to the problem.
That’s pretty strange. I’ve been taking a look at this post specifically and have been going over it too many times and I still can’t understand it just due to its complexity.
I just wish Roblox was a bit more transparent about this and provided a more stable and accurate solution if they’re legitimately considering on removing this. (Though like you said, it might not be for a while.)
They can’t remove it, because of how many games it will break. Honestly, I have no idea why it was deprecated in the first place, as it doesn’t really have a replacement. There are tons of deprecated things, like the “Mouse” object, that are still around just because older games (and newer games; I still see tutorials using Mouse instead of UserInputService) rely on them. If they do remove it, it will break my game and probably thousands of others too. So I wouldn’t be worried about using it and it breaking later on.
Just keep using lookAt. Plenty of things become deprecated and never end up getting replaced. CFrame is one of the oldest features on the site, probably used more than anything else if you look at the entire history of roblox.
I cannot even being to imagine they would be removing this, as like you said, it would break such a huge number of games. I would be willing to bet that you’ll be just fine to continue using it for the foreseeable future.