It’s a long process but if you’re willing to learn…
Controlling animations through c++:
Use trace (raycasts) to see where the walls are, so your character knows if there is cover in front of him or not: