How to align a part with just a script?

Hello again devforum!

I am back once again, to get help with a problem that I would love to be solved as it has stumped me in many games that require a flip mechanic.

so this game requires it to be perfect, but i do not want to use AlignOrientation because I am not completely sure how cframes work and how to turn orientation into lookat and stuff like that. If anyone could help with that, it would be greatly appreciated.

Anyway, my problem is me, well trying not to use it. I am using AssemblyAngularVelocity to rotate a part with this script:

part.AssemblyAngularVelocity = (, part.Rotation.Y - root.Orientation.Y, -part.Rotation.Z)/16)

part is the part I want to rotate, root is the player’s HumanoidRootPart which the part will align its Y axis with. I’ve looked all over but it seems nobody has tried this approach. I should mention the script is in a loop for 50 ticks and then stops the velocities of the part after.

If anyone has a solution for either AlignOrientation or my script above, please respond ASAP :slight_smile:

1 Like

I have this example of how to use AlignOrientation for this: AlignOrientation Example - Roblox

1 Like

thank you, this makes a lot more sense. :slight_smile: