| Parameter | Description |
|---|---|
| e | The entity to destroy. |
Records a command to destroy an entity.
At playback, this command throws an error if the entity was destroyed between recording and playback, or if the entity has the Prefab tag.
| Parameter | Description |
|---|---|
| entities | The NativeArray of entities to destroy. |
Records a command to destroy a NativeArray of entities.
At playback, this command only runs if the entity count is greater than 0. This command throws an error if any of the entities were destroyed between recording and playback, or if any of the entities have the Prefab tag.
| Parameter | Description |
|---|---|
| entityQuery | The query specifying the entities to destroy. |
| queryCaptureMode | Controls when the entities matching entityQuery are computed and captured. |
Records a command to destroy all entities matching a query.
| Parameter | Description |
|---|---|
| entityQuery | The query specifying the entities to destroy. |
Obsolete. Use EntityCommandBuffer.DestroyEntity instead.