Score System
Open 3rd person BP → Add variable, name as Score
→ change to Integer
R click in Content Browser → User Interface → Widgert Blueprint → User Widget (name as Socre)
Open the widget BP → add Text → Create Binding (a new event graph is opened)
Click on the event graph, create the nodes as below (promote to variable → will create a SET node)
Go back o Get Text 0 node →
Let score to change (e.g. a character steps on a cube, score changes)
R click on Content Broswer → Create a BP class → Actor, name as Cube
Add a Cube, change collision to overlap all dynamic
create following event graph in the cube BP
To connect the score system and display in the game:
Create the following in 3rd character BP
Emissive Material nodes graph:
Engulf the point/actor when charater steps on:
In 3rh person BP, create a tag, name as Player
Open actor (case here is emissive sphere), set nodes as follow on Other Actor command on Event Begin node:
Go to 3rd person BP, create Float variable, name as Points
Go to PlayerUI BP, create Text for Points and 00
Select 00 → Details → Content, Create new binding, name as PlayerPoints
set as below (type Get Point for target point node):
Show point socre after engulf/destory sphere actor:
Open Sphere BP, modify previous BP as follow ahead Destroy actor node: