I’m trying to make it so if you get hit by a sword or any weapon it will knock the player back every time you hit someone two times with a weapon and I really don’t know how I’m suppose to do this can someone help me?
You could insert a BodyVelocity into the target's HumanoidRootPart for a short while, give it a force, and delete it later.
1 | local bv = Instance.new( "BodyVelocity" ,Target) |
2 | bv.MaxForce = Vector 3. new( 25000 , 25000 , 25000 ) |
3 | bv.Velocity = Character.HumanoidRootPart.CFrame.lookVector * 10 |
4 | game.Debris:AddItem(bv, 0.3 ) |
This is a simple Knockback script.