Enemies attacking new networked player

Hi,

sorry if this is a really noob question but I’m trying to combine the FPS tutorial with the network example.

Basically, I’m trying to have the hostile robots from the FPS tutorial attack players in the game.

I’ve got the hostile robots instantiated with Network.Instantiate but I cant quite figure out how to get them to attack the players.

What should the variable in the AI script (which is from the FPS tutorial)be for Target? In the FPS tutorial it is First Person Controller, so shouldn’t it be Third Person Player? Since every player that enters the game is spawned with that?

Its really easy with the simple tutorials as the players are already placed in the scene but now their not

Hope I could get some help with this :frowning:

Hello!,

A quick idea, (hope is what you are looking at :))

You can spawn characters on the world, and make the enemies (the AI) target the player that is closest to them :slight_smile:

Here is a great theses on decision making (GOAP),i love AI it’s my favorite part of a game.

Click right here !