BlueBeard1983 Posted February 1, 2014 Posted February 1, 2014 Ok, I was wondering if anyone could help me with creating a script for a custom companion I'm working on. What I want is on the companions death, they are moved to another cell, resurrected, and after 2 game days, is teleported to the player and automatically rehired.
jazzisparis Posted February 1, 2014 Posted February 1, 2014 Add the following segment to your quest script: short bResurrect float fResurrectDelay ; Add the above with the rest of the variables of your script. begin GameMode if bResurrect if (GameDaysPassed - fResurrectDelay) >= 2 set bResurrect to 0 CompanionRef.Enable CompanionRef.ResurrectActor 1 CompanionRef.MoveTo player CompanionRef.SetPlayerTeammate 1 endif elseif CompanionRef.GetDead set bResurrect to 1 CompanionRef.Disable set fResurrectDelay to GameDaysPassed endif end Replace CompanionRef with your companion's unique Reference ID.You should also set the companion to be a Quest Item.
Recommended Posts