I’m currently making some parkour mechanics and stumbled upon this problem with ledge mechanics
What I want to do is make the player able to move while grabbing on a ledge, the grabbing works fine, but the moving has some problem, the player started to rotate the wrong direction (it’s moving in the correct way)
You can have a look at the issue here: https://gyazo.com/ff5aed095c2a645fd28e807752aaf2de
Here’s the code that I use to make the player move while hanging (Currently I have only made the player moves to the left using the A key)
local rayLeft = Ray.new(hrp.CFrame.p, hrp.CFrame.lookVector * 3)
local part, pos, normal = workspace:FindPartOnRay(rayLeft, Character)
local cross = Vector3.new(0, 1, 0):Cross(normal)
if uis:IsKeyDown(Enum.KeyCode.A) then
if not holding then return end
hrp.Anchored = false
local Vel = hrp.Vel
local Gyro = hrp.Gyro
Gyro.MaxTorque = Vector3.new(1 ,1 ,1) * math.huge
Vel.MaxForce = Vector3.new(1, 1, 1) * math.huge
Vel.Velocity = cross * -10
end
