I'm making a zelda, top down, 8 direction movement, type game.
I want the enemy to be knocked back when hit. And if possible, at the same angle that they were hit at.
EXAMPLE VIDEO:
You can see within the first 15 seconds, how whenever The Player hits an enemy with his sword they are knocked back a certain distance at a specific angle. ALSO when The player is hit, he is knocked back in the same manner.
I messed around using physics behavior and didn't have much luck. I also tried doing bullet movement and only turning on the bullet movement when struck for 0.3 sec at an angle of the sword swing. But I didn't get very far with that either.
Any help would be greatly appreciated! Thank you for your time!