Knockback script for my combat system only works for dummies for some reason. When tested with dummies, it works perfectly fine. However when tested with real players, it does not move the player or it moves targets in a weird way that is not in connection with the player hitting the target. Does this have something to do with network ownership? I tried setting the network ownership to the player, and it worked as well as it did with the dummy, so it most definitely has something to do with network ownership. How would I remove network ownership from the solution? From my understanding, network ownership makes everything much more complicated + gives security issues + adds more bugs.
local VF = Instance.new("VectorForce", hithumanoid.Parent.HumanoidRootPart)
VF.Name = "Knockback"
VF.Attachment0 = hithumanoid.Parent.HumanoidRootPart.RootAttachment
VF.Attachment1 = Character.HumanoidRootPart.RootAttachment
VF.ApplyAtCenterOfMass = true
VF.Force = Vector3.new(0, 0, -20 * hithumanoid.Parent.HumanoidRootPart:GetMass() * workspace.Gravity)
VF.RelativeTo = Enum.ActuatorRelativeTo.Attachment1
Debris:AddItem(VF, 0.1)