Panopticon

Unreal Engine 5 | C++ | Blueprints

Overview

My main responsibilities were creating the AI for the spotlight that would patrol the prison and chase the player if it found them, and the player's interactions with objects while in its Human/Shadow forms.

AI

I was in charge of the AI for the spotlight, which would patrol along a set path until it spotted the player, at which point it would follow them until the player could escape its notice. I did this using a state machine with 3 states:

Patrol

This state would contain a series of waypoints, which the AI would move between at a constant speed, briefly pausing each time it reached one.

Follow

If the player entered the vision (determined by a cone collider) of the spotlight, the spotlight would lock onto them, and constantly move to their location move to their location.

Search

If the player exited the spotlight, it would search near the location it last spotted the player for a few seconds, before returning to the Patrol state. To do this, it would choose a random spot in a circle around the player's last seen location, move to it, then choose another random location and repeat until the state ended.

Image description

Human/ Shadow forms

[WIP]