//this performs an automatic sweep of all items in the user's backpack, and fills the the list entry with the items if it is possible public void FillFromBackpack(Mobile from) { if (from == null || from.Backpack == null) { return; } //generate a list of all items in the backpack List <Item> packitems = ItemStore.RecurseFindItemsInPack(from.Backpack); //go through backpack list, and try to add the items foreach (Item item in packitems) { AddItem(null, item); } //resend the store gump after it's all done if (!ItemStoreGump.RefreshGump(from)) { //send a new store gump if there's no existing one up from.SendGump(new ItemStoreGump(from, Store)); } //resend the item list entry gump after it's all done if (!ListEntryGump.RefreshGump(from)) { //send a new list entry gump if there's no existing one up from.SendGump(new ListEntryGump(from, this)); } }