Hello, I have a doubt with one pick up actor. The logic is to destroy the container and every time we destroy the cash stat updates but some how the I dont know how to use interface to notify the player character that the actor has been destroyed and it should update the stat value please help!!!
It’s not clear what the logic is here.
Each time the player hits a pickup, they get cash, and the container gets ‘weaker’?
What is the container?
Hello,
The logic is I have an blueprint called Container. The function you see here is about the damage the container takes. The health value is 100 for the container,. Each time the player hits the container it deducts 20 from the health and as soon as its health goes down to 0 it gets destroyed. My query here is I want to put a logic which says once the container is destroyed, add 100 cash to player stats. Please let me know if its still unclear
Ok. So the player is dealing damage to the container. Just before the container destroys itself, it can send a blueprint interface message to the player to say ‘job done - 100 points’
I see you have that ‘burned’ message, but you’re not sending it to anything, so it goes to the owning blueprint. You need to send it to the player ( I’m guessing? ).
If that’s the case, you can just use ‘get player character’ and plug that into the burned call.
Yes, the get player character component was missing. Thank you so much for helping this quick. Actually, I was confused because I had tried player character earlier but then thought it was asking for index value. So I abandoned it without going through with the function.