Enemy Entities

This section covers the implementation of enemy entities in Ascend from Nine Mountains. Learn how to transform your enemy concepts into working combat encounters using the game’s stance and rotation systems.

Overview

Enemy entities in AFNM represent all hostile combatants that players encounter throughout their cultivation journey. This documentation focuses on helping you transform your enemy concepts into working implementations using the game’s stance and rotation systems.

Core Systems

Entity Structure

Every enemy follows a consistent structure defined by the EnemyEntity interface, which includes combat stats, stance rotations, and conditional behaviors.

Stance System

Enemies cycle through stances containing technique sequences, using rotation rules and conditional overrides to create dynamic combat patterns.

Implementation Focus

The documentation emphasizes practical implementation details, showing how to build setup rounds, phase transitions, and adaptive behaviors.

Quick Navigation

Key Implementation Concepts

Rotation Overrides

Use rotationOverrides with repeatable: false to create setup rounds and one-time behaviors.

Conditional Logic

Stance switches based on health, round count, buffs, or other combat state using mathematical expressions.

Pattern Building

Combine cyclic rotations, random selections, and conditional overrides to create complex behaviors.

Enemy Registration

Enemies are not directly registered through the ModAPI. Instead, they are integrated into the game through events and locations:

Integration Methods

  • Event Combat Steps: Use combat event steps to trigger enemy encounters
  • Location Enemies: Add enemies to locations as exploration encounters or specific combat events
  • Quest Integration: Incorporate enemies into quest objectives and storylines

See the Events documentation for combat step implementation and Locations for enemy placement strategies.

Getting Started

To implement your enemy concept:

  1. Review the Enemy Structure for the interface definition
  2. Use the Design Guide to translate your concept into stance rotations
  3. Study Behavior Patterns for advanced conditional logic
  4. Check Examples for complete implementations
  5. Integrate your enemy through Events or location encounters

Table of contents