UnrealScripterAI
Discord ↗
Link Copied to Clipboard
×
"make an npc that follows the player"
void AMyCharacter::MakeNPC() { // Spawn an NPC AEnemyCharacter* NPC = GetWorld()->SpawnActor<AEnemyCharacter>(NPCClass); // Set the NPC's target NPC->SetTarget(this); }