- Home /
How do I make my AI attack in the FPS tutorial?
I've been working with the FPS tutorial on Unity, and my game is looking alright. I can move, I can shoot, blah blah blah. I even made some AI (the robots). They can move around within their waypoints and chase me; and when I shoot them they collapse to the ground. However, I cannot make them attack me with their weapons. So far I've tried to tactic of:
-Creating an empty object called robot gun -giving that object a machine-gun script (same one that works for the player) -dragging that object onto the robot ai
Still, none of this works. I'm probably (or obviously, since it isn't working) doing something wrong, so please give me a helping hand.
Ok, the robots chase you - but do they play the attack animation when you come near to them? Or they just stop stupidly in idle mode when close to you?
aldonaletto, the play the attack animation, but no damage is done.
Your answer
Follow this Question
Related Questions
Need Help With My AI Script 1 Answer
Problem with enemy AI 1 Answer
Melee range AI 1 Answer
Creating basic enemy animation and attacking 4 Answers
Enemy AI problems 2 Answers