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

Parts - Anchor only one axis?

Asked by 6 years ago

How would you go about anchoring one or two axes? I know how to anchor all of them but is there a way (Without a script checking) to keep an objects z and y axes the same but let the x move? I'm trying to reduce memory/processing power usage.

Thanks, If not I'll just use a script:


local origZ = script.Parent.Position.Z local origY = script.Parent.Position.Y script.Parent.Touched:Connect(function(touchedBy) script.Parent.Z = origZ script.Parent.Y = origY end)

Answer this question