Jump to content

[LE] Inconsistent Respawning Script


Medabev

Recommended Posts

Hey all! Hope all is well.

I'm Currently writing this around 3:00am because for some reason one of my scripts, a good friend of mine made for me - now refuses to work for me.

The Script is simple, Select an Actor and Objectreference for spawnpoint, input time to wait(this varies from 5 to 10mins), Clean corpse and Respawn. My main Goal is to have a constant stream of spread-out Patrols (like immersive Patrols) but without the long grueling wait periods for something to respawn (and will spawn regardless if you enter a cell)

 

I was told, however that this is heavy running, and after trying to optimize my projects I see the truth of that. In the beginning the Script worked fine then the Corpse stopped being deleted, enemies were spawning where they died and not returning to the spawn point. The good news is at least in my efforts to fix this problem I was able to make better another one of my scripts, just this one remains. I've tried many things, multiple actors spawn in one xmarkerheading, xmarkerheadings per actor and I'm getting the same result.

 

I'm open to suggestions, I'll keep trying different things out and figuring out whats wrong.

ActorBase Property ActorBaseProperty Auto
ObjectReference Property spawnPoint Auto
Int Property SecondsForRespawn Auto    

Event OnDeath(Actor akKiller)
    Utility.wait(SecondsForRespawn)
    spawnPoint.PlaceActorAtMe(ActorBaseProperty)
    Self.Delete()
  endevent

EDIT: I fixed it, it seems to work without the spawnpoint. I readjusted everything and now its fine. :cool:

Edited by Juebev
Link to comment
Share on other sites

  • Recently Browsing   0 members

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