Arc Sensor
The Arc Sensor detects objects that intersect a curve. It works just like the Ray Sensor in that it detects all objects up to the first obstruction. The arc is broken up into line segments and a raycast is done on each.
An Arc Sensor detects a platform that can be jumped to
Output Signals
Object
-Collider.gameObject
orCollider.attachedRigidBody.gameObject
depending on Detection ModeStrength
- Set to 1Shape
- Zero-size Bounds centred at the point of intersection
An obstruction is not represented by a Signal
. Obstructions are not defined to be detected, although it is possible for the same GameObject
to be detected and obstructing simultaneously.
you can retrieve details about the intersection of the ray with each object. Access it with the GetDetectionRayHit()
or GetObstructionRayHit()
methods.
Configuration
Parameterisation
How the arc is parameterised. Two choices are available:
- Bezier - A quadratic bezier curve defined by three points in local space.
- Ballistic - The arc of a projectile with constant velocity and acceleration over some amount of time.
Segments
The number of straight line segments the arc is broken into. The sensor does a raycast over each segment so it's best to keep the number as low as possible. The segments have variable length to fit the curve more closely.
Layers
See Ray Sensor
Filters
See Ray Sensor
Optimisation Considerations
See Ray Sensor