Bugfix Getting Shot and Taking No Damage
This commit is contained in:
parent
9ab356f813
commit
3b41b28b4c
@ -25,7 +25,7 @@ EBTNodeResult::Type UBTTask_AttackPlayer::ExecuteTask(UBehaviorTreeComponent& Ow
|
||||
{
|
||||
GunSKMesh = Cast<USkeletalMeshComponent>(AIController->GetPawn()->GetComponentsByTag(USkeletalMeshComponent::StaticClass(), "Gun")[0]);
|
||||
}
|
||||
FVector const Origin = IsValid(GunSKMesh) ? GunSKMesh->GetComponentLocation() : AIController->GetPawn()->GetActorLocation() + FVector(0.f, 0.f, 30.f);
|
||||
FVector const Origin = IsValid(GunSKMesh) ? GunSKMesh->GetSocketLocation("Muzzle") : AIController->GetPawn()->GetActorLocation() + FVector(0.f, 0.f, 30.f);
|
||||
FVector const Start = Origin;
|
||||
FVector const End = Origin + AIController->GetPawn()->GetActorForwardVector() * 100000.f;
|
||||
if (AEnemyCharacter* const EnemyCharacter = Cast<AEnemyCharacter>(AIController->GetPawn()))
|
||||
|
Loading…
Reference in New Issue
Block a user