The information on this page may no longer be accurate. To see the latest, go to our new and improved documentation. You can also learn more about the future of documentation.
Collapse Sidebar



OverlapParams stores parameters for use with WorldRoot boundary-querying functions, in particular WorldRoot/GetPartBoundsInBox|GetPartBoundsInBox, WorldRoot/GetPartBoundsInRadius|GetPartBoundsInRadius and WorldRoot/GetPartsInPart|GetPartsInPart. The FilterDescendantsInstances property stores an array of objects to use as either a whitelist or blacklist based on the FilterType enum. The CollisionGroup property can specify a articles/Collision Filtering|collision group for the boundary query operation.

This data type performs a similar role as the datatype/RaycastParams type.

Unlike most datatypes on Roblox, all the members of OverlapParams can be changed without creating a new object. When performing boundary queries repeatedly, you should use the same object.


OverlapParams.new ( )

Creates a blank datatype/OverlapParams object. Unlike other datatype constructors, this constructor does not have any parameters, so you should set its properties appropriately.


array OverlapParams.FilterDescendantsInstances

An array of objects whose descendants will be used in filtering candidates.

RaycastFilterType OverlapParams.FilterType

Determines how the FilterDescendantsInstances list will be used, depending on the enum/RaycastFilterType provided.

  • Enum.RaycastFilterType.Whitelist — Only BasePart|BaseParts which are descendants of objects in the filter list will be considered.
  • Enum.RaycastFilterType.Blacklist — Every BasePart in the game will be considered except those that are descendants of objects in the filter list.
number OverlapParams.MaxParts

The maximum amount of parts to be returned by the query. The default value of zero (0) represents no limit.

string OverlapParams.CollisionGroup

Specifies a articles/Collision Filtering|collision group for the operation. Parts in collision groups that are set to not collide with this group will be ignored. If this property is omitted, the operation will assume the Default collision group.