Yeah, it’s like I thought.
Modify InventoryStruct to contain an item class, and on begin play call GetClass on self, use ‘set members in struct’ to set the class (purple) variable. Modify your Action Interface to take a class instead of a reference in “DropAction”.
In your UI, when you click to drop (I’m guessing this in in UI) instead of using the reference, just pass in the class variable. Then, in your drop functionality, don’t worry about ‘GetClass’ and just Spawn Actor from the class itself.
*The problem *is that when you store the item in item info, you’re storing a reference to the spawned instance of your item class. The ‘Destroy’ node starts the destruction process, which won’t be processed immediately (I don’t think) so although you typically should call Destroy last- I don’t think this is hurting your BP. Anyway, Destroy finishes pretty quickly and by the time you drop the item, there is no item at that reference- it’s nullptr.
You can test this by dragging the reference which is passed in and using ‘IsValid’ and printing a string depending on the result. Spawn Actor won’t have a class to spawn, your print strings have no value to print. That’s why the strings don’t appear.