UnrealScripterAI
Discord ↗
Link Copied to Clipboard
×
"create a zombie spawner"
void AZombieSpawner::SpawnZombie() { // Spawn a zombie at a random location FVector SpawnLocation = FMath::VRand() * SpawnRadius; GetWorld()->SpawnActor<AZombie>(ZombieClass, SpawnLocation, FRotator::ZeroRotator); }