I’m trying to create a knock back system in a tool atm using BodyPosition, as I find bodyvelocity to be very inconsistent. Could someone help me understand what kind of equation I would use to send the player hit (for example) 10 studs back from the caster? Here’s the code I have now
KickRay.OnHit:Connect(function(hit, humanoid)
local enemyRoot = hit.Parent:FindFirstChild("HumanoidRootPart")
local casterRoot = character:FindFirstChild("HumanoidRootPart")
local BodyPos = Instance.new("BodyPosition")
BodyPos.MaxForce = Vector3.new(999999,999999,999999)
BodyPos.Position = Vector3.new(enemyRoot.Position) + Vector3.new(0,0,10)
BodyPos.Parent = enemyRoot
debris:AddItem(BodyPos, 1)