sornan Posted November 30, 2020 Share Posted November 30, 2020 Hello :) I've got 4 Hobbits that are cowering at the presence of the Nazgul before them. Using a fleeTo package with proper flags keeps them in place and crouching in fear. Problem is, I have not yet found a way to stop the Nazgul from attacking them. The player shows up and fights the Nazgul, so I can't prevent the Nazgul from being able to go into combat. I've done quite a bit of searching on the web, and in the functions list, and can't seem to find a command to get an Npc to be in a 'state' where they would not be attacked by hostiles. Is there a function that might work to make an Npc unattackable (will not be engaged), or is the only way to mess with scripting faction changes? Any help appreciated. TIA :) Link to comment Share on other sites More sharing options...
dylbill Posted November 30, 2020 Share Posted November 30, 2020 I think the best way would be to use factions, or set a relationship between the hobbits and the nazgul as friends or neutral. There's also the StopCombat() script function which you could also mess around with. Link to comment Share on other sites More sharing options...
skyflash71 Posted November 30, 2020 Share Posted November 30, 2020 go to Character/Factioncreate x2 factionsHobbits and Nazguladd hobbits to Hobbits faction in character/actor/your hobbit npcadd Nazgul to Nazgul faction go back and edit each factions in interfaction Relactions tab add new faction and change the Opposing/Affiiated Faction to PlayerFactionset Group Combat Reaction to Neutral add another faction to the list and this time change it to Nazgul faction and set Reaction to Neutral edit the Nazgul factionadd playerfaction as Enemeyadd Hobbits faction as Neutral you are done , now the hobbits are neutral to player and Nazgul while player can fight Nazgul Link to comment Share on other sites More sharing options...
sornan Posted December 2, 2020 Author Share Posted December 2, 2020 (edited) Thank you very much guys :smile: Thanks Dylbill for the suggestions there - The relationship I'd start with, just because in case it works, sounds like the easiest way to go. I can try StopCombat, I have not had success with it in the past but it takes a few moments to see if it might work. Factions may be the way in the end. Thank you Skyflash for piecing all of that together, I appreciate that a lot, especially when I have never really messed with faction changes much. I have a sense there's a good chance the faction adjustments will be the way, see what happens through some testing. Ah, thanks! :smile: Edited December 2, 2020 by sornan Link to comment Share on other sites More sharing options...
sornan Posted December 6, 2020 Author Share Posted December 6, 2020 (edited) Did a test run trying out Relationship, with the player and an Npc that was Bandit Faction, Relationship Ally, and it worked - the guy tried to kill my horse, and other nearby Npc's, but left me alone and even allowed dialog once he was out of combat. The downside, something I didn't know is that for Relationship to work, the actor must be Unique and therefore only one reference allowed. The Nazgul in the quest mod are not unique, and already added in editor and in script. I'd have to remove some things and add things to get it to work this way - but it does work, and is an option :smile: Going to test the faction approach now, and if it works it may be the way as I should not have to modify existing content in the quest mod. On a side note, the StopCombat I'm not quite sure how it would work, even if it did, as it looks like a Bool, not using actual actor references, and the Nazgul need to still be able to fight with the player. Anyhow, carrying on :smile: /Edit Not to triple post :p Tried the factional changes, it works. I had to adjust factions to Ally state to prevent the Nazgul from attacking the hobbits and themselves as well, my suspicion is this is due to them being 'very aggressive' in their AI settings. Either way, it's great, they hold position nearby the cowering Hobbits, and then engage the player once in range. Thanks everyone for the help. :) Edited December 6, 2020 by sornan Link to comment Share on other sites More sharing options...
Recommended Posts