i'm using debris to destroy a part but whenever i do and try to respawn the part back into workspace it gives me this error:
17:42:40.291 - The Parent property of Lightning is locked, current parent: NULL, new parent Workspace
i'm not sure if destroy is a better option in this case or i'll do the same thing, i'm just wondering how i can unlock the parent
script:
UIS.InputBegan:Connect(function(input)
if input.KeyCode == Enum.KeyCode.E then
if debounce == true then
debounce = false
clone.Parent = game.Workspace
local mousePos = mouse.Hit.p
clone.Position = mousePos
debris:AddItem(game.Workspace.Lightning, 3)
debounce = true
end
end
end)

2 comments
unlock a parent when destroyedKinda the point of destroying an object.He wants to create a copy of a part before destroying it and paste wherever his mouse is pointing at on E key press tip mouse movement works at each render frame