Files
2026-06-03 15:17:03 +03:00

30 lines
507 B
C++

// © 2025 Naked People Team. All Rights Reserved.
#include "NPCTargetLocation.h"
#include "NPC.h"
ANPCTargetLocation::ANPCTargetLocation()
{
PrimaryActorTick.bCanEverTick = false;
}
bool ANPCTargetLocation::TryClaim(ANPC* InClaimant)
{
if (Claimant.IsValid() && Claimant.Get() != InClaimant)
return false;
Claimant = InClaimant;
return true;
}
void ANPCTargetLocation::Release(ANPC* Requester)
{
if (!Claimant.IsValid() || Claimant.Get() != Requester)
return;
Claimant = nullptr;
}