Jump to content

Question about Take All


Fantafaust

Recommended Posts

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

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 global

If LL_FourPlay.GetActorBaseSkinForm(akActor) != akItem

;remove...

 

Link to comment
Share on other sites

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 by LarannKiar
Link to comment
Share on other sites

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 by LarannKiar
Link to comment
Share on other sites

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

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 by lee3310
Link to comment
Share on other sites

 

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

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...