So I want to get the AI and player characters to react to physics. Let’s say there are two attacks: explosives and hammer attacks. In both cases, force should be applied to the characters. Everything’s fine and working as long as the character doesn’t have a Character Movement component. But both do, so the player and the AI can control their movements.
I know that such physical forces and effects don’t affect the player character because it doesn’t have Simulate Physics enabled. If it is enabled, then it can’t be controlled by the player (or at least doesn’t move).
So the question is: what is the best way to achieve this? I think I may have to fake the effect somehow, like move the player in the direction of the hit normal, but how much? That’s why a computer controlled simulation would be best, and not a predetermined direction and force. I’d like to have a realistic effect (so if the player character is away from a weak explosion, it shouldn’t fly through the whole map, obviously).
I’ve tried enabling Simulate Physics when a hit event occurs, but it fell into the ground and other ugly things happened, so it’s not the way to do it.
Any suggestions are welcome.
Thanks