It must have been a case of bad luck on your part,
electricfood in respect of this timer work, as you say that you've been able to activate the discarded zombies and spawn them with a button hit (I take that you mean "binding the function to a keyboard key" -or, was it authoring a pop-up box with a radio button? But this is not that important) so you must be able to write a timer rather easily, and I'm sure that you will do that in no time (even if you haven't already done so) when you've read the article that you refer to on
S.T.A.L.K.E.R. MOD portal just once again, as
that article is a brilliant work -and very detailed-
to describe the function that you're asking and I could put it only that much.
Answer is over there, in detail. Just read it carefully, you must've missed something possibly.
Also,
just from a technical point of view, the script piece that you quote, which you forgot to mention where you put it and from whom you've got it
-as the author's instructions still remains embedded- would not work like that. As you would know
" -- " is a
commenting out order and after it, the author of the script tells you to
"spawn stuff" there, at that section. By
"stuff" he of course means that anything that you want to spawn which is spawnable. I painted
RED the
commented out instruction part in your quote, in which you are asked to spawn things. electricfood wrote:I've been trying to make a script to spawn waves of zombies for me to mow down, but I've hit a brick wall. Spawning zombies on a button press is pretty easy, but I can't figure out a way to have the script wait and spawn another wave later.
I've tried the following code, but it causes the game to hang.
==========================================================
local next_spawn = 0
while true do
if next_spawn < time_global() then
-- spawn stuff !_HERE you are asked to spawn the things that you want_! And then remove the comment out, of course.
next_spawn = time_global() + 30000
end
end
==========================================================
I found a timer tutorial
here, but I can't figure it out. I don't know how to make the update method get called by stalker's scripting engine. Is there a script that gets called regularly by the engine that I should edit?
In that part, you must put your spawning script. I mention this just for a general point. You need to follow the article, it's a best written answer. I know the guy who wrote it, and you should take his word.
