Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Expected identifier when parsing function name, got '(', line 962?

function()SimpleWeld(x,y)
	local W = Instance.new("Weld")
	    W.Part0 = x
	    W.Part1 = y
	    W.Parent = x
    end
end)

any ideas?

2 answers

You meant (function (x,y) ? (at line1) Or function SimpleWeld (x,y)

3 comments

0

function SimpleWeld (x,y)

0

Oh ok accept if it help xd

0

i still get the same error

You define a function like this:

function getWeld(x,y)
	--Code
end

You are defining your function like this:

function() getWeld(x,y)
	--Code
end

Also, you had a loose end in line 6.

Hope this helped.

This discussion is preserved as it was. New answers, comments, and votes are closed.