First thing I notice is you are using GetChildren on a table? Your post says that you are using a table; GetChildren is used for getting a list of all of the children in a Roblox object.
A few other questions I have, if I have missed anything in the original post:
Could you print out the contents of malepants and maleshirts (and same for female)
Could you print out the results of each RandomInt() call?
What does the function RandomInt() code look like?
It could also be helpful if you pointed out which line had the error, to make sure this just isn’t a table specific issue. One last protip would be to provide some more of your code, to make it easier to narrow down a potential fix.
To put in simply; You put your ) at the end, so you are calling :GetChildren() on the number from the table, which is not a function of a number, thus this error. (You called :GetChildren() on a number, the number was not expected)
To fix it, simply move your ) to the left:
local success,MESSAGE = pcall (function()
if dummy.Gender.Value == "Male" then
Pants = game:GetService("InsertService"):LoadAsset(malepants[RandomInt(1,#malepants)]):GetChildren()[1]
Shirt = game:GetService("InsertService"):LoadAsset(maleshirts[RandomInt(1,#maleshirts)]):GetChildren()[1]
elseif dummy.Gender.Value == "Female" then
Pants = game:GetService("InsertService"):LoadAsset(femalepants[RandomInt(1,#femalepants)]):GetChildren()[1]
Shirt = game:GetService("InsertService"):LoadAsset(femaleshirts[RandomInt(1,#femaleshirts)]):GetChildren()[1]
end
end)