Skip to main content

aabb3_raycast

aabb3_raycast(result, result_offset, x0, y0, z0, x1, y1, z1, origin_x, origin_y, origin_z, direction_x, direction_y, direction_z) ⇒ boolean

Kind: global function
Returns: boolean - true if ray hit the box, false otherwise
See

ParamTypeDescription
resultArray.<number> | ArrayLike.<number> | Float32Arrayhit 6-tuple is written here as follows: [hit_position_x, hit_position_y, hit_position_z, hit_normal_x, hit_normal_y, hit_normal_z]
result_offsetnumberoffset into result array where to write the hit data
x0number
y0number
z0number
x1number
y1number
z1number
origin_xnumberray origin
origin_ynumberray origin
origin_znumberray origin
direction_xnumberray direction
direction_ynumberray direction
direction_znumberray direction