RobloxScripterAI
Discord ↗
Link Copied to Clipboard
×
"NPC spawner will spawn 3 random NPC in one spawner"
-- script for NPC Spawner local spawner = script.Parent local NPCS = {"NPC1", "NPC2", "NPC3"} -- replace with your NPC names local function spawnNPC() for i = 1, 3 do local randomNPC = NPCS[math.random(#NPCS)] local clone = game.ServerStorage[randomNPC]:Clone() clone.Parent = game.Workspace clone.HumanoidRootPart.CFrame = spawner.CFrame wait(2) end end spawnNPC()