1.0.0
Compatibility
Changes
A two-part system that shows Citizens NPC dialogue in a Pokémon-style text box and makes the NPC walk up to you, on a Minecraft 1.21.1 hybrid (Mohist/Arclight) server running Cobblemon.
Part 1 — Client mod (npc-dialog-box, Fabric)
Installed in the client's mods/ folder. It's purely visual.
- Listens to incoming chat/system messages using Fabric's message events.
- Matches a configurable regex pattern against each line. The default matches your server's NPC speech format <rank> | <Name>: <text> (e.g. ᴅᴏc | Toh: Hello!) and also the rank-less form Name: text, while ignoring normal player chat (which uses the » separator) and plugin broadcasts like [PokeHunt] ….
- When a line matches, it hides it from chat and opens a Pokémon-style box at the bottom of the screen, drawing the original KantoNPCs textures (dialog_box.png, arrow_down.png).
- Typewriter effect: text appears character-by-character.
- Auto-pagination: long text is split into pages of ~2 lines that fit the box; a bouncing arrow shows when there's more. Click / Space / Enter advances; the last click closes it.
- Consecutive lines from the same NPC merge into extra pages of the same box.
- Config file config/npcdialogbox.json: pattern, charsPerTick (typing speed), scale, wrapWidth, linesPerPage, debug.
- Test command: /npcdialogtest <text> opens the box directly.
Part 2 — Server plugin (npc-approach-plugin, Bukkit/Citizens)
Installed in the server's plugins/ folder. It controls NPC behavior (the client can't move server entities).
- Detects the nearest player within a radius, makes the Citizens NPC walk up to them, and when it arrives sends that player the dialogue line (in the [rank] | Name: text format the client mod reads).
- When the player leaves, the NPC walks back to its home spot (teleports back as a fallback), restoring its original facing — mirroring KantoNPCs' behavior.
- Per-NPC setup in-game: select with /npc select, then /npcapproach set <text>, plus add, enable/disable, radius, stop, cooldown, speed, info, clear, reload (with tab-complete).
- Global defaults in config.yml (radius 8, stop 2, cooldown 16s, speed 1.0 — matched to KantoNPCs).
Projects on Modrinth are automatically available through a Maven repository for use with JVM build tools such as Gradle. To learn more about the Modrinth Maven API, click here.
Note: When available, you should use the creator's maven repo instead as it will have transitive dependency information that the Modrinth Maven API does not. You may also end up with duplicate dependencies if you use a mix of Modrinth and non-Modrinth Maven repositories for your dependencies, because the group identifier will be different when served through the Modrinth Maven API.
Maven coordinates:
Version ID:
build.gradle:
repositories {
exclusiveContent {
forRepository {
maven {
name = "Modrinth"
url = "https://api.modrinth.com/maven"
}
}
// forRepositories(fg.repository) // Uncomment when using ForgeGradle
filter {
includeGroup "maven.modrinth"
}
}
}
// Standard Gradle dependency
dependencies {
implementation "maven.modrinth:kI6K0AV3:jAJA7lMn"
}
// Legacy Loom dependency
dependencies {
modImplementation "maven.modrinth:kI6K0AV3:jAJA7lMn"
}

