I used the same method i used then which of duplicating the main character so that the ai would inherit all of it s movement capabilities.
After doing this i realised that it did not have the same effect as it did in my previous game because of the way the top down level had been defaulted instead of creating an AI i spawned as the AI.
So i had to the create a new blueprint class but found that instead of creating an actor i should use a character blueprint so that I wouldn't spawn as the AI.
I gave the mesh a cube component so that i could obviously see it move and follow MyChar.
I gave the character pawn sensing abilities so that he could sense a characters movement and move towards the player.I realised that we would want our AI to look more human like so gave him the third person mesh and animation so that it wouldn't just be a box following the player.
I watched a tutorial on youtube which starts with creating an AI controller using the AI controller blueprint.
Then i took apart my event graph before and added a custom event and made it so that the AI would move to a random location on begin play then after one second has passed he would move again.
I created a chase custom event and replaced roam with it so that when the player spawns the AI will chase him and on contact destroy himself and explode.
So after creating a roam event and chase event we decided that in our game we wanted different AIs to do different things so i created a blueprint Enumeration which allows me to add an option to change the AI blueprints through defaults in game UE4. This also aloud me to go into the blueprints and create it so that the AIs can have two options for exmple we wanted them to have a patrol then if they failed to reach the player would return back to their patrol. This was achieved because i set it up in the blueprints so that the AI can switch between.
I






























