I've created a bow which shoots an arrow projectile, it uses the mouse.Hit.lookVector to provide where it starts and which direction it shoots towards, but I'd like to know how to rotate the arrow so it shoots straight according to the mouse.Hit.lookVector, instead of shooting out at an angle.
✓ ANSWER ACCEPTED
Rotate Projectile to Shoot Straight?
1 answer
✓ Accepted answer
You should be able to do that by using the 2. CFrame argument.
local direction = mouse.Hit.lookVector
-- First vector is the position, and 2. vector is the position CFrame should face
arrow.CFrame = CFrame.new( startPos, startPos + direction )
This discussion is preserved as it was. New answers, comments, and votes are closed.
