Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- game:GetService("RunService").RenderStepped:Connect(function()
- local part, intersectionPoint, surfaceNormal = workspace:FindPartOnRayWithIgnoreList(
- Ray.new(character.HumanoidRootPart.Position, character.Humanoid.MoveDirection * 50),
- { character }
- )
- local upVector = surfaceNormal:Cross(character.HumanoidRootPart.CFrame.rightVector)
- local upVector2 = surfaceNormal:Cross(upVector)
- bodyForce.Force = hrp.CFrame:vectorToWorldSpace(surfaceNormal) * 9.81 * characterMass
- --bodyGyro.CFrame = CFrame.new(Vector3.new(), part.CFrame.lookVector)
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement