Thanks SteezMyster, but I don't understand the MoveTo function. I don't get where Marker01 comes from. I'm guessing it should be a variable/property, but I don't really get why I can't do "Game.GetPlayer().MoveTo(Riverwood)" like when I do "COC Riverwood" in console... Although I would prefer moving to a random exterior location, maybe within a certain radius of where you were killed, if that's possible. Or even the nearest inn would be good, too. Maybe that is easier.
This code does NOT work. It just keeps reloading the last save. I DO get the message, so it's firing, but again, the last save just gets reloaded. And if I set the actor as essential (by checking checkbox on alias), then OnDying doesn't fire.
Scriptname LeftForDeadScript extends ReferenceAlias ObjectReference Property WhiterunBanneredMare AutoEvent OnEnterBleedout() EndEventEvent OnDying(Actor akKiller) Game.GetPlayer().GetActorBase().SetEssential(True) Game.GetPlayer().RestoreActorValue("health", 100) Game.GetPlayer().MoveTo(WhiterunBanneredMare) Debug.MessageBox("You've been killed!")EndEventEDIT:
This code works, except the MoveTo function. Nothing happens.
Scriptname LeftForDeadScript extends ReferenceAlias ObjectReference Property WhiterunBanneredMare AutoEvent OnEnterBleedout() Game.GetPlayer().RestoreActorValue("health", 100) Game.GetPlayer().MoveTo(WhiterunBanneredMare)EndEventEvent OnDying(Actor akKiller) EndEvent