ID:158559
 
Okay, so I've made this system where you can buy certain mobs to place on the map for a defense system. Got it working and all, but I'm not sure how to go about saving the mob's location to that particular place on the map upon death of the mob to respawn it there, or upon reboot/deletion of the world.

How do I do this? I'm not too familiar with saving entire world stuff and I only want to save one particular type of mob.

I've tried various things. Just can't get it to work, so any help would be appreciated.
You can either save the individual x, y, and z locations, or if you're not intending to reboot between the time it is deleted and respawned, save the loc itself.
Then just use "loc = locate(sx,sy,sz)" or "loc = savedloc"
In response to Kaiochao
How would I go about doing that though? Could you give me a quick example?

I've found out that not only does the NPC not stay after reboot/world del but if it kills someone it disappears completely and if it is killed, it disappears as well.
In response to Acryptid
When the NPC dies, send it to a null location instead of deleting it. Then just move it back to the saved location contained in a variable.
In response to Acryptid
Acryptid wrote:
I've found out that not only does the NPC not stay after reboot/world del but if it kills someone it disappears completely and if it is killed, it disappears as well.

This would be an issue with your deathcheck() proc, or how you are calling it.