62 virtual void TickComponent(
float DeltaTime,
enum ELevelTick TickType, FActorComponentTickFunction* ThisTickFunction)
override;
63 virtual void BeginPlay()
override;
64 virtual void BeginDestroy()
override;
67 UPROPERTY(BlueprintAssignable, BlueprintCallable, Category =
"LineOfSight Component\|Event")
68 FHitStart BeginOverlap;
71 UPROPERTY(BlueprintAssignable, BlueprintCallable, Category = "
LineOfSight Component\|Event")
75 UPROPERTY(BlueprintAssignable, BlueprintCallable, Category = "
LineOfSight Component\|Event")
76 FHitEveryFrame HitEveryFrame;
78 UPROPERTY(BlueprintAssignable, BlueprintCallable, Category = "
LineOfSight Component\|Event")
79 FRotateToAngleEnd RotateToAngleEnd;
82 UPROPERTY(EditAnywhere, Category = "
LineOfSight Component")
85 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "
LineOfSight Component")
88 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "
LineOfSight Component")
91 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "
LineOfSight Component")
94 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "
LineOfSight Component")
97 UPROPERTY(EditAnywhere, Category = "
LineOfSight Component")
100 UPROPERTY(EditAnywhere, Category = "
LineOfSight Component", meta = (ClampMin = "2", EditCondition = "GeometryType ==
ETypeArc::Arc_VectorLenght"))
104 UPROPERTY(EditAnywhere, Category = "
LineOfSight Component")
108 UPROPERTY(EditAnywhere, Category = "
LineOfSight Component", meta = (DisplayName = "HitEveryFrameEvent (Deprecated)"))
109 bool HitEveryFrameEvent;
112 UPROPERTY(EditAnywhere, Category = "
LineOfSight Component")
113 bool BeginAndEndOverlapEvent;
116 UPROPERTY(EditAnywhere, Category = "
LineOfSight Component")
119 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "
LineOfSight Component")
120 bool Only_Z_Rotation;
122 UPROPERTY(EditAnywhere, Category = "
LineOfSight Component")
125#if WITH_EDITORONLY_DATA
127 UPROPERTY(EditAnywhere, Category =
"LineOfSight Component")
130 UPROPERTY(EditAnywhere, Category = "
LineOfSight Component")
131 float DebugLineThickness = 2.0f;
134 UPROPERTY(EditAnywhere, BlueprintReadWrite, Category =
"LineOfSight Component")
135 UMaterialInterface* Material;
137 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
138 void SetAngle1(const
float NewAngle);
140 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
141 void SetAngle2(const
float NewAngle);
143 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
144 FORCEINLINE
float GetAngle1()
const {
return Angle1; };
146 UFUNCTION(BlueprintCallable, Category =
"LineOfSight Component")
147 FORCEINLINE
float GetAngle2()
const {
return Angle2; };
149 UFUNCTION(BlueprintCallable, Category =
"LineOfSight Component")
150 void SetRadius1(const
float NewRadius);
152 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
153 void SetRadius2(const
float NewRadius);
155 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
156 FORCEINLINE
float GetRadius1()
const {
return Radius1; };
158 UFUNCTION(BlueprintCallable, Category =
"LineOfSight Component")
159 FORCEINLINE
float GetRadius2()
const {
return Radius2; };
164 UFUNCTION(BlueprintCallable, Category =
"LineOfSight Component")
165 void SetStandardCollision(const
bool NewStatus);
169 bool bInterpAngleBool;
171 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
172 void StartInterpAngle(const
float NewAngle1, const
float NewAngle2, const
float Speed1, const
float Speed2);
174 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
175 void StopInterpAngle();
177 float AngleForInterpAngle1;
179 float AngleForInterpAngle2;
181 float SpeedInterpAngle1;
183 float SpeedInterpAngle2;
187 bool InterpRadiusBool;
190 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
191 void StartInterpRadius(const
float NewRadius1, const
float NewRadius2, const
float Speed1, const
float Speed2);
193 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
194 void StopInterpRadius();
196 float Radius1ForInterp;
198 float Radius2ForInterp;
200 float SpeedInterpRadius;
202 float SpeedInterpRadius1;
204 float SpeedInterpRadius2;
207 UPROPERTY(BlueprintReadWrite, Category = "
LineOfSight Component")
213 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
214 FORCEINLINE uint8 GetHitEveryFrame()
const {
return HitEveryFrameEvent; }
216 UFUNCTION(BlueprintCallable, Category =
"LineOfSight Component")
217 FORCEINLINE uint8 GetBeginAndEndOverlapEvent()
const {
return BeginAndEndOverlapEvent; }
219 UFUNCTION(BlueprintCallable, Category =
"LineOfSight Component")
220 void SetHitEveryFrame(const
bool NewValue);
222 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
223 void SetBeginAndEndOverlapEvent(const
bool NewValue);
225 FCollisionQueryParams TraceParams;
227 ECollisionChannel TraceChanne2;
230 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
231 void SetTraceChannel(const ETraceTypeQuery NewTraceChanne);
233 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
234 void SetTraceComplex(const
bool NewValue);
238 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
239 void AddIgnoredActor(UPARAM(ref) const AActor* ActorToIgnore);
242 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
243 void AddActorsToIgnore(UPARAM(ref) TArray<AActor*>& ActorsToIgnore);
245 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
246 void ClearActorsToIgnore(const
bool NewIgnoreSelf = true);
249 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
250 void SetIgnoreSelf(const
bool NewValueIgnoreSelf);
252 void BuildArcVectorLenght();
254 void BuildArcVectorLenghtFlat();
259 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
260 void StartLineTrace(ETraceTypeQuery TraceChannel, int32 NumberOfLines = 60);
264 UPROPERTY(Transient, DuplicateTransient)
267 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
270 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
277 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
278 void StopLineTrace();
281 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
282 void StartBuildMesh();
284 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
285 void StopBuildMesh();
287 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
288 void SetTickEnable(const
bool Enable);
290 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
291 void SetVisibilityOfMesh(const
bool NewVisibility);
293 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
294 bool MeshIsBuilt() const;
296 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
297 bool LineOfSightIsActive() const;
301 uint8 bRotateInRangeActive;
303 uint8 bRotateToAngleActive;
305 FRotator AngleRotateRot;
307 FRotator AngleRotateRot2;
309 FQuat AngleRotateQuat;
311 FQuat AngleRotateQuat2;
315 float Tolerance = 0.0000005f;
318 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
319 void SetTolerance(const
float NewTolerance);
325 void RotateInRange();
327 void RotateToAngle();
330 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
331 void StartRotateInRangeAxis(const
EAxisTypeComp Axis, const
float Angle,
float Speed, const
ETypeRotation TypeRotation, const
bool NegativeToPositive);
334 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
335 void StartRotateToAngleAxis(const
EAxisTypeComp Axis, const
float Angle, const
float Speed, const
ETypeRotation TypeRotation, const
bool AddToCurrent = true);
338 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
339 void StartRotateToActor(const
EAxisTypeComp Axis, AActor* Actor, const
float Speed);
341 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
342 void StopRotateToAngle();
344 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
345 void StopRotateInRange();
347 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
348 void StopAllRotate();
352 FRotator SetAxisValue(
EAxisTypeComp Axis, const
float Value, FRotator& Rotator);
355 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
356 FRotator FindAngleRotate(UPARAM(ref) AActor*& Actor);
359 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
360 void SetGeometryType(const
ETypeArc NewType);
363 UFUNCTION(BlueprintCallable, Category = "
LineOfSight Component")
364 void SetNormals(const FVector Normals);
374 bool bBuildMeshActive;
376 bool StartLineTraceActive;
378 TArray<FHitResult> WasStartOverlapArray;
381 TArray<FVector> PointArray1;
384 TArray<FVector> NormalVertex;
387 TArray<FVector2D> UV0;
390 TArray<FLinearColor> VertexColors;
393 TArray<FProcMeshTangent> Tangents;
396 TArray<int32> Triangle;