scarycave Posted August 31, 2012 Share Posted August 31, 2012 Anybody know a way to make an Npc add an item to him/herself in their responsibility < 10? I was thinking of making a mod where you have to collect a certain item from dead evil characters and trade them in for prizes. I'm okay with having to go through every npc and adding it but if theirs a faster way I'd be glad to hear it. Link to comment Share on other sites More sharing options...
blackninja50 Posted August 31, 2012 Share Posted August 31, 2012 I don't know of any way to do that save for manually adding the item to every evil actor, although I think you can add an item to all leveled bandits and murderers with a leveled list. Link to comment Share on other sites More sharing options...
cfh85 Posted September 1, 2012 Share Posted September 1, 2012 You could add a token to the PC. Add a script on it that runs an array looks for actors in the current cell, using GetFirstRef 35 1 and GetNextRef 35 1. Or set an array_var to GetHighActors. The check the responsibility of each actor with If ((TempRef.GetAV Responsibility) <= 10) and add the item.You would either need to check if the actor already has the item or keep track of all the actors who have the item added (I think you can do that with an array). Set the script to run once a minute or two.They may be a function to check through ever actor in the game at once, but I've not seen it yet. I'm not 100% sure but I'm fairly sure that if you edit (in the CS) every NPC with a low responsibility then it would override changes made by other mods (if yours is loaded last). If you do it with a script then it's more compatible, though will add to save game bloat (probably) even if only a little Link to comment Share on other sites More sharing options...
Maskar Posted September 1, 2012 Share Posted September 1, 2012 (edited) The easiest method would probably be a quest script running once every x seconds checking for npcs in the area (much like cfh85 suggested) and check if they have low responsibility and don't have the item (GetItemCount == 0). If they don't have it simply add and equip it. You might also be able to edit the leveled lists (AddToLeveledList), depending on your criteria. You shouldn't directly edit npcs or leveled lists though, to avoid incompatibilities. An alternative method to check if an npc is evil is by checking if he/she is in an evil faction, rather than look at his/her responsibility. Edited September 1, 2012 by Maskar Link to comment Share on other sites More sharing options...
Maskar Posted September 1, 2012 Share Posted September 1, 2012 (edited) double post. please delete. Edited September 1, 2012 by Maskar Link to comment Share on other sites More sharing options...
scarycave Posted September 1, 2012 Author Share Posted September 1, 2012 Thanks for the help guys. :)I'll try it out. Link to comment Share on other sites More sharing options...
Recommended Posts