Possession and Combat System
The possession system is built around a Possessable Interface and a Possessable base class, allowing the player to seamlessly take control of any compatible pawn type — including enemies, NPCs, or future companions. When a pawn is possessed, its AIController and Behavior Tree are deactivated, and input is redirected through the player’s controller, which dynamically maps controls based on the possessed pawn’s type and abilities. The system was designed for scalability, enabling different types of possession without rewriting core control logic.
The combat mechanics are implemented directly within each character class, with player-exclusive skills and melee logic separated from the Sigil Component, a modular system that handles the crafting and casting of magic spells. The architecture supports contextual interactions tied to possessed characters — for instance, lighting or shooting explosive barrels, or breaking barriers with melee attacks.
The framework also supports an evocable companion system. Currently, the companion can be summoned into the world and commanded to move, attack, or be dismissed, and is fully compatible with the possession system to enable future playable or controllable summons.
Possession and team system in action: the player possesses an enemy with a gun and engages another, triggering group awareness through the Combat Manager.
AI and Team System
The AI system is built on a custom perception component and custom team logic, extending Unreal’s perception framework to enable selective team-based awareness. Enemies perceive and react to events such as combat or player possession depending on their assigned team ID. Group-level events — like alert states — are broadcast via a Combat Manager that uses event dispatchers to synchronize behavior across multiple agents.
AI decision-making uses Unreal’s Environment Query System (EQS) combined with C++ Behavior Tree tasks, allowing precise control over state transitions and situational awareness. AI agents cycle through multiple states (Passive, Investigating, Seeking, Attacking, Frozen, etc.), with state logic varying dynamically when agents belong to a team group.
Development Challenges
Developing Zero required designing a modular architecture that could handle dynamic control switching between multiple pawn types while maintaining consistent gameplay logic. The possession framework was one of the most complex parts of the project — it demanded precise management of AIController state, input redirection, and seamless transitions between autonomous and player-controlled behavior.
Building a custom perception system and team-based AI architecture also presented unique challenges. Creating flexible yet performant communication between agents led to the implementation of a Combat Manager that uses event dispatchers to broadcast group awareness and combat states in real time.
Integrating animation and locomotion required balancing responsiveness and visual fidelity. The system combines motion matching and state machine logic, supported by curves and animation notifies for aiming, input buffering, and hit detection. This hybrid approach provided the control needed for fast iteration while keeping animation transitions smooth and data-driven.
Finally, the framework for the evocable companion extended the same architecture used for possession, allowing future summonable entities to share input logic and perception behavior with minimal additional code.
Lessons Learned
Early modular design and component-based logic proved essential for scalability and iteration speed. Interfaces and data assets allowed systems like AI, input, and progression to stay decoupled and reusable.
The possession framework underlined the value of interface-driven architecture, enabling future playable entities (e.g., companions) to share input and control logic seamlessly.
Developing the custom perception system emphasized data-driven AI design, combining EQS and C++ tasks for both designer flexibility and code precision.
A hybrid motion system—mixing motion matching and state machines—balanced control responsiveness with animation fidelity, while curves and notifies refined timing and feedback.
Building on existing frameworks for the companion system reinforced the importance of extensible, maintainable code for future scalability.