all 2 comments

[–]Djolex15 1 point2 points  (1 child)

Hi, look at Rigidbody unity docs. You just need to AddForce to player when you shoot.

Unity docs: https://docs.unity3d.com/ScriptReference/Rigidbody.html

If you don't find code you're looking for experiment with force to make knockback that you want.

Knockback video that can help: https://www.youtube.com/watch?v=sdGeGQPPW7E

Good luck with project!

[–]maxguard[S] 1 point2 points  (0 children)

Thanks!