Repository navigation
Architecture
unknown edited this page Nov 14, 2026
·
1 revision
ManhuntStar is one game written once, in a platform-independent core, and run by three thin platforms: the Paper plugin and the Fabric and NeoForge mods. The plugin and the mods play the same because they run the same code.
┌──────────────────────────────┐
│ core │ no Paper, no Minecraft
│ AI, hunt rules, config, UI │
└──────────────┬───────────────┘
platform interfaces │ (dev.manhuntstar.platform, .host)
┌────────────────────────┼─────────────────────────┐
│ │ │
┌────────┴────────┐ ┌─────────┴─────────┐ │
│ paper │ │ mod-common │ plain Minecraft (NeoForm) + mixins
│ Paper plugin │ └─────────┬─────────┘
└─────────────────┘ ┌──────┴──────┐
┌───┴────┐ ┌────┴─────┐
│ fabric │ │ neoforge │ loader entry points
└────────┘ └──────────┘
| Module | What it is | Depends on |
|---|---|---|
core |
Everything that doesn't depend on a platform: the bots' AI, pathfinding, combat, mobility, tactics, the hunt rules, settings, languages, file upgrades, the command tree (Brigadier), the menus, storage, skins, update check, statistics. | Adventure, SnakeYAML, Gson, Brigadier (compile only) |
paper |
The Paper plugin: Bukkit/Paper implementations of the platform interfaces, listeners, the command, TAB list, glow, death messages, mob goals, FastStats, the public API. Shadow jar with core inside. | core, Paper API |
mod-common |
The mods' shared code, using only Minecraft itself: implementations of the platform interfaces, the mixins that feed the game's events to core, permissions, statistics. | core, Minecraft (NeoForm), Mixin |
fabric |
The Fabric entry point (server events, commands, permissions API). Compiles mod-common's sources with Fabric's Minecraft. | mod-common, Fabric API |
neoforge |
The NeoForge entry point (events, commands, permission node). Compiles mod-common's sources with NeoForge's Minecraft. | mod-common, NeoForge |
core has no Paper and no Minecraft on its classpath: anything platform-specific put there doesn't compile. That's what keeps the plugin and the mods identical.
-
dev.manhuntstar.platform: the game as core sees it:GameServer,GameWorld,GameEntity,GameLiving,GamePlayer,GameMob,BotBody(a vanilla Mannequin),GameItem,BlockType,ItemType,EntityKind,ConfigNode,YamlFiles... Each platform implements them (Paper*classes inpaper,Mod*classes inmod-common). -
dev.manhuntstar.host: what the platform provides to core:ManhuntPlatform(server, YAML, logger, data folder, resources, lifecycle hooks) andPlatformServices(TAB list, glow, death messages, path debug, events, aim diagnostics, menu screens). -
ManhuntCoreis ManhuntStar itself. A platform creates it with itsManhuntPlatform, then callsenable(),tick()every server tick anddisable().ManhuntHostis what the bots see of it.
- Migrates a 1.5.x
config.ymlandmessages.ymlif present. - Creates or upgrades
config.yml(ConfigUpgrade), carrying over a bStats opt-out. - Installs or upgrades the language files (
Messages.install). - Loads the settings and texts.
- Starts the path service, skins, storage, bot manager, mob targeting, update checker, platform services and menus.
- Restores the bots, groups and the hunt from
bots.yml.
| Package | What's there |
|---|---|
bot |
Bot, BotManager (creation, ticking, respawn, groups, silent deaths), Progression (phases), BotDifficulty, BotInventory, Hunger, MobTargeting, Modes (option enums) |
bot.ai |
Brain (target choice and decisions), Navigator (following A* paths), Towering, IdleBehavior (waiting in the ring), Personality
|
bot.combat |
Combat: melee, shield, bow, crossbow, trident, humanization |
bot.mobility |
BoatRoutine, HorseRoutine, ElytraFlight, MlgClutch, PortalEntrance
|
bot.motor |
Motor: a player's movement input applied to the Mannequin |
bot.world |
Mining, TemporaryBlocks, PlayerBlockTracker
|
bot.survival, bot.ability
|
Eating, golden apples, fire; ender pearls |
pathfinding |
AStar, PathService (thread pool), chunk snapshots and block costs |
tactics |
TacticsManager (TNT ambush, bow burst, firework crossbow), CaveAmbush
|
manhunt |
RingService, HuntPolicy (who's hunted, late joiners), PauseService
|
command |
ManhuntCommand: the whole /manhunt tree in Brigadier, for every platform |
gui |
MenuManager: the chest menus |
config |
Settings, Setting, Messages, YAML, and upgrade (file versions and steps) |
persistence |
BotStorage (bots.yml) |
skin, update, metrics
|
Skins, update check, FastStats statistics and error reports |
Everything that touches the game runs on the server thread. Off it:
- the A* searches (
PathService), on copies of the chunks taken on the server thread; - HTTP calls (skins, update check);
- writing
bots.yml(the text is built on the server thread, written on another, then swapped in); - FastStats, which reads copies of the values that core makes once a minute.
-
Paper: one jar. It's compiled against the oldest supported Paper API (
paper-api-min), andPaperCompatlooks up newer calls by reflection once.compileAgainstLatestchecks the code against the newest API. -
Mods: one jar per Minecraft version. Each module's
build.gradle.ktsis the build of one version, and Gradle creates a project per version (:fabric:26.3,:mod-common:26.2...). What changed between Minecraft versions goes inmod-common/versions/<version>/src/(for exampleMinecraftCompat). Since Minecraft is no longer obfuscated (26.1+), Fabric and NeoForge use the same names and share mod-common.
-
core/src/test: settings, file upgrades, languages (LanguageFilesTestchecks every bundled language hasen.yml's keys and placeholders), hunt policy, ring exit, pathfinding, ballistics, metrics, update checker. -
core/src/testFixtures: a fake server and world (FakeServer,FakeWorld,FakeItem) andYamlFilesContract, a contract every platform's YAML implementation runs (BukkitYamlFilesTeston Paper,ModYamlFilesTeston the mods). -
paper/src/test:PaperCompatandBotStorage.
Getting started
Playing
Server owners
Developers
Download