Jump to content

Activate on Death


legacy001

Recommended Posts

It'll be very nice if someone could explain this to me.

 

I want to have a script where right after a NPC of a specific race dies, something activates (a message box, a sound byte, whatever). Now, since this is not specific to any NPC, I can't go in the construction set and have a script activate in the NPC dialog box. This must apply to all NPCs of that race. My intention was to have random dying words come from NPCs much like the creatures already do. It would be specific to races since I'd expect elves to say something different from Argonians.

 

Maybe there is already a mod that does this? Anyways, if you could offer any kind of help, please do. I'd appreciate it.

Link to comment
Share on other sites

It'll be very nice if someone could explain this to me.

 

I want to have a script where right after a NPC of a specific race dies, something activates (a message box, a sound byte, whatever). Now, since this is not specific to any NPC, I can't go in the construction set and have a script activate in the NPC dialog box. This must apply to all NPCs of that race. My intention was to have random dying words come from NPCs much like the creatures already do. It would be specific to races since I'd expect elves to say something different from Argonians.

 

Maybe there is already a mod that does this? Anyways, if you could offer any kind of help, please do. I'd appreciate it.

As far as I know, this cannot be done. Scripting needs specific targets for those scrpited effects to take place. essentially, you would need to script each and every member of that race to get them to say anything, or would need to apply a scripted spell effect to everyone before dying. Short of editing every NPC of that race in the game, or somehow forcing a scripted enchantment effect on all weapons, spells, or other means of attack, there really isn't any way to accomplish this. Additionally, any way which you might be able to accomplish this will probably have additional, unwanted, effects on your game.

 

Beyond that, you would still need to setup conversation dialogues which would have the conditions you would want. Simply put, probably not worth the effort to do this when you'd just be met with a sound effect (which would eventually get annoying) when you killed someone.

Link to comment
Share on other sites

Actually - this could be done with a quest script using OBSE. But it would not "be triggered" by an NPC death, it would instead periodically check for a dead NPC in the area. If you al

o used the quest script feature for controlling how frequently the script execut

d, it would not have to be too resource intensive either.

 

To get started, checkout the Oblivion Script Extender Documentation.

 

Good luck!

 

-Jumonji

 

edit: I wish this forum software would adhere to web standards so that messages from Opera would be formatted correctly. IE is not the only browser in the world.

Link to comment
Share on other sites

That's what I thought too after I toiled around. I don't want to be use OBSE if I can avoid it (harder to distribute and regulate).

 

I dumped the scripts for Ren's Corpse mod in which after a certain amount of time, zombies arise from the dead. From this I interpreted that it is possible to do something like what I said in the first place. I checked out his script and I'm pretty sure he added a custom ring to everyone that was an invisible mesh. And from there, I guess he attached a script to the ring as an enchantment, so that when the condition is fulfilled, something activates. I'm not too sure about this method since it seems like a very roundabout way to do things, but I'll keep on looking.

Link to comment
Share on other sites

I set the priority high enough and I don't think it works. Maybe it has to do with the fact that after dying the character is disabled? I'm not really sure of this, I only know that I have set the if-branch to "if dead == 1" and maxed the priority under "combat - hit."
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...