@britton_21
Roblox Oct 15, 2026

Making a fly ability for players in my own roblox game

Want players to toggle flying with a key in my sandbox game. I tried BodyVelocity but the character flips over. Is LinearVelocity the way to do it now, or is there a better approach?
1

Leave A Reply

Log in to post an answer.

1 Answer

eliza_50 Oct 21, 2026
britton_21
BodyVelocity still works but it's deprecated, so use LinearVelocity plus an AlignOrientation on the HumanoidRootPart. Rough shape: a LocalScript listens with UserInputService for your toggle key, and while flying is on you set the velocity from the camera's look direction times your speed every RenderStepped. Put the humanoid in PlatformStand so gravity and the walk animation stop fighting it. One catch. The player owns their own character physics, so client-side movement does replicate fine, but if you have any server-side speed check for exploiters it will flag your own fliers. Exempt players while the ability is active.