Box Overlap

Physics
Tanto lado del cliente como del usuario
Disponible en PC y móvil

Use a static box-shaped area for detection and return all entities within the box-shaped area. If the level parameter is filled in, the terrain can be detected.

Declaración

func BoxOverlap(halfExtents Vector3, center Vector3, rotation Vector3, layerMask List<int>, includeTrigger bool, out var hitEntities List<entity<Entity>>)
go

Parámetros

Entrada

Nombre Tipo Descripción
Half Extents Vector3 Half the length of the three sides of the box area, only positive values are accepted
Center Vector3 Box area center point
Rotation Vector3 Box area rotation
Layer Mask ListT_int Layer mask, only the filled layers will participate in the scan, leaving it blank means all layers will participate in the scan
Include Trigger Bool Whether the trigger can be detected

Afuera

Nombre Tipo Descripción
Hit Entities ListT_Entity List of entities hit