What I recommend is using the TweenService, but if you do it like this then you must. Here is your issue, what I believe is happening is that this part is anchored and you are changing its position with CFrame, so the parts aren't actually touching, because it isn't really moving you are just changing its position.
Go do some research into TweenService and the movement of parts using it, I will drop a link below.
TweenService
I do have an example (from the DevForum) of precisely what you are looking for:
local TweenService = game:GetService("TweenService")
local part = Instance.new("Part")
part.Position = Vector3.new(0, 10, 0)
part.Color = Color3.new(1, 0, 0)
part.Anchored = true
part.Parent = game.Workspace
local goal = {}
goal.Position = Vector3.new(10, 10, 0)
goal.Color = Color3.new(0, 1, 0)
local tweenInfo = TweenInfo.new(5)
local tween = TweenService:Create(part, tweenInfo, goal)
tween:Play()
In the script above what is happening is you are referencing the service, and then creating a part and goal. The goal will be the ending position and color of the part, and then the TweenInfo is the length of the travel of the part. You create the local variable and then :Play() the tween.
Hope this helped, if it did please accept my answer, other than that, have a great day and happy coding!
2 comments
Why are you combining Part.CFrame and Vector3.new()? Just do part.CFrame * CFrame.new(0,0,-1)
Because I learned it so. Im rlly new. I've been scripting for 3 days right now. And this doesn't fix my problem