Devlog 2


Enemy AI:
The enemy AI in this game took a fair amount of work to get right, as i had intended a few main features with it. Firstly, they would have a main viewing angle of about 50 degrees in front of them where they could detect the player, as well as a short detection radius around them to prevent the player from following the enemy to avoid them. With this there are two types of detection as highlighted by the below picture.

The first is a suspicion detection. This is when the player is detected in the green area as shown. When detected here, the guard will pause then move to the position where they detected the player. If they detect them again, then the position that they will move to will update. If they then ever detect them in the red zone, then they will alert all nearby guards and proceed to chase the player at an increased speed. If the player manages to escape from this sequence, then the guard will return to the initial detection position and resume patrol. The same thing happens if they are only detected in the green. If the enemy ever catches the player, then the player loses. In general, the usual behavior state for guards is patrol. In this state, they will patrol between designated points as specified. When they reach the end of a patrol path, they will get the next patrol path and wait 1 second before moving to the next point. This gives the player a short notice that the guard is about to change direction.

Files

NorthernSilenceBuild.zip Play in browser
47 days ago

Leave a comment

Log in with itch.io to leave a comment.