Inventory Dump

From ZenMondo Wormser, 1 Year ago, written in Linden Scripting, viewed 315 times.
URL http://flynnos.org/flynnbin/view/477ce20a Embed
Download Paste or View Raw
  1. //////////////////////
  2. //Inventory Dump by ZenMondo Wormser
  3. //
  4. // Just place in a prim, along with the inventory items to be given.
  5. // To retrieve the inventory, just touch the prim.
  6. // Contents will be given in a folder named what you want by changing
  7. // a line below (default is Inventory Dump).
  8. //////////////////////
  9.  
  10. // Change "Inventory Dump"  to the name of the folder you want the object to give.(keep the quotes)
  11. string folder_name = "Inventory Dump";
  12.  
  13.  
  14. {
  15.    
  16.  
  17.     touch_start(integer total_number)
  18.     {
  19.         integer counter = 0;
  20.         integer inventory_num = llGetInventoryNumber(INVENTORY_ALL);
  21.        
  22.         list inventory_list;
  23.        
  24.         while(counter < inventory_num)
  25.         {
  26.             inventory_list = (inventory_list=[]) + inventory_list + llGetInventoryName(INVENTORY_ALL, counter);
  27.             counter ++;
  28.         }
  29.        
  30.         list scriptname = [llGetScriptName()];
  31.        
  32.         integer index = llListFindList(inventory_list, scriptname);
  33.        
  34.         inventory_list = llDeleteSubList(inventory_list, index, index);
  35.        
  36.        
  37.         llGiveInventoryList(llDetectedKey(0), folder_name, inventory_list);
  38.        
  39.        
  40.        
  41.     }
  42. }
  43.  

Reply to "Inventory Dump"

Here you can reply to the paste above

captcha