< Return to Academics
Survival AI
Project Size
~40 hours
Tools & Languages
C++
Topics
Gameplay Programming
AI & Navigation
Assignment
Using the seen topics, we were tasked to write the best AI for an agent in a survival game scenario. The AI is only given information about what is inside the vision cone. By gathering items it can stay alive and defend itself, while trying to achieve the best highscore.
This was one of my favorite projects, as it was essentially combining the interesting topics with a game. It was also a great learning experience to further understand how to use behavior trees and blackboards in combination with tasks to drive an AI.
Project Features
- A* Pathfinding
- Behavior Tree & Blackboard
- Influence Maps
- C++ Algortihms
Project Summary
Navigation using Influence Map
To navigate the world, I split up the map into a grid to be used as influence map.
Each tile in the grid contains:
- Time since last visit
- Items inside
AI Logic
Using a Behavior Tree, the AI can follow a list of priorities which it filters through based on the information in the blackboard. Blackboard information is updated each frame using the data available in the vision range, as well as some data set through different executed tasks.
The behavior tree is built up from three possible nodes:
- Selectors
- Sequences
- Conditionals