local parent = script.Parent parent.Touched:Connect(function(touchedpart) local player = touchedpart.Parent local playerservice = game:GetService("Players") local playergui = playerservice:FindFirstChild(player.Name).PlayerGui local Property = playergui.SHOP.Frame wait(0.5) Property:TweenSizeAndPosition(UDim2.new(0.052, 0,0.081, 0), UDim2.new(0,0,0,0) ) wait(0.2) game.ReplicatedStorage.coin:Play() end)
You haven't moved back the frame after the animation so it keeps tweening it without you actually seeing it. At least that's my guess. Correct me if I'm wrong.
local parent = script.Parent parent.Touched:Connect(function(touchedpart) local player = touchedpart.Parent local playerservice = game:GetService("Players") local playergui = playerservice:FindFirstChild(player.Name).PlayerGui local Property = playergui.SHOP.Frame wait(0.5) if Property.Position == UDim2.new(0.052, 0,0.081, 0) Property:TweenSizeAndPosition(PleaseChangeThisAndPutWhateverYouWant) end Property:TweenSizeAndPosition(UDim2.new(0.052, 0,0.081, 0), UDim2.new(0,0,0,0)) wait(0.2) game.ReplicatedStorage.coin:Play() end)