mentilreq Posted July 26, 2010 Share Posted July 26, 2010 I am looking for help with a player home I am making. I have two problems with the auto sorters: 1. Whenever an item is removed from my inventory and placed in the container it appears in the container at 100% health, 2. I would like to know if there is a way to disable the "item removed" message from appearing for each item removed. Any Help would be greatly appreciated, I am brand new to scripting and I have searched everywhere with no luck. This is the script I have been using. int listnumFint myCountint formrefnumFref formref set formrefnumF to ListGetCount MRsortsmallarms Label 1 if listnumF <= formrefnumF set formref to listgetnthform MRsortsmallarms listnumF set myCount to player.getitemcount formref player.removeitem formref myCount smallarms.additem formref myCount set listnumF to listnumF + 1 goto 1endifset listnumF to 0 Link to comment Share on other sites More sharing options...
Cipscis Posted July 27, 2010 Share Posted July 27, 2010 RemoveItem and AddItem both have an optional third parameter that you can use to tell them not to show that message. For example:;' Just ignore this line. It''s here to make the code readable player.RemoveItem formRef myCount 1The issue of items having 100% health is a bit more complicated, though. When you use RemoveItem and [url="http://geck.bethsoft.com/index.php/AddItem[/url] to move items around, you're not actually moving items around. What you're really doing is deleting items with RemoveItem, and creating new items with AddItem. If you want to actually move items, you'll need to use RemoveAllItems, but that will cause a lot of "message spam" and move a whole lot of other items as well. You can control which items are and aren't moved by using FOSE v1.2s IsQuestItem and SetQuestItem (RemoveAllItems doesn't move quest items), using a form list to store the items that have their "quest item" status changed so that you can change them all back after moving the items. It's not the easiest thing to do, but it's certainly doable. Cipscis Link to comment Share on other sites More sharing options...
mentilreq Posted July 27, 2010 Author Share Posted July 27, 2010 RemoveItem and AddItem both have an optional third parameter that you can use to tell them not to show that message. For example:;' Just ignore this line. It''s here to make the code readable player.RemoveItem formRef myCount 1The issue of items having 100% health is a bit more complicated, though. When you use RemoveItem and [url="http://geck.bethsoft.com/index.php/AddItem[/url] to move items around, you're not actually moving items around. What you're really doing is deleting items with RemoveItem, and creating new items with AddItem. If you want to actually move items, you'll need to use RemoveAllItems, but that will cause a lot of "message spam" and move a whole lot of other items as well. You can control which items are and aren't moved by using FOSE v1.2s IsQuestItem and SetQuestItem (RemoveAllItems doesn't move quest items), using a form list to store the items that have their "quest item" status changed so that you can change them all back after moving the items. It's not the easiest thing to do, but it's certainly doable. CipscisThanks, I'll try it tonight. Link to comment Share on other sites More sharing options...
AlexxEG Posted July 27, 2010 Share Posted July 27, 2010 I found out how to additems with a certain health. You gonne need to find a way to save the condition of the item you remove to a variable. This is the setup to add items to containers/actors with a certain health. Actor.AddItemHealthPercent Item:ObjectID Count:int HealthPercent:float MessageHiddenFlag:int EDIT: This is where I found it, incase you wanne know. AddItemHealthPercent - GECK Link to comment Share on other sites More sharing options...
Recommended Posts