15#include "AIPerceptionComponent.generated.h"
26USTRUCT(BlueprintType, meta = (DisplayName =
"Sensed Actor's Update Data"))
32 UPROPERTY(BlueprintReadWrite, Category =
"AI|Perception")
36 UPROPERTY(BlueprintReadWrite, Category = "AI|Perception")
40 UPROPERTY(BlueprintReadWrite, Category = "AI|Perception")
80 const float Age = LastSensedStimuli[
Sense].GetAge();
88 Location = LastSensedStimuli[
Sense].StimulusLocation;
110 for (
const FAIStimulus& Stimulus : LastSensedStimuli)
125 for (
const FAIStimulus& Stimulus : LastSensedStimuli)
164 return LastSensedStimuli.
IsValidIndex(
Sense) && (LastSensedStimuli[
Sense].IsValid() && (LastSensedStimuli[
Sense].IsExpired() ==
false));
181USTRUCT(BlueprintType, meta = (DisplayName =
"Sensed Actor's Data"))
186 UPROPERTY(BlueprintReadWrite, Category =
"AI|Perception")
189 UPROPERTY(BlueprintReadWrite, Category = "AI|Perception")
192 UPROPERTY(BlueprintReadWrite, Category = "AI|Perception")
195 UPROPERTY(BlueprintReadWrite, Category = "AI|Perception")
218 UPROPERTY(EditDefaultsOnly, Instanced, Category = "AI Perception")
223 UPROPERTY(EditDefaultsOnly, Category = "AI Perception")
260 uint32 bForgetStaleActors : 1;
306 template<
typename T,
typename = std::enable_if_t<std::is_base_of_v<UAISenseConfig, T>>>
325 UFUNCTION(BlueprintCallable, Category=
"AI|Perception")
345 UFUNCTION(BlueprintCallable, Category =
"AI|Perception")
353#if WITH_GAMEPLAY_DEBUGGER_MENU
364 UFUNCTION(BlueprintCallable, Category =
"AI|Perception")
367 UFUNCTION(BlueprintCallable, Category = "AI|Perception")
371 UFUNCTION(BlueprintCallable, Category = "AI|Perception")
375 UFUNCTION(BlueprintCallable, Category = "AI|Perception")
379 UFUNCTION(BlueprintCallable, Category = "AI|Perception")
384 UFUNCTION(BlueprintCallable, Category = "AI|Perception")
389 UFUNCTION(BlueprintCallable, Category = "AI|Perception")
448 UE_DEPRECATED(5.6,
"RefreshStimulus is deprecated. Use ConditionallyStoreSuccessfulStimulus() instead.")
#define UE_DEPRECATED(Version, Message)
Definition CoreMiscDefines.h:302
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
#define DECLARE_DYNAMIC_MULTICAST_DELEGATE_TwoParams(DelegateName, Param1Type, Param1Name, Param2Type, Param2Name)
Definition DelegateCombinations.h:62
#define DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(DelegateName, Param1Type, Param1Name)
Definition DelegateCombinations.h:53
#define UPROPERTY(...)
UObject definition macros.
Definition ObjectMacros.h:744
#define UFUNCTION(...)
Definition ObjectMacros.h:745
#define GENERATED_UCLASS_BODY(...)
Definition ObjectMacros.h:768
#define UCLASS(...)
Definition ObjectMacros.h:776
#define USTRUCT(...)
Definition ObjectMacros.h:746
#define GENERATED_USTRUCT_BODY(...)
Definition ObjectMacros.h:767
Definition AIController.h:91
Definition GameplayDebuggerCategory.h:49
Definition UnrealType.h:3087
UE_REWRITE SizeType Num() const
Definition Array.h:1144
SizeType AddDefaulted()
Definition Array.h:2795
UE_NODEBUG UE_FORCEINLINE_HINT bool IsValidIndex(SizeType Index) const
Definition Array.h:1122
Definition AssetRegistryState.h:50
Definition UnrealString.h.inl:34
Definition ObjectKey.h:228
Definition SubclassOf.h:30
Definition AIPerceptionSystem.h:31
Definition AISenseConfig.h:19
Definition ActorComponent.h:152
virtual ENGINE_API void OnRegister()
Definition ActorComponent.cpp:1542
virtual ENGINE_API void OnUnregister()
Definition ActorComponent.cpp:1577
virtual ENGINE_API void PostInitProperties() override
Definition ActorComponent.cpp:592
virtual ENGINE_API void BeginDestroy() override
Definition ActorComponent.cpp:1144
Definition EngineTypes.h:3429
constexpr FVector InvalidLocation
Definition AITypes.h:30
@ false
Definition radaudio_common.h:23
static uint32 GetSize()
Definition AITypes.h:212
Definition AIPerceptionTypes.h:130
bool IsValid() const
Definition AIPerceptionTypes.h:198
bool IsExpired() const
Definition AIPerceptionTypes.h:193
bool WasSuccessfullySensed() const
Definition AIPerceptionTypes.h:192
Definition AIPerceptionComponent.h:183
Definition AIPerceptionComponent.h:50
TWeakObjectPtr< AActor > Target
Definition AIPerceptionComponent.h:51
FAISenseID DominantSense
Definition AIPerceptionComponent.h:57
FVector GetReceiverLocation(const FAISenseID Sense) const
Definition AIPerceptionComponent.h:152
FVector GetLastStimulusLocation(float *OptionalAge=nullptr) const
Definition AIPerceptionComponent.h:73
bool HasAnyCurrentStimulus() const
Definition AIPerceptionComponent.h:123
TArray< FAIStimulus > LastSensedStimuli
Definition AIPerceptionComponent.h:53
uint32 bIsHostile
Definition AIPerceptionComponent.h:60
bool HasKnownStimulusOfSense(const FAISenseID Sense) const
Definition AIPerceptionComponent.h:162
bool HasAnyKnownStimulus() const
Definition AIPerceptionComponent.h:108
FVector GetStimulusLocation(const FAISenseID Sense) const
Definition AIPerceptionComponent.h:142
uint32 bIsFriendly
Definition AIPerceptionComponent.h:63
bool IsSenseActive(const FAISenseID Sense) const
Definition AIPerceptionComponent.h:172
FActorPerceptionInfo(AActor *InTarget=nullptr)
Definition AIPerceptionComponent.h:65
Definition AIPerceptionComponent.h:28
Definition GenericTeamAgentInterface.h:24
Definition AIPerceptionTypes.h:36
Definition VisualLoggerTypes.h:205
Definition ObjectPtr.h:488
Definition WeakObjectPtrTemplates.h:25