Scaffold McRPG Skill

VerifiedSafe

Step-by-step guide to create a new McRPG skill, including config files, code, and YAML resources.

Sby Skills Guide Bot
DevelopmentAdvanced
7/28/2026
Claude CodeCursorCodex
#minecraft#java#scaffolding#plugin-development#configuration

Recommended for

Automated summary

Scaffolds a new McRPG skill end-to-end by creating the config, YAML, and level component files based on the Swords reference implementation.

Strengths

  • Follows an explicit ordered workflow from input gathering to file creation.
  • Uses the Swords implementation as a canonical reference for classes and components.
  • Provides reusable Java and YAML templates for configuration and the level component.
  • Includes registration in the FileType enum and creation of the YAML resource.

Limitations

  • The supplied content is truncated at the end of the level component, so final wiring and tests are not shown.
  • Assumes repository-specific package structure, internal APIs, and conventions.
  • Does not specify build, test, or validation commands after generation.
When to use it

Use when adding a new XP-granting skill to McRPG and you need a consistent scaffold for configuration, YAML, and the level component.

When not to use it

Do not use for non-McRPG projects or when modifying an existing skill without scaffolding a new one.

Security analysis

Safe
Quality score80/100

The skill is a pure code-scaffolding guide for a Minecraft plugin: it creates Java classes and YAML resources, edits enums/registries, and verifies with Gradle builds. There are no destructive commands, no network calls, no credential/secret handling, no obfuscated payloads, and no attempts to override agent safety or role. The only execution-adjacent step is the ordinary Gradle compile/test loop, which is legitimate developer workflow.

Findings
  • •Instructs running project build scripts (./gradlew compileJava, ./gradlew test), which executes repository-defined build logic — standard for a development workflow but technically arbitrary code execution from the repo.
How this analysis is made

Examples

Scaffold an archery skill
Add a new McRPG skill called Archery that grants XP on EntityShootBowEvent, without HeldItemBonusSkill, using the namespace key archery. Follow the Add Skill workflow and create the config file, YAML resource, FileType entry, and level component.
Scaffold a block-break skill
Scaffold a new McRPG skill named Excavation for block-break XP, with no HeldItemBonusSkill and namespace key excavation. Use the Add Skill steps and follow the block-break component reference.
Scaffold a fishing skill
Create a new McRPG skill called Fishing using the appropriate Bukkit event for fishing XP, HeldItemBonusSkill set to no, and namespace key fishing. Complete the Add Skill scaffold from config to level component.

Add Skill

Scaffold a new McRPG skill end-to-end. Follow every step in order — do not skip steps.


Step 0 — Gather inputs

Ask (or infer from context) before writing any code:

  1. Skill name — PascalCase class name (e.g. Archery)
  2. Bukkit event that grants XP — the specific event class (e.g. EntityShootBowEvent)
  3. HeldItemBonusSkill? — does this skill grant a bonus based on which item is held? (yes / no)
  4. Namespace key string — snake_case identifier (defaults to the lower-case skill name, e.g. archery)

Step 1 — Read the canonical reference

Before writing any code, read the full Swords skill implementation:

  • src/main/java/us/eunoians/mcrpg/skill/impl/swords/Swords.java
  • src/main/java/us/eunoians/mcrpg/skill/impl/swords/SwordsLevelOnAttackComponent.java
  • src/main/java/us/eunoians/mcrpg/configuration/file/skill/SwordsConfigFile.java

Step 2 — Create the skill config file

Create src/main/java/us/eunoians/mcrpg/configuration/file/skill/<Name>ConfigFile.java:

package us.eunoians.mcrpg.configuration.file.skill;

import dev.dejvokep.boostedyaml.dvs.versioning.BasicVersioning;
import dev.dejvokep.boostedyaml.route.Route;
import dev.dejvokep.boostedyaml.settings.updater.UpdaterSettings;
import org.jetbrains.annotations.NotNull;

import java.util.HashMap;
import java.util.HashSet;

import static com.diamonddagger590.mccore.util.Methods.toRoutePath;

/**
 * Contains all the {@link Route}s used for the <name>_configuration.yml
 */
public final class <Name>ConfigFile extends SkillConfigFile {

    private static final int CURRENT_VERSION = 1;

    public static final Route SKILL_ENABLED = Route.fromString("skill-enabled");
    // Add skill-specific route constants here

    @Override
    public @NotNull UpdaterSettings getUpdaterSettings() {
        return UpdaterSettings.builder()
                .setVersioning(new BasicVersioning("version"))
                .addCustomLogic(new HashMap<>())
                .addIgnoredRoutes(1, new HashSet<>())
                .build();
    }
}

Step 3 — Add to FileType enum

In src/main/java/us/eunoians/mcrpg/configuration/FileType.java, add a new entry:

<NAME>_CONFIG("skill_configuration" + "/" + "<name>_configuration.yml", new <Name>ConfigFile()),

Import the new config file class.


Step 4 — Create the YAML config resource

Create src/main/resources/skill_configuration/<name>_configuration.yml:

# <Name> Skill Configuration
version: 1

skill-enabled: true

# Maximum level for this skill
maximum-skill-level: 1000

# Level-up equation using Parser variables: {level}, {experience}
level-up-equation: "100 * {level}"

# Experience sources
experience:
  # List of item materials that grant XP for this skill
  allowed-items-for-experience-gain: []
  # Source-specific experience amounts (e.g. mob names/types)
  sources: {}

Step 5 — Create the LevelableComponent

Create src/main/java/us/eunoians/mcrpg/skill/impl/<name>/<Name>LevelComponent.java.

Look at SwordsLevelOnAttackComponent.java to pick the correct parent class:

  • For attack-based XP: extend ConfigurableOnAttackLevelableComponent
  • For block-break XP: look at MiningLevelOnBlockBreakComponent as reference
  • For other events: implement LevelableComponent directly
package us.eunoians.mcrpg.skill.impl.<name>;

import com.diamonddagger590.mccore.registry.RegistryAccess;
import dev.dejvokep.boostedyaml.YamlDocument;
import dev.dejvokep.boostedyaml.route.Route;
import org.jetbrains.annotations.NotNull;
import us.eunoians.mcrpg.configuration.FileType;
import us.eunoians.mcrpg.configuration.file.skill.<Name>ConfigFile;
import us.eunoians.mcrpg.registry.McRPGRegistryKey;
import us.eunoians.mcrpg.registry.manager.McRPGManagerKey;

// Extend the appropriate parent
final class <Name>LevelComponent extends /* parent class */ {

    @Override
    public @NotNull YamlDocument getSkillConfiguration() {
        return RegistryAccess.registryAccess()
                .registry(McRPGRegistryKey.MANAGER)
                .manager(McRPGManagerKey.FILE)
                .getFile(FileType.<NAME>_CONFIG);
    }

    @Override
    public @NotNull <Name> getSkill() {
        return (<Name>) RegistryAccess.registryAccess()
                .registry(McRPGRegistryKey.SKILL)
                .getRegisteredSkill(<Name>.<NAME_UPPER>_KEY);
    }
}

Step 6 — Create the skill class

Create src/main/java/us/eunoians/mcrpg/skill/impl/<name>/<Name>.java:

package us.eunoians.mcrpg.skill.impl.<name>;

import com.diamonddagger590.mccore.registry.RegistryKey;
import dev.dejvokep.boostedyaml.YamlDocument;
import dev.dejvokep.boostedyaml.route.Route;
import org.bukkit.NamespacedKey;
import org.bukkit.plugin.Plugin;
import org.jetbrains.annotations.NotNull;
import us.eunoians.mcrpg.McRPG;
import us.eunoians.mcrpg.configuration.FileType;
import us.eunoians.mcrpg.configuration.file.localization.LocalizationKey;
import us.eunoians.mcrpg.registry.manager.McRPGManagerKey;
import us.eunoians.mcrpg.skill.impl.McRPGSkill;
import us.eunoians.mcrpg.skill.impl.type.ConfigurableSkill;
import us.eunoians.mcrpg.util.McRPGMethods;

// Add HeldItemBonusSkill if applicable: ", HeldItemBonusSkill"
public final class <Name> extends McRPGSkill implements ConfigurableSkill {

    public static final NamespacedKey <NAME_UPPER>_KEY =
            new NamespacedKey(McRPGMethods.getMcRPGNamespace(), "<name_key>");

    private final McRPG mcRPG;

    public <Name>(@NotNull McRPG mcRPG) {
        super(<NAME_UPPER>_KEY);
        this.mcRPG = mcRPG;
        addLevelableComponent(new <Name>LevelComponent(), <BukkitEvent>.class, 0);
    }

    @Override
    public @NotNull YamlDocument getYamlDocument() {
        return mcRPG.registryAccess()
                .registry(RegistryKey.MANAGER)
                .manager(McRPGManagerKey.FILE)
                .getFile(FileType.<NAME>_CONFIG);
    }

    @Override
    public @NotNull Route getDisplayItemRoute() {
        return LocalizationKey.<NAME_UPPER>_DISPLAY_ITEM;
    }

    @Override
    public @NotNull Plugin getPlugin() {
        return mcRPG;
    }

    @Override
    public @NotNull String getDatabaseName() {
        return "<name_key>";
    }
}

Step 7 — Add the LocalizationKey display item route

In src/main/java/us/eunoians/mcrpg/configuration/file/localization/LocalizationKey.java:

  1. Add a skill header constant (following the existing pattern, e.g. SWORDS_HEADER):
private static final String <NAME_UPPER>_HEADER = toRoutePath(SKILLS_HEADER, "<name_key>");
  1. Add the display item route:
public static final Route <NAME_UPPER>_DISPLAY_ITEM = Route.fromString(toRoutePath(<NAME_UPPER>_HEADER, "display-item"));

Step 8 — Add the locale file entry

In src/main/resources/localization/english/en_skills.yml (and any other bundled locale files), add a display item section for the new skill following the existing pattern for Swords, Mining, etc.


Step 9 — Register in McRPGExpansion

In src/main/java/us/eunoians/mcrpg/expansion/McRPGExpansion.java, inside getSkillContent():

skillContent.addContent(new <Name>(mcRPG));

Import the new skill class.


Step 10 — Register the FileManager

In the file manager (wherever FileType values are loaded into YamlDocument instances), ensure <NAME>_CONFIG is handled the same as the other skill configs. Check src/main/java/us/eunoians/mcrpg/configuration/ for the FileManager class to see the loading pattern.


Step 11 — Final verification

./gradlew compileJava

If compilation succeeds, run:

./gradlew test

Fix any failures before committing.


Checklist

  • [ ] <Name>ConfigFile.java created with Route constants
  • [ ] FileType.<NAME>_CONFIG entry added
  • [ ] YAML config file at src/main/resources/skill_configuration/<name>_configuration.yml
  • [ ] <Name>LevelComponent.java created with correct parent
  • [ ] <Name>.java created extending McRPGSkill, implementing ConfigurableSkill
  • [ ] LocalizationKey.<NAME_UPPER>_DISPLAY_ITEM route added
  • [ ] Locale YAML entry added for display item
  • [ ] Registered in McRPGExpansion.getSkillContent()
  • [ ] ./gradlew compileJava passes
  • [ ] ./gradlew test passes

From the file to a first result

The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.

View the source and supporting files

This download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.

1. Download the file

Download SKILL.md

From the root of a test project, save the file as .skill-downloads/scaffold-mcrpg-skill-ms47vqmw/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.

Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.

mkdir -p '.skill-downloads/scaffold-mcrpg-skill-ms47vqmw' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/scaffold-mcrpg-skill-ms47vqmw/download' --output '.skill-downloads/scaffold-mcrpg-skill-ms47vqmw/SKILL.md.part' && mv '.skill-downloads/scaffold-mcrpg-skill-ms47vqmw/SKILL.md.part' '.skill-downloads/scaffold-mcrpg-skill-ms47vqmw/SKILL.md'

2. Check prerequisites

Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.

No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.

The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.

3. Load the skill

This file does not provide a usable name/description header for this native procedure. It remains available to download and inspect; use the manual method below.

Manual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.

4. Try a first task

Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:

Read .skill-downloads/scaffold-mcrpg-skill-ms47vqmw/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.

Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.

Related skills