Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

My character flings when it hits a wall how can i fix it?

Asked by 3 years ago
Edited 3 years ago

I've made a rolling script with creates a bodyvelocity in the humanoidrootpart but when u roll against a wall or an object it flings u and ive tried to fix it somehow but i couldnt figure out how can somebody help me out? If u know how to fix it pls explain me how if u wonder this is the part that creates the bodyvelocity

local LookVector = HumanoidRootPart.CFrame.LookVector           
local BodyVelocity = Instance.new("BodyVelocity")

BodyVelocity.MaxForce = Vector3.new(math.huge, math.huge, math.huge)
BodyVelocity.Velocity = LookVector * 60
BodyVelocity.Parent = HumanoidRootPart
wait(0.2)
BodyVelocity:Destroy()

its in a script ^

Answer this question