decide on your combo timeout i.e. 1 or 2 seconds or whatever: global variable: combotimeout = 2
make another global variable for stepping the combo up each time: combostep = 0
add your conditions for the combo starting , such as weapon collision with enemy. increase the combostep by 1 for each collision.
your sprite can optionally change animations based on the combostep variable. for testing/ visual cue you can create a text box with fade behaviour with the combostep value in the text field at the enemy x,y so you can see the combo amount increase with each hit.
each second, subtract one from combotimer, and if combotimer = 0, reset combostep to = 0
so your attack button will trigger all of this because it is based on the collision between your weapon and the enemy.
consider also a condition that tests if your sprite is attacking so that merely touching the enemy with your weapon without attacking doesn't register a hit.