Welcome to City Infinite Dev Log #2. First things first, for this Dev Log I have done some basic enemy AI and a music track for my game.
Enemy AI
Starting with the Enemy AI, I had made some enemy AI which is just a navMesh Agent. The agent is programmed to hunt down the player if the player is within range, to represent the enemy I made a B E A N that is red it's just like the player but red to show that it is an enemy.
When the enemy is not in range of the player, it goes around the world and just roams around extremely Irresponsibly and aimless, not looking for the player, just like I programmed it to be.
Dev Info
I generated random x and z coordinates for the enemy to loiter to instead of using
Random.insideUnitCircle
as
agent.SetDestination
requires a valid Y position to work properly. I learnt this the hard way (2 days of debugging).
Music
I made music.
https://drive.google.com/file/d/1bhNBtXVxfkTGmEEN28ycs1znUECpfRTA/view?usp=drivesdk
Music is supposed to be calm and relaxing, so if you have any suggestions to make it better comments down below.
And that's it for this Dev Log!
If you liked this Dev Log give it a like and follow this blog to get updated when I post my next Dev Log, I try to post every week