Skip to main content

Module phase_type

Module phase_type 

Source
Expand description

PhaseType — turn phases/steps.

Mirrors Java’s PhaseType.java. The core enum lives in forge_foundation::PhaseType; this module re-exports it and adds phase-module-specific helper functions.

Enums§

PhaseType
Turn phases/steps. Mirrors Java PhaseType.

Functions§

get_next
Get the next phase, optionally with reversed phase order (Topsy Turvy). Mirrors Java’s PhaseType.getNext(current, isTopsy).
is_last
Returns true if this is the last phase in the turn. Mirrors Java’s PhaseType.isLast().
parse_range
Parse a range of phases from a comma-separated string. Supports “Phase1->Phase2” range syntax and “Main” alias for Main1+Main2. Mirrors Java’s PhaseType.parseRange().
phase_group_index
Phase group index — maps each phase to its parent group. Mirrors Java’s PHASE_INDEX map.
smart_value_of
Parse a phase type from a string, matching by script name or enum name. Mirrors Java’s PhaseType.smartValueOf().