Sunbleached Posted December 18, 2019 Share Posted December 18, 2019 Hello! I'm trying to create an unpacker script for gacha (no copy items). is there any way to make the content appear in the folder and not in the objects? while it gives out just objects one by one. string START_TEXT = "Touch To Unpack"; // Text on rez string END_TEXT = "Item Is In Your Inventory"; // Text on completion string OPEN_SOUND = "6f61a589-b000-b685-d198-8c50d35dc926"; // Opening sound UUID default { state_entry() { llSetMemoryLimit(llGetUsedMemory()+1024); llSetText(START_TEXT, <1.0,1.0,1.0>, 1); } touch_start(integer n) { if(llDetectedKey(0)==llGetOwner()) // Detect owner { for (n--;n>=0;n--) { integer j=llGetInventoryNumber(INVENTORY_ALL); for (j--;j>=0;j--) { string name=llGetInventoryName(INVENTORY_ALL,j); if (llGetInventoryType(name)!=INVENTORY_SCRIPT) { llGiveInventory(llDetectedKey(n),name); llTriggerSound(OPEN_SOUND, 1.0); llSetText(END_TEXT, <1.0,1.0,1.0>, 1); llRemoveInventory(llGetScriptName()); // Script self-delete } } } } } } Link to comment Share on other sites More sharing options...
Alyona Su Posted December 18, 2019 Share Posted December 18, 2019 (edited) Serious question: Does it need to be a scripted unpacker? Were I to resell no-copy items, I'd just put it into a box and set the box to give contents on click. Then attach it as a HUD and position it to set that option. Now it works when rezzed or worn as a HUD and will create a folder named the same as the box name, and all inventory will go into that folder with a notice that no-copy items will be moved. I'm just wondering, because it seems to me that unpacker scripts are a solution to non-existant problem. If you are trying to do something special (like creating multiple inventory folders, etc.,) then I do understand. That requires scripting. Edited December 18, 2019 by Alyona Su 1 Link to comment Share on other sites More sharing options...
Fritigern Gothly Posted December 18, 2019 Share Posted December 18, 2019 5 hours ago, Sunbleached said: Hello! I'm trying to create an unpacker script for gacha (no copy items). is there any way to make the content appear in the folder and not in the objects? while it gives out just objects one by one. Can't be done. I have created an inventory archive system using boxes, which will give you back your items on touch. I have everything given to a folder, but no copy items will be given one item at a time and can only arrive in the system folders which correspond to their type. This is the ONLY way no copy items can be transferred from a prim's inventory into your own. A trick that I use is to have the script send a full-perm placeholder notecard to a folder with the name of the box, then have people look in their recent files and move all new items which did NOT arrive in that folder, over so that all the items are where they belong. I would not have done this, if it weren't for the fact that I wanted to store some of my old outfits which for some reason came with mixed perms. 1 Link to comment Share on other sites More sharing options...
Ruthven Ravenhurst Posted December 30, 2019 Share Posted December 30, 2019 On 12/18/2019 at 8:20 AM, Alyona Su said: Serious question: Does it need to be a scripted unpacker? Were I to resell no-copy items, I'd just put it into a box and set the box to give contents on click. Then attach it as a HUD and position it to set that option. Now it works when rezzed or worn as a HUD and will create a folder named the same as the box name, and all inventory will go into that folder with a notice that no-copy items will be moved. I'm just wondering, because it seems to me that unpacker scripts are a solution to non-existant problem. If you are trying to do something special (like creating multiple inventory folders, etc.,) then I do understand. That requires scripting. I thought attachments (even huds) couldn't be opened that way? I will have to test that Link to comment Share on other sites More sharing options...
Recommended Posts
Please take a moment to consider if this thread is worth bumping.
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now