I'm making a while loop that will move the part to the mouse always, so I can create a building system.
--Variables
local player = game.Players.LocalPlayer
local mouse = player:GetMouse()
local Part = game.Workspace.Farm:Clone()
Part.Parent = game.Workspace
--Move Part to Mouse Position Always
while true do
local x = mouse.X
local y = mouse.Y
Part.Position = Vector3.new(x,y)
--Places Part at Mouse Position.
mouse.Button1Down:connect(function(hit)
local X = mouse.hit.X
local Y = mouse.hit.Y
local Z = mouse.hit.Z
local Partt = Part:Clone()
Partt.Parent = game.Workspace
Partt.Anchored = true
Partt.Position = Vector3.new(X,Y,Z)
wait(5)
Partt:Destroy()
end)
wait()
end

1 comment
Mind showing code? c: It'll help us to further answer your question within the best of our abilities! :D