I know what FindPartsInRegion3 is, but what is FindPartsInRegion3WithIgnoreList? and can you explain the parameters of it?
Similar to FindPartOnRayWithIgnoreList, FindPartsInRegion3WithIgnoreList returns all parts within region 3, except those specified in the ignore list. The ignore list is an array that contains indexed objects that you don't want the function to return when you call it.
The first parameter is the region3 you wish to find parts in.
The second parameter is an array (table) which contains all of the parts you don't want the function to return, so if there's an object inside the region3 that's also on the ignore list, the function will ignore it.
The third parameter is the maximum amount of parts inside the region3 that the function will return, defaulting to 20 and limited to 100.
Note that parts specified in the ignore list are not returned by the function, but do count towards the maximum parts returned.