Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why is this model not translating?

Asked by 9 years ago

So I have:

local modelCFrame = model:GetModelCFrame();
print(modelCFrame);
model:TranslateBy(Vector3.new(modelinfo[3]-modelCFrame.p));
print(model:GetModelCFrame());

which moves the model to modelinfo[3] (Vector3.new(0.07, 0.61, -22.29)) however I did prints around them and they both return the position as 0,0,0? Why is this not moving the model?

1 answer

Log in to vote
-2
Answered by 9 years ago

If you just want to move the whole model just do

local Model = Workspace.Model

Model:MoveTo(Vector3.new(0.07, 0.61, -22.29))
Ad

Answer this question