# ScheduleBatch(NativeArray<OverlapBoxCommand>, NativeArray<ColliderHit>, int, int, JobHandle)

> Schedule a batch of overlap box commands to perform in a job.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine](/engine/6000.6/script-reference/unityengine.md)
* **Assembly:** UnityEngine.PhysicsModule

```csharp
public static JobHandle ScheduleBatch(NativeArray<OverlapBoxCommand> commands, NativeArray<ColliderHit> results, int minCommandsPerJob, int maxHits, JobHandle dependsOn = default)
```

### Parameters

**** (\[NativeArray\<OverlapBoxCommand>]\(/engine/6000.6/script-reference/unity/collections/nativearray1)): A NativeArray of the OverlapBoxCommands to perform.**** (\[NativeArray\<ColliderHit>]\(/engine/6000.6/script-reference/unity/collections/nativearray1)): A NativeArray of the ColliderHits where the results of the commands are stored.**** (\[int]\(https\://learn.microsoft.com/dotnet/api/system.int32)): The minimum number of commands to perform in a single job.**** (\[int]\(https\://learn.microsoft.com/dotnet/api/system.int32)): The maximum number of Colliders the overlap can hit.**** (\[JobHandle]\(/engine/6000.6/script-reference/unity/jobs/jobhandle)): A JobHandle of a job which must be completed before the overlap box starts.

### Returns

| Type                                                                 | Description                                                  |
| -------------------------------------------------------------------- | ------------------------------------------------------------ |
| [JobHandle](/engine/6000.6/script-reference/unity/jobs/jobhandle.md) | The JobHandle of the job which will perform the overlap box. |
