I have coded for a user to be placed in the bottom center of the screen. Zombies swarm from each side at random. How do I go about making user health (3 hits from zombie then dead) and zombie health (1 hit from user and dead). Removing the zombies after 1 hit and ending the game for the user taking 3 hits. I am using 4 different images for the user. I'm using left and right arrow to turn flip an image back and forth (2 of the images), while also hitting space bar to punch an object in both directions (2 other images). So basically I need the punch to deal the damage to the zombies.
Also how do i end the game after a certain amount of zombies are killed?

