Hey there! I am a new developer in Roblox studio and I’m also new to the Roblox DevForm. I am making a zombie survival like game and all was good until this happened.
The Problem
So I was making my Zombie spawners for my game and the problem was, that all of the zombies were spawning at only one place! That two, they were spawning very, very fast. Here is a before and after complication were before i run the game and after I run the game.
Before
And After
As you can see, the zombies are all bunched up in one place and none of the other spawners are not spawning any zombies. Instead, they are spawning only at this one spawn.
You can also see they are spawning REALLY quickly as well.
The Script
This is the script I used in all of the Zombie spawners. (Below) Can someone please tell me how to fix the problem on how to make the other zombie spawns spawn in the other spawners and not only that one spawn, and also tell me how to slow the zombie spawn down. Thanks!
local NPC = game.ReplicatedStorage["Normal Zombie"] -- This is what my zombie model is
local spawner = script.Parent
while true do
local Clone = NPC: Clone(1) --This is the number on how many zombies should spawn at a time
Clone.UpperTorso.CFrame = spawner.CFrame
Clone.Parent = workspace
wait(5) -- How long it takes to wait and repeat the script again
end
Things to Note for Replying
Here is a few things to note down before solving my problem.
- I do have one model of two parts which have the script and spawner in it. I also used the same model and copy and pasted it in the spawn area. (About 3 or 4 times)
- The script could only work for R15 Zombie models and were I put the name of the model is the name of the model and it has to be the name of the model or else the script can’t work. (Giving me a better zombie model is nice of you if you give it to me becuase that was the best R15 zombie model i could find.
)
- Even though I get rid of the zombie spawner that always spawns all of zombies, it still spawns the zombies at that one place!
- Even though I get rid of all of the spawners and zombies in my game and replicated storage. (The place were i have to put the zombies in order for the zombies to actually spawn) and add them back, the first spawner I make, all of the other zombie spawners will only spawn at the first zombie spawner! And if I get rid of that one, they still spawn at the same place were the spawner was!
That’s it for things to note.
Anyways, that is it. Thanks for reading and I appreciate your help if you help me!