Problem with CFrame and BodyPosition

So I am trying to move a part forward and up, basically a leap, using bodyposition. After doing such, the part returns to its original cframe before the leap. Here is my code:

local currentcf = model.PrimaryPart.CFrame
model.PrimaryPart.BodyPosition.Position = currentcf:ToWorldSpace(CFrame.new(0,2,-2)).Position
model.PrimaryPart.BodyGyro.CFrame = currentcf*CFrame.Angles(math.rad(-10),0,0)
wait(.75)
model.PrimaryPart.BodyPosition.Position = currentcf.Position
model.PrimaryPart.BodyGyro.CFrame = currentcf

The code works fine, however if repeated it starts getting imprecise, and the part’s Y vector in the position starts diminishing more and more. Is this imprecision related to BodyPosition, BodyGyro, or ToWorldSpace?

1 Like