After killing the enemy npc [del(src)] how do I make them respawn on the map?
ID:1229046
Apr 6 2013, 10:32 am (Edited on Apr 6 2013, 10:47 am)
|
|
mob Everything looks great ^^ I'm just curious about what if I make 30+ of the same npc will I need to set src.loc=locate(?,?,?) for each of them? |
Yes. Or if(istype(src,mob/AI)) (Which would do all the AI, I believe)
mob |
mob/var This would be easier to do, I didn't test though |
Ah, one more question though. How do I make spawning delays for the AI's after they die?
|
In response to Mitz001
|
|
Create a variable such as spawn_delay for each NPC then do spawn(src.spawn_delay) before restoring them.
|
In response to Albro1
|
|
or she/he could do the normal sleep proc xD
|
In response to Haiji
|
|
You could, however, if you wanted to change anything about that mob between the time that you call the sleep and when it ends, you can't. Sleep halts everything about the mob until it's over. Spawn just waits for a certain amount of time, letting other things work like normal.
|
Something like that, but then again I didn't test it.