VR Fighting Game help

Hey,
I am trying to make a VR fighting game like gorn, Creed etc. I tried using an animation based system but it just feels off now I am trying to make a physics based system which will use the skeleton’s physics.

What I am currently doing is I start simulating physics after the motion controller begins to overlap with the ai actor.

The problem: The enemy AI keeps on falling.
I can hit it on the ground but it just falls in a ragdoll like fashion after the first punch.

Question: How can I make it so the enemy AI keeps on standing after the first punch? (How can I simulate physics and have the AI stand on its feet)

Thanks in advance!

Hi

This is not an exact solution, however it will give u an idea. Create a variable for health and set a value for e.g., 100.

On one punch you reduce a value of 10. Until it becomes zero, disable the gravity of the enemy, so that it will not fall. Make a condition that if the health is 0, then enable the gravity of the enemy and add a fall animation, so that it looks natural while falling.

You can find the gravity option under physics. Hope this helps !

Hey thank you for the answer :slight_smile: I have implemented your solution and it works great with one problem. The character is kind of floating in place when gravity is disabled. Is there any way I can make it so its a little more grounded?

Hi

You can work on the Physics tab, See the link below,

You can disable Simulate Physics so that it will not affect by gravity. Or you can try freezing the position or rotation on a particular axis.

Cheers !

thanks for your answers! I ended up using the physical animation component (Pretty buggy atm) Here’s a great tutorial for anyone trying to do it in their own game: Lets Create Physical Animations - Blueprints #15 [Unreal Engine 4 Tutorial] - YouTube