The per-package pages in this section are generated from the Javadoc in the source code with ./gradlew apiReference. Each page lists the signatures, descriptions, parameters, return values and exceptions of every public type and method in that package.
- Descriptions are in English, exactly as written in the code.
- Every API is at the
PREVIEW level. It can change between versions.
- Every type and method shows the release that added it (Since).
- Do not edit the generated pages by hand. Change the Javadoc in the source, then generate the pages again.
All functions lists every constructor and method in one table, and Additions by release lists what each release added.
For usage and examples by area, see Native API. For stability levels, see API stability.
Package list
All packages are under dev.polymodloader.api. The names below are the part after that. They are grouped the same way as the sidebar.
Basics
| Package | Contents |
|---|
| stability | The stability annotation @ApiStability and the levels in StabilityLevel |
| runtime | GameSide, the kind of Minecraft process Poly Mod Loader is running in |
| lifecycle | The mod entrypoints (CommonModInitializer, ClientModInitializer, DedicatedServerModInitializer) and ModContext |
Content
| Package | Contents |
|---|
| content | Content declaration (ContentRegistrar), creative tabs, sounds, entity data keys, advancement triggers |
| content.block | Block definitions, behavior, shapes, sounds |
| content.block.entity | Block entity definitions and ticking, slot layout menus (MenuLayout) |
| content.block.state | Block state properties (BlockProperty) and state snapshots (BlockStateView) |
| content.effect | Status effect definitions and behavior |
| content.entity | Mob and projectile definitions, AI goals, movement and riding, natural spawning |
| content.entity.model | Mob box models, part animations, keyframe animations |
| content.item | Item and food definitions, item data components |
| content.particle | Particle type definitions |
| content.rule | Game rule keys and categories |
Events
| Package | Contents |
|---|
| event | Event keys (EventKey) and listener registration (EventRegistry) |
| event.block | Block events (break) |
| event.entity | Living entity events (allow and modify damage, death) |
| event.player | Player join events (join check, join, leave) |
| event.server | Server lifecycle events and ServerView |
| event.world | Dimension events (prepare, chunk load and unload) |
World and entities
| Package | Contents |
|---|
| world | Block positions and directions, WorldView, world storage (StoredData) |
| worldgen | Code biomes, terrain generators, code placed features, noise functions, code structures |
| entity | Views of entities, living entities, mobs, and players, and damage information |
| inventory | Inventory views and item stacks (snapshots, live stack references) |
Server and data
| Package | Contents |
|---|
| command | Server command trees, argument types, execution context |
| permission | Permission nodes and permission providers |
| network | Payload channels and codecs, exchanges during the join preparation phase |
| data | Data trees saved with the world (DataTree) and migrations |
| resource | Resource IDs and data and asset reload listeners |
Client
| Package | Contents |
|---|
| client | Key bindings, HUD, mod screens, world and block entity rendering, shader pipelines, dynamic textures, client events |
| Package | Contents |
|---|
| system | The contract for replaceable systems (SystemId, SystemProvider, SystemLookup) |
| system.brand | The poly:game_brand system (GameBrandSystem) |
| devtools.gametest | Game test registration, running tests, test areas (TestArea) |
Page generation
The repository's tools:api-reference module builds the package pages. When you run ./gradlew apiReference at the repository root, it reads the sources of the public API modules (poly-runtime-api, poly-system-api, poly-event-api, poly-game-api, poly-lifecycle-api) and writes one page per package into this folder (site/docs/api-reference/). Only this page (index.md) is written by hand.