Navigation
API > API/Runtime > API/Runtime/AIModule > API/Runtime/AIModule/Perception
Inheritance Hierarchy
- UObject
- UAISense
- UAISense_Sight
References
| Module | AIModule |
| Header | /Engine/Source/Runtime/AIModule/Classes/Perception/AISense_Sight.h |
| Include | #include "Perception/AISense_Sight.h" |
Syntax
UCLASS (ClassGroup=AI, Config=Game, MinimalAPI)
class UAISense_Sight : public UAISense
Variables
| Type | Name | Description | |
|---|---|---|---|
| bool | bSightQueriesOutOfRangeDirty | ||
| bool | bUseAsynchronousTraceForDefaultSightQueries | Defines if we are allowed to use asynchronous trace queries when there is no IAISightTargetInterface for a Target | |
| ECollisionChannel | DefaultSightCollisionChannel | ||
| TMap< FPerceptionListenerID, FDigestedSightProperties > | DigestedProperties | ||
| float | HighImportanceDistanceSquare | ||
| float | HighImportanceQueryDistanceThreshold | ||
| int32 | MaxAsyncTracesPerTick | Maximum number of asynchronous traces that can be requested in a single update call | |
| float | MaxQueryImportance | ||
| double | MaxTimeSlicePerTick | ||
| int32 | MaxTracesPerTick | ||
| int32 | MinQueriesPerTimeSliceCheck | ||
| int32 | NextOutOfRangeIndex | The SightQueries are a n^2 problem and to reduce the sort time, they are now split between in range and out of range Since the out of range queries only age as the distance component of the score is always 0, there is few need to sort them In the majority of the cases most of the queries are out of range, so the sort time is greatly reduced as we only sort the in range queries | |
| FTargetsContainer | ObservedTargets | ||
| FOnPendingVisibilityQueryProcessedDelegate | OnPendingCanBeSeenQueryProcessedDelegate | ||
| FTraceDelegate | OnPendingTraceQueryProcessedDelegate | ||
| float | PendingQueriesBudgetReductionRatio | Defines the amount of async trace queries to prevent based on the number of pending queries at the start of an update. | |
| float | SightLimitQueryImportance | ||
| TArray< FAISightQuery > | SightQueriesInRange | ||
| TArray< FAISightQuery > | SightQueriesOutOfRange | ||
| TArray< FAISightQuery > | SightQueriesPending |
Constructors
| Type | Name | Description | |
|---|---|---|---|
UAISense_Sight
(
const FObjectInitializer& ObjectInitializer |
Functions
| Type | Name | Description | |
|---|---|---|---|
| float | CalcQueryImportance
(
const FPerceptionListener& Listener, |
||
| EVisibilityResult | ComputeVisibility
(
UWorld* World, |
||
| void | GenerateQueriesForListener
(
const FPerceptionListener& Listener, |
||
| void | OnListenerRemovedImpl
(
const FPerceptionListener& RemovedListener |
||
| void | OnListenerUpdateImpl
(
const FPerceptionListener& UpdatedListener |
||
| void | OnNewListenerImpl
(
const FPerceptionListener& NewListener |
||
| void | OnPendingCanBeSeenQueryProcessed
(
const FAISightQueryID& QueryID, |
||
| void | OnPendingQueryProcessed
(
const int32 SightQueryIndex, |
||
| void | OnPendingTraceQueryProcessed
(
const FTraceHandle& TraceHandle, |
||
| void | RegisterEvent
(
const FAISightEvent& Event |
||
| bool | RegisterNewQuery
(
const FPerceptionListener& Listener, |
||
| bool | RegisterTarget
(
AActor& TargetActor, |
Returns information whether new LoS queries have been added | |
| void | RemoveAllQueriesByListener
(
const FPerceptionListener& Listener, |
||
| void | RemoveAllQueriesToTarget
(
const FAISightTarget::FTargetId& TargetId, |
||
| void | RemoveAllQueriesToTarget_Internal
(
const FAISightTarget::FTargetId& TargetId, |
RemoveAllQueriesToTarget version that need to already have a write access on QueriesListAccessDetector | |
| bool | ShouldAutomaticallySeeTarget
(
const FDigestedSightProperties& PropDigest, |
||
UE_MT_DECLARE_RW_ACCESS_DETECTOR
(
QueriesListAccessDetector |
|||
| void | UpdateQueryVisibilityStatus
(
FAISightQuery& SightQuery, |
||
| void | UpdateQueryVisibilityStatus
(
FAISightQuery& SightQuery, |
Overridden from UAISense
| Type | Name | Description | |
|---|---|---|---|
| void | OnListenerConfigUpdated
(
const FPerceptionListener& UpdatedListener |
||
| void | OnListenerForgetsActor
(
const FPerceptionListener& Listener, |
||
| void | OnListenerForgetsAll
(
const FPerceptionListener& Listener |
||
| void | |||
| void | RegisterSource
(
AActor& SourceActors |
Virtual void RegisterSources(TArray |
|
| void | UnregisterSource
(
AActor& SourceActor |
||
| float | Update () |
Classes
| Type | Name | Description | |
|---|---|---|---|
| FDigestedSightProperties |
Enums
| Type | Name | Description | |
|---|---|---|---|
| EVisibilityResult | |||
| FQueriesOperationPostProcess |
Typedefs
| Name | Description |
|---|---|
| FTargetsContainer |