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

Is there a way to stop SetPrimaryPartCFrame from moving the models position if obstructed?

Asked by 6 years ago

Okay so, what I'm asking is is SetPrimaryCFrame could not move the model as well as rotate it, if obstructed. I've tried moving the model using MoveTo to try and fix it but that didn't work.

        repeat
        door:SetPrimaryPartCFrame(CFrame.new(0, pcf, -90))
        door:MoveTo(Vector3.new(41.35, 5.8, 1.25))
        pcf = pcf-2.5
        print(door.Part1.Position)
        wait(0.1)
        until pcf == -10
0
Try using cframe instead of vector3 BerrySus 65 — 6y

Answer this question