Jump to content

[LE] how respawn specific NPC in (x) time


Recommended Posts

HI :smile:

created an enemy in creation kit, the problem when it dies does NOT reset, my goal is to reset in 24 hours, I do not find the specific command and my English is bad, I hope you apologize and thank you for the inconvenience :D (keep in mind that use creation kit 3 days ago..) :/


PD: if it serves them the created npc is called "Xzibit"

Edited by Robert271990
Link to comment
Share on other sites

There are a few approaches. The key to most of them is the function RegisterForSingleUpdateGameTime() and the events OnUpdateGameTime() and, probably, OnDeath(). The trickiest bit is figuring out how exactly you wish to attach the scripts.

Link to comment
Share on other sites

Hay algunos enfoques. La clave para la mayoría de ellos es la función RegisterForSingleUpdateGameTime () y los eventos OnUpdateGameTime () y, probablemente, OnDeath (). Lo más complicado es descubrir cómo exactamente deseas adjuntar los scripts.

simplifique, quiero que este npc (hombre lobo) tenga tiempo para reaparecer una vez que lo mate, por ejemplo 24h https://k62.kn3.net/6/9/5/F/4/8/900.png solo eso

Entiendo que debe crear un comando en la línea y el script, pero no sé cuál es,I just need an example
Edited by Robert271990
Link to comment
Share on other sites

Me gustaría saber eso también. Quería un cementerio embrujado donde el fantasma reaparezca todas las noches, incluso si hubiera sido asesinado.

if you find out please let me know :) but I think in this case you need another different script line
Edited by Robert271990
Link to comment
Share on other sites

Event OnDeath(Actor akKiller)
    ; if you care only that this event runs if the killer is the player.
    if akKiller == Game.GetPlayer()
        RegisterForSingleUpdateGameTime(24.0)
    endif
EndEvent

Event OnUpdateGameTime()
    ; this will need to be on an alias.
    ; Don't put scripts directly on the actor, unless it's not a vanilla actor.
    (GetReference() as Actor).Resurrect()
EndEvent

Not tested.

Not compiled.

Just a general idea.

Fast Travel, Sleeping, Waiting, anything that advances time will effect this Event (it'll run when all of that is done.)

 

If you have a problem using Resurrect, you can also choose Reset(), but the player cannot be in the same cell, I think, otherwise odd things will happen, like respawning with nothing but their underwear, and things like faction information is not reset.

Edited by Rasikko
Link to comment
Share on other sites

Event OnDeath(Actor akKiller)
    ; if you care only that this event runs if the killer is the player.
    if akKiller == Game.GetPlayer()
        RegisterForSingleUpdateGameTime(24.0)
    endif
EndEvent

Event OnUpdateGameTime()
    ; this will need to be on an alias.
    ; Don't put scripts directly on the actor, unless it's not a vanilla actor.
    (GetReference() as Actor).Resurrect()
EndEvent

Not tested.

Not compiled.

Just a general idea.

Fast Travel, Sleeping, Waiting, anything that advances time will effect this Event (it'll run when all of that is done.)

 

If you have a problem using Resurrect, you can also choose Reset(), but the player cannot be in the same cell, I think, otherwise odd things will happen, like respawning with nothing but their underwear, and things like faction information is not reset.

 

"the script extension does not exist" :sad: anyway thanks

Edited by Robert271990
Link to comment
Share on other sites

 

Event OnDeath(Actor akKiller)
    ; if you care only that this event runs if the killer is the player.
    if akKiller == Game.GetPlayer()
        RegisterForSingleUpdateGameTime(24.0)
    endif
EndEvent

Event OnUpdateGameTime()
    ; this will need to be on an alias.
    ; Don't put scripts directly on the actor, unless it's not a vanilla actor.
    (GetReference() as Actor).Resurrect()
EndEvent

Not tested.

Not compiled.

Just a general idea.

Fast Travel, Sleeping, Waiting, anything that advances time will effect this Event (it'll run when all of that is done.)

 

If you have a problem using Resurrect, you can also choose Reset(), but the player cannot be in the same cell, I think, otherwise odd things will happen, like respawning with nothing but their underwear, and things like faction information is not reset.

 

"the script extension does not exist" :sad: anyway thanks

 

 

All of those function calls exist in vanilla Skyrim. Can you provide the full and exact text of your script and the error log?

Link to comment
Share on other sites

  • Recently Browsing   0 members

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