how to make player attack an enemy

can anyone show me how to make my character attack an enemy and deal a set amount of damage? the game link is here: https://flowlab.io/html5/bin/1305036 ( don’t mind the sprite, it’s just a placeholder.)

I have the same question so if you find out or someone tells you please inform me!

There are a few examples you can try in the Flowlabs help section.
Example lists:
http://flowlab.io/examples

Sword attack 2:
http://flowlab.io/game/play/835804