I have this button that is supposed to resize and reposition a part. But a problem I have a lot is that vector3.new and tweening can't have a part in a position if there is other parts in the way.
Not Anchored - Not wrong position sat - Checked many times
Script:
click = script.Parent.ClickDetector local Giver = script.Parent.Parent.Parent.Giver local av = false function wat(player) if av == true then av = false Giver.Position = Vector3.new(9.774, 0.825, -6.403) Giver.Size = Vector3.new(1.57, 0.25, 4.11) Giver.Transparency = 0.2 script.Parent.BrickColor = BrickColor.new('Really red') script.Parent.Parent.Main.SurfaceGui.Frame.TextLabel.Text = "AUTO COLLECTER OFF" elseif av == false then av = true Giver.Position = Vector3.new(6.18, 0.722, -38.968) Giver.Size = Vector3.new(191.59, 0.05, 159.38) Giver.Transparency = 1 script.Parent.BrickColor = BrickColor.new('Lime green') script.Parent.Parent.Main.SurfaceGui.Frame.TextLabel.Text = "AUTO COLLECTER ON" end end click.MouseClick:connect(wat)
use CFrame to have a part be able to be in a certain position without physics getting in the way also I would reccomend making the part anchored if you want it to be inside a different part otherwise the physiscs will influence it. good luck