-
Notifications
You must be signed in to change notification settings - Fork 2
UTDRL_LineOfSightComponent
Klian edited this page Mar 22, 2023
·
5 revisions
Parent: UActorComponent
This component will handle the sight visualization for the character. The system will trace the space in front of the character. With the resulting hit collisions, a series of triangles are drawn on a runtime texture. This texture is then used in the Global PostProcess material.
The following is a structure parameter used to control the component.
- Trace Channels: Channels the system should test for sight drawing, defaults are "WorldStatic" and "WorldDynamic"
- Sight Angle: Angle to trace relative to the character forward direction.
- Sub Angles: SubAngles to trace, increasing this value will increase the trace resolution but it will be more demanding on the CPU
- MaxDistance: Max distance to trace
- Collector: Collector used to collect parameters about sight and use them in the Global PostProcess material
- Texture Resolution: CanvasRenderTarget texture resolution used
- Canvas: CanvasRenderTarget used to draw the sight area
- Area Scale: Used to tweak the area affected by the Canvas in the real world. In other words, increasing this value will increase the margin around the character, preventing the canvas to be drawn multiple times on screen.
- Use Hide Actors Based on Class: Should hide a list of actor classes and make them visible only if they're in the sight cone?
- Tick Trace for Actors Every: Time delay between actors visibility traces
- Trace Body Relative Scale: When tracing for actors, the system will use the character's capsule as base shape, its size will be multiplied by this value (radius and height)
- Test Radius Around Owner: Area to trace around the actor (any direction, used for proximity)
- Hide Classes: List of classes to hide and show on sight
- Trace for Actors Channels: Channels to trace when the system is looking for hidden classes in the sight cone