Jump to content

Photo

how to can I make a bobblehead stand with a container and auto populate the Stand

fallout 4 creation kit help

  • Please log in to reply
2 replies to this topic

#1
zed2015

zed2015

    Stranger

  • Premium Member
  • 5 posts

So i am working on a Player Base mod.  and I am using a Auto-Sorter to dump items from a central box into item containers.   this is working for me.  but I have ran into one issue that i cannot seems to work around. 

when a Bobblehead is placed into the Auto-Sorter.    the bobble-Head is transferred into the Bobblehead shelf inventory.  but it i does not show on the Shelf.  until a player goes to the shelf.  removes the Bobblehead from the inventory and then puts it back in.    I have been looking for a way to trigger the bobblehead shelf to automatically display the bobble head.  but I cannot get it to work

 

Sorry if this was asked before.   I have been looking for any posts / Videos / tutorials on this for a while.  and have not found anything that helps me. 

 

 

 



#2
SKK50

SKK50

    Institutum delenda est

  • Premium Member
  • 5,785 posts

You need to be looking at BobbleheadStandContainerScript to see what is happening.

 

If the stand has never loaded before it will be missing a BobbleheadsInContainer array which could be detected and fixed (this may not work on an uninitialized array, dunno you need to test):

If ((StandObjectReference as BobbleheadStandContainerScript).BobbleheadsInContainer.Length == 0)
   (StandObjectReference as BobbleheadStandContainerScript).BobbleheadsInContainer = New Form[0]
EndIf

Then the Event OnItemAdded should detect your bobblehead add, but it doesnt do anything as script activity is triggered by Event OnActivate which you can try to trigger remotely;

StandObjectReference.Activate(akActivator = Game.GetPlayer(), abDefaultProcessingOnly = false)

Understanding that if the stand does not have 3d loaded (or other conditions) things may go wrong as this is perpetrating unnatural acts on a system that was not designed to do this stuff.



#3
zed2015

zed2015

    Stranger

  • Premium Member
  • 5 posts

did not think that this would have been a unnatural act,

Thank you for the help.  but it did not work for me. 

it is good enough that the sorter is putting bobbleheads into the shelves inventory.   will just have to live with having to pull them out and putting them back in to get them to show.  

 

Thanks again







Also tagged with one or more of these keywords: fallout 4, creation kit, help

IPB skins by Skinbox
Page loaded in: 1.115 seconds