#include <AdvancedPawnSensingComponent.h>
◆ GetSensorRotation()
| FRotator UAdvancedPawnSensingComponent::GetSensorRotation |
( |
| ) |
const |
|
overridevirtual |
Get the rotation of this sensor. We need this for the sight component
7{
8 FRotator SensorRotation(FRotator::ZeroRotator);
9 const AActor* SensorActor = GetSensorActor();
10 if (SensorActor != nullptr)
11 {
12 FVector SensorLocation;
13 SensorActor->GetActorEyesViewPoint(SensorLocation, SensorRotation);
14 return SensorRotation;
15 }
16 return Super::GetSensorRotation();
17}
The documentation for this class was generated from the following files: