Setup player preview for equipment panel

This commit is contained in:
2026-05-31 15:33:43 +03:00
parent 2969800966
commit aefabc8ed7
42 changed files with 823 additions and 318 deletions
@@ -2,6 +2,7 @@
#include "Interactable.h"
#include "Engine/OverlapResult.h"
#include "CollisionQueryParams.h"
#include "DrawDebugHelpers.h"
#include "NakedDesire/Player/NakedDesireCharacter.h"
UInteractionComponent::UInteractionComponent()
@@ -204,5 +205,16 @@ bool UInteractionComponent::HasLineOfSightFromPawn(AActor* Target) const
FHitResult Hit;
const bool bBlocked = GetWorld()->LineTraceSingleByChannel(Hit, Start, End, ECC_Visibility, Params);
#if ENABLE_DRAW_DEBUG
if (bDrawDebugLineOfSight)
{
const FColor LineColor = bBlocked ? FColor::Red : FColor::Green;
DrawDebugLine(GetWorld(), Start, bBlocked ? Hit.ImpactPoint : End, LineColor, false, 0.1f, 0, 1.f);
if (bBlocked)
DrawDebugPoint(GetWorld(), Hit.ImpactPoint, 10.f, FColor::Red, false, 0.1f);
}
#endif
return !bBlocked;
}