I'm getting this annoying error, I can't seem to work out where I have gone wrong - perhaps someone could point me in the right direction? (There is more functions, etc to this script but the error doesn't come from any other function calls).
Screenshots: http://prntscr.com/med2mi - Note that this is a LocalScript within a Tool in StarterPack. http://prntscr.com/med35d - Error in the output I keep receiving. http://prntscr.com/med4aq - Line 58 itself. >:O
Note: I've tried doing this: http://prntscr.com/med5l1 - But then it seems to throw this error: http://prntscr.com/med635 (Seems to appear when the .Equipped and .Unequipped events fire)
local function InstantWeld()
CurrentWelds = {} -- Empty the table
GetObjects(Handle)
coroutine.resume(coroutine.create(function()
wait(0.1)
for Parts = 1, Handle:GetChildren() do -- Line 58
local v1 = Parts
local v2 = 1, #v1 do
if v1[v2]:IsA("Weld") then
local Break = false
for v3 = 1, #CurrentWelds do
if v1[v2] == CurrentWelds[v3] then
Break = true
end
end
if not Break then
v1[v2]:Destroy()
end
end
end
end
end))
end
Tool.Equipped:connect(function()
InstantWeld()
end)
Tool.Unequipped:connect(function()
InstantWeld()
end)
InstantWeld()
Thank you for your time, warm regards, Ryoshote.

10 comments
So which line is 58?
yea, don't paste a 33 line script when you have an error on a line after 33
@PrismaticScripts I've put screenshot of Line 58 at the top, before putting the script.
Are you trying to make it so if the player tries to unequip the tool, it will be re-welded to the player?
@theking48989987 What does that have to do with anything? It is only a snippet, it isn't the full script itself. But it is a snippet of where I believe the error is occurring.
@SerpentineKing Not really, no - I know it looks silly on the inside. But it works perfectly on the outside, except for this occurring error.
what did you define parts as?
and, instead of using text for links, actually embed the link of the image to the text
@theking48989987 local Parts = Tool:GetChildren()
im not sure why you set v1 equivalent to Parts when you could just iterate through parts