This document describes the original 1.19.4 source code architecture located in ai_reference/reaper-1.19.4/.
NOTE: This is for reference when understanding the original implementation - DO NOT copy these patterns directly into the new 1.21.11 implementation. Use modern Meteor addon patterns instead.
ai_reference/reaper-1.19.4/src/main/java/me/ghosttypes/reaper/Reaper.java - Main addon class extending MeteorAddon
- Defines addon metadata, version, and folder structure
- Implements
onInitialize()to load modules and services - Implements
onRegisterCategories()to register custom module categories
- Centralized module registration and loading
- Creates three custom categories: "Reaper", "Reaper Misc", "Windows"
- Load methods:
loadR()(combat),loadM()(misc/chat/render),loadW()(windows),loadH()(HUD) - Uses
addModules()helper to register modules with Meteor's module system
modules/
├── chat/ - Chat-related modules (AutoEZ, PopCounter, etc.)
├── combat/ - PvP combat modules (AnchorGod, BedGod, Surround, etc.)
├── hud/ - HUD elements (CustomImage, Notifications, SpotifyHud)
├── misc/ - Miscellaneous utilities (RPC, PacketFly, etc.)
│ └── elytrabot/ - Complex pathfinding system with A* implementation
└── render/ - Rendering modules (ExternalHUD, HoleESP, etc.)
Most modules extend ReaperModule which provides common functionality (check util/misc/ReaperModule.java).
- Initializes background services at addon startup
- Thread pool manager:
TL.java(Thread Loader) - Services:
GlobalManager- Event subscription and global stateResourceLoaderService- Asset downloading and managementNotificationManager- Notification systemSpotifyService- Spotify integration (currently disabled)WellbeingService- (currently disabled)
util/
├── combat/ - Combat helpers (CityUtils)
├── misc/ - General utilities (MathUtil, MessageUtil, ModuleHelper)
├── network/ - Network utilities (MultipartUtility, PacketManager)
├── os/ - OS-specific operations (FileHelper, OSUtil)
├── player/ - Player interactions (Interactions, Stats)
├── render/ - Rendering helpers (ExternalWindow, Renderers)
├── services/ - Service implementations (see Service System above)
└── world/ - World interaction (BlockHelper, CombatHelper, RotationHelper)
BlockHelper/BlockBuilder- Block placement abstractionsCombatHelper/DamageCalculator- Combat calculationsRotationHelper- Server-side rotation managementPlayerHelper- Player state queriesExternalWindow- Native window rendering system
Mixins are defined in reaper.mixins.json:
MinecraftClientMixin- Core client hooksBootstrap- Early initializationmeteor.FakePlayerMixin- Meteor integration for fake playersmeteor.MeteorBootstrap- Meteor startup hooksmeteor.NotificationProxy- Notification system integration
HeldItemRendererAccessor- Access private fields in held item rendererHeldItemRendererMixin- Modify held item rendering behavior
Custom events in events/:
DeathEvent- Player death detectionInteractEvent- Interaction trackingUpdateHeldItemEvent- Item switch detectionCancellablePlayerMoveEvent- Movement control (originally used by ElytraBot - see DO_NOT_PORT.md)
See DO_NOT_PORT.md - Replaced by meteor-client-webgui
The original addon included a sophisticated external window system:
ExternalWindow.java- Base window implementation using native renderingExternalRenderers.java- Rendering pipeline for external windows- Modules:
ExternalHUD,ExternalFeed,ExternalNotifications
This allowed rendering game information in separate OS windows outside Minecraft.
See DO_NOT_PORT.md - Already ported to meteor-rejects-v2
- Threaded pathfinding system with A* algorithm
- Multiple flight modes (ElytraFly, PacketFly)
- Custom movement events and utilities
- Timer and direction utilities for precise movement
These patterns existed in the original code - understand them for reference, but implement using modern patterns:
- Folder structure: Original created
Reaper.FOLDER,Reaper.RECORDINGS,Reaper.ASSETS,Reaper.USER_ASSETSon initialization - Thread management: Used custom
TL.javathread pool for async operations - Service system: Custom
SL.javaservice loader initialized background services - Discord RPC: Had auto-enablement logic
- Services: Spotify and Wellbeing services were disabled in original
- External windows: Required native OS support for external rendering
- Module loader: Non-standard
ML.javamodule loader - DO NOT replicate this pattern
Reaper.FOLDER- Main addon folder in Meteor directoryReaper.RECORDINGS- Recordings subfolderReaper.ASSETS- Asset storageReaper.USER_ASSETS- User-customizable assets
Reaper.HUD_GROUP - Dedicated HUD category for addon HUD elements
Last Updated: 2025-12-26