-- Decompiled with the Synapse X Luau decompiler.


local l__Instance_new__1 = Instance.new;
return function(p1)
	return function(p2, ...)
		local v1 = l__Instance_new__1(p1);
		local l__Parent__2 = p2.Parent;
		if l__Parent__2 then
			p2.Parent = nil;
		end;
		local l__next__3 = next;
		local v4 = nil;
		while true do
			local v5 = nil;
			local v6 = nil;
			v6, v5 = l__next__3(p2, v4);
			if not v6 then
				break;
			end;
			v4 = v6;
			if type(v6) == "number" then
				v5.Parent = v1;
			else
				v1[v6] = v5;
			end;		
		end;
		if l__Parent__2 then
			v1.Parent = l__Parent__2;
		end;
		if not ... then
			return v1;
		end;
		local v7 = { ... };
		for v8 = 1, #v7 do
			local v9 = v1:Clone();
			local l__next__10 = next;
			local v11 = v7[v8];
			local v12 = nil;
			while true do
				local v13 = nil;
				local v14 = nil;
				v14, v13 = l__next__10(v11, v12);
				if not v14 then
					break;
				end;
				v12 = v14;
				if type(v14) == "number" then
					v13.Parent = v9;
				else
					v9[v14] = v13;
				end;			
			end;
			v9.Parent = not v9.Parent or l__Parent__2;
			v7[v8] = v9;
		end;
		return v1, unpack(v7);
	end;
end;
