Score counter increments via widget

Hey guys!

So I’ve made a game where you can throw potions at targets to collect points. I have the blueprints correct in making it increment via a string but now I’d like to transfer it preferably via a widget blueprint which I’ve already used for my HUD.

There are 3 different targets which the player can hit for either 1, 2 or 3 points but I can’t seem to get it to cast to the HUD blueprints or the widget blueprints and I’m a little stuck :frowning:

All the tutorials I’ve found are from last year which doesn’t help either.

Thanks in advance :slight_smile:

It is quite tough to link systems set up in the level blueprint to widgets and things, the best thing to do would probably to create a new actor blueprint for each of your 1, 2, 3 point targets. Then you can use Cast To nodes to reference those blueprints in your HUD widget.

(This is probably a better way to save your targets anyways as you only have to set it up once and then duplicate it around your level)

Hi Steve, sorry I took so long to reply. Ok so I’ve added a test blueprint for one of my 2 pointer target but I’m new to using widgets and I’m stuck.

I’ve added a points variable to the asset blueprint and cast it to the HUD widget I created but from there on out I have no clue what I’m linking up. Originally I thought I could link the points variable from the asse blueprint but I can’t since it complains about first person character casting.

I have fixed it! I ended up creating a variable in the first person character node and cast it to the target and the widget. The only trouble now is getting my overlaps to work so that I can throw objects at the targets to count points,