I don’t know how helpful this is, but I figured out what was causing this in my game - repeatably. I haven’t figured out a workaround…but I have ‘fixed’ the actors where the iteminfo is being reset to the default of the parent actor.
I have a BP_MasterItem
I have children of BP_MasterItem -> BP_itemHealthPotion and BP_weaponHeroSword which are craftable, as well as other items which are not craftable
I ran into this problem as soon as I closed Unreal Engine after making BP_itemHealthPotion and BP_weaponHeroSword craftable - narrowing down where to look. The method I was using to create a recipe list was in my inventory actor (BP_Inventory) I have a variable array - CraftingRecipes - of type BP_MasterItem: I populated the default values of this array with BP_weaponHeroSword and BP_itemHealthPotion.
Those 2 BP actor’s iteminfo were reset back to default, as well as their ingredient components (which were stored in iteminfo as a an array of S_InventorySlots (which contains ItemClass of type BP_MasterItem and an Amount integer)
I found that if an item was added to the CraftingRecipes array with no ingredients populated in the iteminfo, it still would reset - so I don’t think that is important – but I found that even though the ingredient components were no longer referenced explicitly in the iteminfo of BP_weaponHeroSword and BP_itemHealthPotion, if you went to Reference Viewer, they were still being referenced (and therefore still reset) when closing and opening the game.
I found that just adding ingredient components was not causing anything to reset as well if that BP was not added to the CraftingRecipes variable array.
I made another ingredient component made from BP_MasterItem → BP_MasterResource → Child – this was still defaulted when the BP that was calling it as an ingredient was added to the CraftingRecipes variable array.
I’m not entirely sure what conclusions to draw from this, but I found the cause in Unreal Engine for me, and I explored it a bit. My solution is to find another workaround for populating a recipe list…