Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Object not rotating to my character?

Making a flying object that follows me, but it's not rotating to my character?

script.Parent.MouseButton1Click:connect(function()	
print (script.Parent.Value.Value)
while true do
wait()
drone.MainPart.BodyPosition.Position = Vector3.new(script.Parent.Parent.FOLLOWME.Value.Value.X, script.Parent.Parent.FOLLOWME.Value.Value.Y, script.Parent.Parent.FOLLOWME.Value.Value.Z)
drone.MainPart.BodyAngularVelocity.AngularVelocity = Vector3.new(-script.Parent.Parent.FOLLOWME.Value2.Value.X, -script.Parent.Parent.FOLLOWME.Value2.Value.Y, -script.Parent.Parent.FOLLOWME.Value2.Value.Z)
base.BodyPosition.P = 8000
drone.MainPart.BodyPosition.Position = drone.MainPart.BodyPosition.Position + Vector3.new(-50,25,0)		
end
end)

1 answer

✓ Accepted answer

You need a BodyGyro to rotate an object. BodyPosition just makes it float towards the given vector.

5 comments

0

And how do I set it so it only uses X and Z

0

In the MaxForce property, set its y value to 0: bodyGyro.MaxForce = Vector3.new(x, 0, z)

0

Does not exist..

0

What do you mean "does not exist"?

0

It does exist. Check the properties list.

This discussion is preserved as it was. New answers, comments, and votes are closed.