Ok so I have rolling in my game. And I made it move relative to the camera.
Basically all I do is put a bodyvelocity in the character and set the direction to game.Workspace.CurrentCamera.CFrame.lookVector * Vector3.new(1,0,1)
I multiply it so that it does not include the Y value because obviously I dont want people rolling into the sky lol.
Anyways this causes an issue. If the camera is angled down or up the roll will be a lot slower since the lookvector is pointed away
local function getWalkDirectionWorldSpace()
local walkDir = camera.CFrame:VectorToWorldSpace( getWalkDirectionCameraSpace() )
walkDir *= Vector3.new(1, 1)
if walkDir.Magnitude > 0 then
walkDir = walkDir.Unit
end
return walkDir
end