Fantafaust Posted February 26, 2023 Share Posted February 26, 2023 Just a quick question, if I'm perusing a container that has unplayable/hidden items and hit Take All, will it also take those items? I assume it doesn't and I don't want it to, but I figured I'd ask. Link to comment Share on other sites More sharing options...
SKKmods Posted February 26, 2023 Share Posted February 26, 2023 Yes that is correct. BUT the script call RemoveAllItems() CAN remove hidden/unplayable as I found with (a) Companion default hidden weapons and (b) Feral ghoul skins that are aaa/armor records and many many more amusing instances. Link to comment Share on other sites More sharing options...
Fantafaust Posted February 26, 2023 Author Share Posted February 26, 2023 That's pretty hilarious lolThanks for the answer, I wanted to rework one of my personal power armor mods but if Take All also got hidden items I'd be screwed to keep it working for long.Glad to hear that's not the case Link to comment Share on other sites More sharing options...
lee3310 Posted February 27, 2023 Share Posted February 27, 2023 Yes that is correct. BUT the script call RemoveAllItems() CAN remove hidden/unplayable as I found with (a) Companion default hidden weapons and (b) Feral ghoul skins that are aaa/armor records and many many more amusing instances. I know you don't use F4SE in your mods but there is a function in "LL_FourPlay" plugin that helps with the skin part: Form Function GetActorBaseSkinForm(Actor akActor) native globalIf LL_FourPlay.GetActorBaseSkinForm(akActor) != akItem ;remove... Link to comment Share on other sites More sharing options...
LarannKiar Posted February 28, 2023 Share Posted February 28, 2023 (edited) With F4SE, one can call the Take All function by UI.Invoke too: UI.Invoke("ContainerMenu", "root1.FilterHolder_mc.Menu_mc.onTakeAll") onTakeAll() is a public function in ContainerMenu.swf that calls: this.BGSCodeObj.takeAllItems(). (".this" is the MovieClip, BGSCodeObj is a public variable filled by the native game code (this is the actual object whose container is open), takeAllItems() is a function defined in the .exe that takes everything that is meant to be takeable). Edited February 28, 2023 by LarannKiar Link to comment Share on other sites More sharing options...
PJMail Posted March 1, 2023 Share Posted March 1, 2023 I think at one point I found RemoveAllItems() will not move 'unplayable' items if the destination is the player, but not 100% sure if they aren't just lost.As the player can't have unplayable items. Link to comment Share on other sites More sharing options...
LarannKiar Posted March 1, 2023 Share Posted March 1, 2023 (edited) As the player can't have unplayable items. The player can have unplayable items in their inventory force-added by AddItem() but without showing up in the menu. I think they count in GetInventoryWeight() and GetItemCount() too. Edited March 1, 2023 by LarannKiar Link to comment Share on other sites More sharing options...
PJMail Posted March 1, 2023 Share Posted March 1, 2023 True - you can add anything you like to the player by, say, using the CK to add inventory items to the player. However, in the context of this discussion, my point was the game actively tries to stop the player getting unplayable items - so to keep that in mind when using script functions like removeallitems. I even think unplayable items can't be transfered to Settlement Workshops, but I haven't done extensive testing. Link to comment Share on other sites More sharing options...
lee3310 Posted March 2, 2023 Share Posted March 2, 2023 (edited) With F4SE, one can call the Take All function by UI.Invoke too: UI.Invoke("ContainerMenu", "root1.FilterHolder_mc.Menu_mc.onTakeAll") onTakeAll() is a public function in ContainerMenu.swf that calls: this.BGSCodeObj.takeAllItems(). (".this" is the MovieClip, BGSCodeObj is a public variable filled by the native game code (this is the actual object whose container is open), takeAllItems() is a function defined in the .exe that takes everything that is meant to be takeable).This is very interesting. Can you specify another target/container ? also, is there a similar function that can be used as an alternative to addItem() ? (the papyrus one can cause a reset inventory bug on some NPCs) Edited March 2, 2023 by lee3310 Link to comment Share on other sites More sharing options...
PJMail Posted March 4, 2023 Share Posted March 4, 2023 With F4SE, one can call the Take All function by UI.Invoke too: UI.Invoke("ContainerMenu", "root1.FilterHolder_mc.Menu_mc.onTakeAll") onTakeAll() is a public function in ContainerMenu.swf that calls: this.BGSCodeObj.takeAllItems(). (".this" is the MovieClip, BGSCodeObj is a public variable filled by the native game code (this is the actual object whose container is open), takeAllItems() is a function defined in the .exe that takes everything that is meant to be takeable).This is very interesting. Can you specify another target/container ? also, is there a similar function that can be used as an alternative to addItem() ? (the papyrus one can cause a reset inventory bug on some NPCs) You can get around that additem/reset issue in papyrus by doing the additem(s) on a temporary container then using "Container.RemoveAllitems(NPC)" to transfer the object(s) to the NPC.This does not trigger the inventory/outfit reset issue. Link to comment Share on other sites More sharing options...
Recommended Posts