Logo
MINECRAFTBIBLE
Items
Items

All game items

Blocks
Blocks

Building blocks

Mobs
Mobs

Creatures & monsters

Biomes
Biomes

World biomes

Structures
Structures

Generated structures

Recipes
Recipes

Crafting guides

Advancements
Advancements

Achievements

Loot Tables
Loot Tables

Drop rates

Tags
Tags

Item groupings

All Versions
View all data →
Capes
Cape ArchiveNEW

Browse rare Minecon capes, OptiFine capes, and custom capes from players worldwide

Browse

Player Database
Player DatabasePopular

Search any player

Skin Browser
Skin Browser

Browse & download skins

Cape Gallery
Cape GalleryNEW

Minecon & OptiFine capes

Seed Vault
Seed Vault

Curated seeds

Learn

Guides
GuidesNew

Tutorials & tips

Blog
Blog

News & updates

Community

Community Hub
Community HubHub

Posts, discussions & more

All Versions
View community →
Seed Analyzer
Seed Analyzer

World seed analysis

Loot Explorer
Loot Explorer

Drop rates

Crafting Calculator
Crafting Calculator

Material planning

Enchant Calculator
Enchant Calculator

Probability math

Redstone Lab
Redstone Lab

Signal timing

Trading Profit
Trading Profit

Villager ROI

All Versions
View all tools →
Mods
Mods

Browse all mods

Plugins
Plugins

Server plugins

Resource Packs
Resource Packs

Textures & sounds

Shaders
Shaders

Visual enhancements

Datapacks
Datapacks

World logic

Scanner
Mod Intelligence

Scan & analyze any mod

All Versions
View all mods →
Loading...
IntroductionIntroductionVersion HistoryVersion HistoryGuidesGuidesBlog & NewsBlog & News
ItemsItemsBlocksBlocksMobsMobsRecipesRecipesBiomesBiomesStructuresStructuresAdvancementsAdvancementsLoot TablesLoot TablesTagsTags
ModsModsPluginsPluginsResource PacksResource PacksShadersShadersDatapacksDatapacks

MinecraftBible

The Ultimate Wiki

Logo
MINECRAFTBIBLE

The ultimate Minecraft reference. Every item, block, mob, and recipe documented with precision.

Community

  • Skin Browser
  • Cape Gallery
  • Seed Vault
  • Blog
  • Guides

Database

  • Items
  • Blocks
  • Mobs
  • Recipes
  • Biomes
  • Structures

Tools

  • Seed Analyzer
  • Mod Intelligence
  • Crafting Calculator
  • Enchant Calculator

Mods & Packs

  • Mods
  • Plugins
  • Resource Packs
  • Shaders
  • Datapacks

Site & Legal

  • About
  • Authors
  • Editorial Policy
  • Corrections
  • Contact
  • Privacy Policy
  • Terms of Service
  • DMCA
  • Sitemap

© 2026 MinecraftBible. Not affiliated with Mojang or Microsoft.

PrivacyTermsContact
AdvancementInfo
PluginGPL-3.0-only

AdvancementInfo

AdvancementInfo is a lightweight API that allows you to easily access and manage Minecraft advancements across different server implementations.

113
Downloads
0
Followers
1 years ago
Updated
📦
1
Versions
librarymanagementoptimizationbukkitfoliapaperpurpurspigot
Download Latestv1.0View on Modrinth

📖About AdvancementInfo

Discord

AdvancementInfo

AdvancementInfo API is a specialized library designed to simplify the retrieval and manipulation of Minecraft advancements in your plugins. It abstracts the underlying complexity of accessing advancement data—such as titles, descriptions, icons, criteria, rewards, and display settings—by providing a uniform interface and several concrete implementations that use reflection to work with Bukkit, Paper, and other server internals.


Overview

The API is centered around the AdvancementInfo interface, which defines methods for obtaining detailed information about an advancement. Implementations like BukkitInfoImpl, ReflectInfoImpl, and PaperInfoImpl extract data from a Bukkit Advancement object using reflection and provide:

  • Advancement Details: Title, description, icon, and display options.
  • Display Coordinates: X and Y positions for advancement display.
  • Visual Frame: The advancement’s frame type (e.g., TASK, GOAL, CHALLENGE).
  • Criteria and Requirements: Data that defines how the advancement is achieved.
  • Rewards: Information on the rewards granted upon completion.

Key Features

  • Unified Interface:
    The AdvancementInfo interface provides a common API to access advancement data, regardless of the underlying implementation.

  • Multiple Implementations:
    Different implementations adapt to various server versions and environments:

    • BukkitInfoImpl: Uses Bukkit’s standard advancement display methods.
    • ReflectInfoImpl: Leverages reflection to extract advanced details.
    • PaperInfoImpl: Tailored for Paper servers, using Paper-specific methods and the LegacyComponentSerializer for text conversion.
  • Version Compatibility:
    The API intelligently selects the correct implementation based on the server’s Minecraft version, ensuring broad compatibility.

  • Reflection Based:
    The use of reflection enables the API to access internal fields and methods of advancements, providing rich information even when not directly exposed by the Bukkit API.


Usage Example

Below is an example of how to use the AdvancementInfo API to retrieve and display information about a Minecraft advancement.

Example: Retrieving Advancement Information

package com.example.myplugin;

import me.croabeast.advancement.AdvancementInfo;
import org.bukkit.Bukkit;
import org.bukkit.advancement.Advancement;
import org.bukkit.plugin.java.JavaPlugin;

public class MyPlugin extends JavaPlugin {

    @Override
    public void onEnable() {
        // Retrieve a Bukkit advancement by its key
        Advancement advancement = Bukkit.getAdvancement(new org.bukkit.NamespacedKey(this, "example_advancement"));

        if (advancement != null) {
            // Create an AdvancementInfo instance from the advancement using the static factory method
            AdvancementInfo info = AdvancementInfo.create(advancement);

            if (info != null) {
                // Print advancement details to the console
                getLogger().info("Advancement Title: " + info.getTitle());
                getLogger().info("Description: " + info.getDescription());

                // Retrieve formatted description array with a max line length of 40 characters
                String[] lines = info.getDescriptionArray(40);
                for (String line : lines) {
                    getLogger().info("Line: " + line);
                }
            } else {
                getLogger().warning("Failed to retrieve advancement info.");
            }
        } else {
            getLogger().warning("Advancement not found.");
        }
    }
}

Explanation

  • Retrieving an Advancement:
    The example obtains a Bukkit Advancement via its key.

  • Using the Factory Method:
    AdvancementInfo.from(advancement) returns an appropriate implementation (Bukkit, Paper, or Reflect) based on the server version.

  • Accessing Advancement Data:
    Once the AdvancementInfo instance is obtained, you can access its title, description, criteria, rewards, and display settings.

  • Formatting Description:
    The example demonstrates how to split the description into an array of lines, ensuring that no line exceeds a specified length.


Maven / Gradle Installation

To include AdvancementInfo to the project, add the following repository and dependency to your build configuration. Replace ${version} with the desired version tag.

Maven

Add the repository and dependency to your pom.xml:

<repositories>
    <repository>
        <id>croabeast-repo</id>
        <url>https://croabeast.github.io/repo/</url>
    </repository>
</repositories>

<dependencies>
    <dependency>
        <groupId>me.croabeast</groupId>
        <artifactId>AdvancementInfo</artifactId>
        <version>${version}</version>
        <scope>compile</scope>
    </dependency>
</dependencies>

Gradle

Add the repository and dependency to your build.gradle:

repositories {
    maven {
        url "https://croabeast.github.io/repo/"
    }
}

dependencies {
    implementation "me.croabeast:AdvancementInfo:${version}"
}

Replace ${version} with the appropriate module version.


Conclusion

The AdvancementInfo API provides a powerful, unified approach to accessing and processing Minecraft advancements. It abstracts away the complexities of reflection and server version differences, allowing you to focus on using the advancement data in your plugin. Whether you are building custom advancement displays, integrating advancement data into your plugin logic, or simply logging advancement details, this API makes it easier to work with advancements in a consistent manner.

Happy coding!
— CroaBeast

👥 Team & Contributors

CroaBeast
CroaBeastOwner

⚙️ Compatibility

Environment
🖥️ Server-side
Loaders
bukkitfoliapaperpurpurspigot
Minecraft Versions
1.121.12.11.12.21.131.13.11.13.21.141.14.1+40 more

🔗 Links

Modrinth Page