I have a blueprint called BP_BaseItem. And in it there is a variable ItemInfo and I set it like this in the construction script:
…And in the event graph I I made a script that I can pickup the item:
And it’s doing perfectly fine I made a debug and it says on the screen what I picked up and and how many:
…However, when I use the item with this script I made:
The debug says zero, the ItemInfo variable becomes empty:
What did I miss here? Please help.
Can you share your inventory code, functions remove and add?
I can’t do it right now, im at work.
Hey man, First of all I just want to say thank you so much for taking your valuable time in looking into my post, I appreciate it. Here are my Add and Remove Functions in my inventory bp.
add item function:
Remove Item Function:
Here is a custom event in BP_inventory that call the EventOnUsed custom event in BP_BaseItem. Maybe this also causes the problem.
Guys, anyone have some idea of what I did wrong?
Hey guys, never mind, I solved it. I just added Index variable in the baseitem blueprint and used it to pass the index number everytime I call the “UseItemAtIndex”