- Home /
nstantiate the arrow at the bow's position with the bow's rotation, give it a velocity, when it hits something, disable its movement.
Hey There ! I am new in unity and want some help in this regard. Your help would be appreciated Thanks In advance
Answer by Tehnique · Jul 15, 2014 at 08:34 AM
That's a lot you ask for. I'll just give you some pointers, so you can write your own code:
For Instantiating with the same rotation:
Use Instantiate, and set the bow transform.rotation Quaternion as the "rotation" parameter when you call Instantiate.
For velocity:
Use AddForce on the arrow rigidbody. The direction should be the bow forward direction, or whatever your aim direction is (if it's not bow forward).
For movement disabeling, set arrow as kinematic on collision. For more info, check this question.
Good luck!
Your answer
![](https://koobas.hobune.stream/wayback/20220613154113im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Click to Shoot 1 Answer
Questions about a Bow and Arrow FPS setup 1 Answer
Need help moving player object towards an instantiated ball 1 Answer