Game Plugin
The Game
plugin extends the base Game
class with game-specific functionality.
Plugin Package Structure
A Game plugin package contains:
Plugin definition file
Game-specific Game subclass
Game-specific GameAPI subclass
Game sprites
Game Subclass Implementation
Most critical functionality comes from the parent Game class. The subclass provides game-specific configuration.
Required Components
Screen Regions
Define regions of interest:
OCR Presets
Configure text recognition settings:
GameAPI Implementation
The GameAPI subclass contains reusable game-specific functions in files/api/api.py
Function Categories
UI operations
Game state management
Sprite detection
Data processing
Namespacing
Game Sprites
Directory Structure
Place sprites in files/data/sprites
using PNG format.
Naming Convention
Examples: * `sprite_npc_priest_0.png` â SPRITE_NPC_PRIEST * `sprite_npc_priest_1.png` â Additional frame for SPRITE_NPC_PRIEST
Last updated