amxx-modding-kit-api-states

Manage entity states with a rule-based framework for AMXX applications.

32|4|Updated Mar 23, 2023
One-click install
npx skills add https://github.com/hedgefog/amxx-modding-kit --skill amxx-modding-kit-api-states
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: amxx-modding-kit-api-states
Source: https://github.com/hedgefog/amxx-modding-kit/tree/main/.agents/skills/amxx-modding-kit/api/states
Command: npx skills add https://github.com/hedgefog/amxx-modding-kit --skill amxx-modding-kit-api-states

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

State machine-based state management for AMXX modding, enabling deterministic transitions, guards, and lifecycle hooks to coordinate complex gameplay states.

Core Features & Use Cases

  • Define states via enums and register a context for per-player or global state
  • Register enter/exit/change and transition hooks to drive visuals, gameplay effects, and logic
  • Support timed transitions and guards to validate state changes
  • Example use cases: health-state management, infection/transformation flows, and per-player state restoration on spawn

Quick Start

Define your enum, register the context in plugin_precache, create and destroy the state manager per player on connect/disconnect, and implement hooks to respond to state changes.

Frequently Asked Questions about amxx-modding-kit-api-states

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build a state machine for AMXX plugins?▼

To build a state machine in AMXX, define your state enums, register a context in plugin_precache, create per-player State_Manager instances, and wire enter, exit, change, and transition hooks to drive gameplay logic.

What is the best way to manage per-player health states in Pawn?▼

Per-player health states are managed by creating and destroying State_Manager instances on connect and disconnect, using transition guards and lifecycle hooks to validate changes and drive visuals or gameplay effects.

Can I use timed transitions and guards for infection flows in AMXX?▼

Yes, you can use timed transitions and guards to validate state changes for infection or transformation flows, ensuring deterministic state handling within the registered state context.

How do I restore player lifecycle states on spawn in AMXX?▼

Player lifecycle state restoration on spawn is handled by the per-player State_Manager instance, which coordinates state transitions and triggers registered enter and exit hooks to reapply the correct state.

Do I need to define enums to use this AMXX state context framework?▼

Yes, defining state enums is required to establish the valid states within the system before registering the context and wiring the transition hooks for your AMXX plugin.