Ive tried to create a lag test game for roblox but im struggling to destroy once its been created, ive tried everything but it still wont work
Heres the code:
local function SpawnParts()
wait()
local LagPart1 = Instance.new("Part")
LagPart1.BrickColor = BrickColor.new("Institutional white")
LagPart1.Material = ("ForceField")
LagPart1.Parent = game.Workspace
LagPart1.Position = Vector3.new(12, 61.5, 5)
LagPart1.Name = "LagParts"
LagPart1.Size = Vector3.new(6,6,6)
end
Reset.MouseButton1Up:Connect(function()
Reset1 = true
workspace:WaitForChild("LagPart1"):Destroy()
end)
