Beam Attachment1 flying all over the place

Henlo fens, have a script that makes this beam whenever i shoot gun to act as tracer, all is fine. However, attachment1 seems to have attachment issues with the holy spirit and flies to the sky sometimes. For example:

My code simply puts attachment1 at (0,0,-100)

			attachment1.Position = Vector3.new(0, 0, -100)

i hope some of you may help. thanke.

(EDIT: It seems to only happen when i am aiming at an object)

Nevermind. I was setting the attachment1.WorldPosition to (0, 0, -100) when there was a object intersecting with the raycast. I feel ashamed of myself now

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.