This simple script can be added to any creatures ondeath event and it causes them to automatically respawn after a certain period of time. It removes the need for using encounters for killable NPCs.
Just change the RES_DELAY constant at the top of the script to change the respawn time in seconds.
Bobo, you need to put the script on your blueprint and re-place the monster.
If you just put in on the monster as placed it will respawn the blueprint monster and the blueprint doesn't have the special script. _________________________ My Submissions
Posted by bobo11.5 at 2006-09-22 22:01:10 Voted 10.00 on 09/22/06
I love this script, its like the only one simple enough for the scripting impared, but the creatures you respawn only come back once. Is there a way to make them come back over and over? _________________________ "Ironfist honor and manhood" "Oh you mean the two smallest things in all of faerun"
...
"Fat bellied little knee high"
It worked but now i also randomly crash while playing...
Also is there a way to make them spawn where they are placed and not where they die, and i placed one and four respawned
Posted by DaNippers at 2006-06-18 22:00:51 Voted 10.00 on 06/18/06
Thank you very much :) _________________________ "We came, We saw, we kicked .... OH MY GOD! RUN!!!!!"
When adding the code to an existing ondeath script, remove the line:
ExecuteScript("x2_def_ondeath", OBJECT_SELF);
It could easily cause a recursive endless loop (aka TMI). _________________________ My Submissions
Posted by DaNippers at 2006-06-18 15:10:12 Voted 10.00 on 06/18/06
GAH they don't allow the [code] command, Buggers lol well anyways that's the idea _________________________ "We came, We saw, we kicked .... OH MY GOD! RUN!!!!!"
Posted by DaNippers at 2006-06-18 15:09:18 Voted 10.00 on 06/18/06
VERY Nice, And it actually worked for me, lol Although now I randomly crash, Could be that I added it to the cnr skinnable creature Here's the code after Adding maybe you can Help me figure if that's where and how to fix???
[code]/////////////////////////////////////////////////////////
//
// Craftable Natural Resources (CNR) by Festyx
//
// Name: cnr_skin_ondeath
//
// Desc: The OnDeath handler for skinnable animals.
//
// Author: David Bobeck 18Feb03
//
/////////////////////////////////////////////////////////
const float RES_DELAY = 120.0f;
#include "cnr_config_inc"
#include "nw_i0_2q4luskan"