Zorkaz Posted January 9, 2021 Share Posted January 9, 2021 Setup: A gate closes behind you and you're utterly alone. Every companion will stand behind it unable to enter Does anyone know a good way to prevent companions to follow you into certain areas? The place must be navmeshed Btw. "Followers Can't Travel Here" is one option but maybe there's a better one Link to comment Share on other sites More sharing options...
DieFeM Posted January 9, 2021 Share Posted January 9, 2021 You would need a quest with higher priority than the Followers quest with a package (I guess a wait package) in a RefCollectionAlias or ReferenceAlias that would override the companion/follower package and, somehow (maybe using OnLocationChange) add/remove the follower/companion from this alias as needed. Link to comment Share on other sites More sharing options...
WIGWAM Posted January 12, 2021 Share Posted January 12, 2021 Tried to do a similar thing and I sort of thing. This is a script that I got off another mod author, You'll need to do some editing as not all of it is necessary: Scriptname CoU_RemoveCompanions extends ObjectReference ;Properties Action Property akIdle Auto ObjectReference Property marker Auto ;Events Event OnActivate(ObjectReference akActionRef) Game.ForceFirstPerson() Actor[] playerFollowers = Game.GetPlayerFollowers() int index = 0 while (index < playerFollowers.Length) playerFollowers[index].MoveTo(marker) playerFollowers[index].DisallowCompanion(true) index += 1 endWhile Game.GetPlayer().PlayIdleAction(akIdle) EndEvent This should go on the door that leads to the cell. It should work on any companion that is implemented properly. If they are just on a "follow" AI package they wont be affected. Personally I couldn't get this to work so I ended up with a less elegant solution that just repletely moves the current follower outside the cell: Scriptname LLitCW_FXScript extends ObjectReference Group Location_Properties Location Property MyLocation Auto Const GlobalVariable property LLiTCW_FXTimer auto ObjectReference Property marker Auto EndGroup int FXTimer = 1 Event OnLoad() StartTimer(LLiTCW_FXTimer.GetValue(), FXTimer) EndEvent Event OnTimer(int aiTimerID) ;---Temp Stop Companions--- if (aiTimerID == FXTimer) && Game.GetPlayer().IsInLocation(MyLocation) Actor[] playerFollowers = Game.GetPlayerFollowers() int index = 0 while (index < playerFollowers.Length) playerFollowers[index].MoveTo(marker) index += 1 endWhile StartTimer(LLiTCW_FXTimer.GetValue(), FXTimer) Endif EndEvent Link to comment Share on other sites More sharing options...
Recommended Posts