Recently I've been working on a combat system, I've gotten everything to work except for the knockback. I've been trying to look for a good way to implement knockback but I can't find any good tutorial online. I've heard that BodyVelocity works, but it doesn't fit the style of what my game will be like. Does anybody have tips for implementing knockback?
✓ ANSWER ACCEPTED
Tips for knockback in a fighting game?
1 answer
✓ Accepted answer
local Speed = 40
local Force = 80000
local TotalForce = Force
local KnockBack = Instance.new("BodyVelocity")
KnockBack.Parent = part.Parent:FindFirstChild("HumanoidRootPart")--part is the target of the knockback/ the opponent
KnockBack.MaxForce = Vector3.new(TotalForce,TotalForce,TotalForce)
KnockBack.Velocity = Character:FindFirstChild("HumanoidRootPart").CFrame.LookVector * Speed -- based on the direction YOUR character is facing.
Idk if this works for you, but you should try it.
This discussion is preserved as it was. New answers, comments, and votes are closed.
