How do i fix my rocket facing in wrong way?

im making an AT4 rocket launcher but somehow the rocket is facing in wrong way after launching

also i tried to rotate it back but it still wont work

1 Like

Can you please add the code you used?

1 Like
local rocket = game.ReplicatedStorage:FindFirstChild(ATGM4):Clone()
rocket.Parent = workspace
rocket.CFrame = CFrame.new(handle.Position, aim.Position)
rocket.CanCollide = false
rocket.Velocity = rocket.CFrame.LookVector * rocketSpeed

this is where the problem occurred

local rocket = game.ReplicatedStorage:FindFirstChild("ATGM4"):Clone()
rocket.Parent = workspace
rocket.CFrame = CFrame.new(handle.Position, aim.Position) * CFrame.Angles(0, math.pi, 0)
rocket.CanCollide = false
rocket.Velocity = rocket.CFrame.LookVector * rocketSpeed

try this

now it flying to random direction

Can you give the .rbxm file of the rocket launcher so I can directly test it and send the correct code

One thing that I found that I had to do was add an attachment to the rocket and use AlignOrientation to force it to align to the direction of flight.

The mesh seems rotated incorrectly when imported what you could do instead is create a main part that the rocket is connected to or an attachment with the correct orientation. Then base all your math on that attachment like direction and orientation.

thx man, ur idea worked well

1 Like

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