local p = script.Parent local db = false p.Touched:Connect(function(h) if h.Parent:FindFirstChild("Humanoid") then local char = h.Parent local plr = game.Players:GetPlayerFromCharacter(char) if plr.leaderstats.Recourse.Value >= 10 then if db == false then db = true plr.leaderstats.Recourse.Value -= 10 print("worked") local ab = {script.Parent.Parent.Parent.AvailableSpots:GetChildren()} for i, v in pairs(ab) do if v.Occupied == false then print("occupied is false") local clone = game.ReplicatedStorage.GrassDum:Clone() print("it cloned") clone.Parent = workspace print("workspaceparent") clone:MoveTo(v.Position) print("it shud work since it moved to pos") end wait(2) db = false end end end end end)
I believe that :MoveTo() is deprecated. I’ve used it before and its always given me problems. Try just setting the cords instead.
If MoveTo() isn't working, try the newly added feature PivotTo()
PivotTo() works the same as SetPrimaryPartCFrame except you don't need a primarypart.
clone:PivotTo(v.Position)