Can't figure out how to do health and points

Does anyone know how to make my characters health go down when they touch the enemy or how to make the points go up when they collect the gold bars? Thank you!

A link to the game if it’s useful/needed:

There are a couple of examples on the Flowlab Help Page. I am linking two of the simplest ones.

There are many examples in the Help section, but here are a few games you can look at.
Example Help section: