I have this simple script:
local bob = workspace.Bobby
while task.wait() do
print(bob:GetPivot())
end
It supposed to be different every iteration but it’s the same.
Bobby is a moving NPC so it couldn’t be the script.
I have this simple script:
local bob = workspace.Bobby
while task.wait() do
print(bob:GetPivot())
end
It supposed to be different every iteration but it’s the same.
Bobby is a moving NPC so it couldn’t be the script.
if its moving :getpivot should return diffrent values, unless the loop is running so fast and timing out or theres just an issue with :getpivot.
Id try it with a wait() first to make sure its not the loop, and id also add in 2 more prints print(bob.position) and print(bob.cframe)
GetPivot
does not return the NPC’s position, it returns where the model rotates from (PVInstance
). See this for additional details:
Instead, try bob.PrimaryPart.Position
or bob.PrimaryPart.CFrame
.
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.