Quantcast
Viewing latest article 15
Browse Latest Browse All 90

Answer by doomprodigy

I am unsure as to how the enemy in the FPS Tutorial is working but in the AI, I programmed for my FPS my enemy used a raycast for shooting, simply aim a raycast at the diagonal angle that would hit you if you are below him. ( I am fairly sure that this is how the AI in FPS Tut works with its firing ). This would mean two raycasts. Currently there is probably one aiming straight ahead from the enemys body to hit you when it looks at you straight on and when it hits, it calls the damage or shooting function. simply duplicate this change a few things such as the raycasts direction and it should work. Turn Gizmos on to see when the raycast is currently going/aiming.


Viewing latest article 15
Browse Latest Browse All 90

Trending Articles