Rocket Model Spawning Sideways

Hello. I am currently developing a fun explosion game which features RPG’s, C4’s, and grenades. The slight problem I am having with the RPG is that the rocket itself is moving sideways and not facing the direction it’s moving. Is there anyways I can fix this?

The rocket is using bodyvelocity to propell itself and just changes it’s cframe right when it’s fired. A small clip of the code can be found below.

Video Here

             RocketModel["SmokePart"]["Position"] = Tool["Rocket"]["M"]["Position"]
                
             local BV = Instance.new("BodyVelocity", RocketModel["SmokePart"])
             BV["Velocity"] = (MouseHit["Position"] - Tool["Handle"]["Position"])["Unit"] * 200
             BV["MaxForce"] = Vector3.new(40000000, 40000000, 40000000)
part.CFrame = CFrame.new(part.Position, LookAtPosition)

You can set the CFrame of the rocket when you clone it first like this. Change the LookAtPosition to the position it is moving towards

EDIT: You can also use this

part.CFrame = CFrame.lookAt(part.Position, LookAtPosition)
1 Like

If WoTrox’s solution still spawns the rocket sideways, you can amend it as follows:

partA.CFrame = CFrame.new(partA.Position, LookAtPosition) * CFrame.Angles(0,0,0)

math.rad(90) will convert degrees into radians.

1 Like

You can either rebuild the rocket model 90 degrees clockwise, or use a script to change the rotation of the rocket. I would just prefer rebuilding the rocket though, saves a lot more time if that solves it.