ID:918435
 
(See the best response by Nadrew.)
Code:
proc
RespawnWorld()
world.Repop()
spawn(600) RespawnWorld()


Problem description:
The code doest bring back the mobs i killed :/
This only works for /atom/movables present on the map at runtime. If you're not deleting them or if you're generating mobs using some sort of spawn tile then it won't work.
No I actually place the mob on the map
Are you initially calling RespawnWorld() somewhere?
No
Call it on new world?

world
New()
..()
RespawnWorld()
Best response
Should spawn() that call off, otherwise world/New() won't finish until RespawnWorld() finishes (and RespawnWorld() should be a loop so it'll never finish).

The original poster shouldn't be using recursive calls for this, but a while() loop.
proc/RespawnWorld()
while(world)
world.Repop()
sleep(600)

world/New()
..()
spawn(1) RespawnWorld()