Hello, I am having trouble getting this script to work
So, the ball is being affected by body veloicty, and I want it to slow down atleast when you kick it. It doesn’t slow down at all in fact it just keeps moving until the end of the map
How do I stop this ball from moving so much, even when not affected by force
script:
local cooldown = false
script.Parent.Touched:Connect(function(Hit)
if Hit.Parent:FindFirstChildWhichIsA('Humanoid') then
if not cooldown then
cooldown = false
end
local hrp = Hit.Parent:FindFirstChild('HumanoidRootPart')
local ball = script.Parent
local force = Instance.new('BodyVelocity')
force.MaxForce = Vector3.new(9000000000000, 9090000000000, 90000000000)
force.Velocity = hrp.CFrame.LookVector * 30
force.Parent = ball
game.Debris:AddItem(force,0.6)
end
wait(1)
cooldown = false
end)