Millinescence Posted December 30, 2010 Share Posted December 30, 2010 Hello~ I'm new to the forums and a novice at modding. I just got the Oblivion Construction Set and I'm trying to make my own spell called Absorb Items. What it does is simple, it's supposed to remove all items from a target and put them in your inventory, that or have them all be dropped onto the ground for the player to pick up. There's a function called "removeallitems" but that just takes all their items and permanently removes them from the character. Link to comment Share on other sites More sharing options...
NellSpeed Posted December 30, 2010 Share Posted December 30, 2010 In theory, what you could try is something the CS Wiki suggests: RemoveAllItems TargetContainerID What that means is, all the items are put into a container, rather than simply destroyed. You'd have to also create a permanent container for the items to be put into-- I'm afraid I've got no idea how you'd put them straight into your inventory-- and you'd need to work out how to specify that a specific NPC's items are the ones you want (GetSelf?). I'm sorry I can't be of more concrete help, but I'm pretty sure this CAN be done! Link to comment Share on other sites More sharing options...
Millinescence Posted December 30, 2010 Author Share Posted December 30, 2010 (edited) In theory, what you could try is something the CS Wiki suggests: RemoveAllItems TargetContainerID What that means is, all the items are put into a container, rather than simply destroyed. You'd have to also create a permanent container for the items to be put into-- I'm afraid I've got no idea how you'd put them straight into your inventory-- and you'd need to work out how to specify that a specific NPC's items are the ones you want (GetSelf?). I'm sorry I can't be of more concrete help, but I'm pretty sure this CAN be done!A permanent container? Hmmm....the Bag of Holding mod comes to mind. Which I just happen to have. I need to find the formID for that bag though. Thanks so much~! Cookie for you :3 Edit:I've tried the alphanumerical ID that the CS gave me for the BoH, and I got an error about an "invalid object reference to parameter container (optional)". I even tried references to the well in Skingrad, still gave me that same error. Edited December 30, 2010 by Millinescence Link to comment Share on other sites More sharing options...
NellSpeed Posted December 30, 2010 Share Posted December 30, 2010 The alphanumerical won't work-- not for custom items. What you want is the reference editor ID. I haven't got the CS in front of me, but the CS will help with this. What you'll need to be doing is to find where the BoH is physically located-- you can find that under Activators > Containers. Go there, open up the properties tab from the cell, and you should see the RefID: http://cs.elderscrolls.com/constwiki/index.php/Image:Tut_img_10.jpg The RefID is what you'll use to identify the container. So you'd have something like this in your script: NPCReferenceEditorID.removeallitems ContainerReferenceID Hope this makes a bit more sense. Link to comment Share on other sites More sharing options...
Millinescence Posted December 30, 2010 Author Share Posted December 30, 2010 The alphanumerical won't work-- not for custom items. What you want is the reference editor ID. I haven't got the CS in front of me, but the CS will help with this. What you'll need to be doing is to find where the BoH is physically located-- you can find that under Activators > Containers. Go there, open up the properties tab from the cell, and you should see the RefID: http://cs.elderscrolls.com/constwiki/index.php/Image:Tut_img_10.jpgIt's located in Vilverin (player.coc Vilverin04) where the necromancer lives....that is until you pick it up. Then the container itself will be in your inventory, which is what makes it so handy. But what version of CS is that image? Activators and Containers are a separate category on the one I have. (My version is 1.2.404)Link to BoH mod Link to comment Share on other sites More sharing options...
GreatLucifer Posted December 30, 2010 Share Posted December 30, 2010 (edited) have you tried; ref.removeallitems player ? As the player is considered a persistent referance, this should work just fine, and very direct. As for the ref, you could try something like "set ref to GetSelf". Lucifer EDIT I have confirmed my suspicions :yes: This is the script...; scn AAAStealAllEffect ref Self begin ScriptEffectStartset Self to GetSelfSelf.removeallitems playerend Works like a charm. Hope this helped. Lucifer Edited December 30, 2010 by GreatLucifer Link to comment Share on other sites More sharing options...
Millinescence Posted December 31, 2010 Author Share Posted December 31, 2010 EDIT I have confirmed my suspicions :yes: This is the script...; scn AAAStealAllEffect ref Self begin ScriptEffectStartset Self to GetSelfSelf.removeallitems playerend Works like a charm. Hope this helped. LuciferOMGs! Thanks so much~! ^-^ I just got done testing your script and it does exactly what I wanted it to do. Here's your well-deserved cookie :thumbsup: Link to comment Share on other sites More sharing options...
Deleted1848331User Posted December 31, 2010 Share Posted December 31, 2010 (edited) I'm so putting that in my game for myself... "Hey, Haskill, come here for a second..." lol edit This has officially made my day xD Edited December 31, 2010 by Guest Link to comment Share on other sites More sharing options...
GreatLucifer Posted December 31, 2010 Share Posted December 31, 2010 Thanks man, I love kudos ;) And be warned; I have not tested this on unplayable stuff (like Haskill)... I have no idea how that will behave :D Lucifer Link to comment Share on other sites More sharing options...
Deleted1848331User Posted December 31, 2010 Share Posted December 31, 2010 Thanks man, I love kudos ;) And be warned; I have not tested this on unplayable stuff (like Haskill)... I have no idea how that will behave :D Lucifer I suppose I can do it on Sheogorath... especially since I can toggle tcl and enableplayercontrols after I hit him muhahahahaha Link to comment Share on other sites More sharing options...
Recommended Posts