WeaponBase #8
Binary file not shown.
@@ -67,17 +67,21 @@ void ADDICharacter::Server_SpawnProjectile_Implementation()
|
||||
FVector Location = GetActorLocation();
|
||||
FRotator Rotation = GetActorRotation();
|
||||
FVector Dir = GetActorForwardVector();
|
||||
|
||||
// GetActorEyesViewPoint(Location, Rotation);
|
||||
|
||||
Location += Dir * 200.f;
|
||||
Location += Dir * 55.f;
|
||||
|
||||
if (!ProjectileClass)
|
||||
{
|
||||
GEngine->AddOnScreenDebugMessage(1, 10.f, FColor::Emerald, "No Projectile Set");
|
||||
return;
|
||||
}
|
||||
GetWorld()->SpawnActor<AActor>(ProjectileClass, Location, Rotation);
|
||||
|
||||
|
||||
|
||||
FActorSpawnParameters SpawnInfo;
|
||||
SpawnInfo.Owner = this;
|
||||
SpawnInfo.Instigator = GetInstigator();
|
||||
GetWorld()->SpawnActor<AActor>(ProjectileClass, Location, Rotation, SpawnInfo);
|
||||
}
|
||||
|
||||
void ADDICharacter::Client_CharacterHit_Implementation()
|
||||
|
||||
Reference in New Issue
Block a user