Allign Position And Allign Orientation Not working

Hey! So, I am trying to set up a pet follow script, I know there are many of them on the dev forum, and I have looked at all of them but I have not been able to fix my issue. So the issue im having is the script works perfectly for 15 seconds, Then out of no where it breaks as shown in the video below, The Dragon Pet, Just randomly stops following me and will instead be locked in place.

			local CurrentPet = PetFolder:WaitForChild("Dragon"):Clone()
			CurrentPet.Parent = workspace
			local Orien1 ="Attachment")
			Orien1.Parent = Character.HumanoidRootPart
			local Orien0 ="Attachment")
			Orien0.Parent = CurrentPet.HumanoidRootPart
			Orien0.Orientation =,90,0) 
			local attach1 ="Attachment")
			attach1.Parent = Character.HumanoidRootPart
			local attach0 ="Attachment")
			attach0.Parent = CurrentPet.HumanoidRootPart
			attach0.Position =,-3,-3)
			local allign ="AlignPosition")
			allign.MaxForce = 30000
			allign.Responsiveness = 40
			allign.Attachment0 = attach0
						allign.Attachment1 = attach1
			allign.Parent = CurrentPet.HumanoidRootPart
			local Ori ="AlignOrientation")
			Ori.Responsiveness = 40
			Ori.Attachment0 = Orien0
			Ori.Attachment1 = Orien1
			Ori.Parent = CurrentPet.HumanoidRootPart
1 Like

I made a following magic type thing, which uses “Body position” and CFrame, like this…

local follow ="BodyPosition",  part)
part.follow = part.Position +, 3, 0)
while true do
      part.CFrame =, Target.Position)

hope this helps!

I would use this, but Im really against the idea of having that many while true do loops in 1 game, It can cause a lot of lag, and Id rather find a solution to the actual problem but thank you!

you don’t need to it’s an example. I’m sure there’s a better way