Downloadable examples¶
These examples are complete JSON files, not the editor's internal string map. Start with one in a test world and choose the NPC's appearance in the editor before using it in a production area.
Starter pack¶
Download the complete starter pack
Extract this archive inside config/greatnpc/. It includes four presets under trainer_preset/tutorials/ and the two required team files under trainer_team/tutorials/.
File-based presets require a team file
The current loader requires team to resolve to an existing file before it registers a preset, even for a shop or dialogue NPC. team_inline does not bypass that loader check. The battle examples reference tutorials/practice-team; the non-battle examples reference tutorials/empty-team, which contains [].
Install a preset example¶
- Download a preset below and its required team file, or use the complete starter pack.
- Save the preset under
config/greatnpc/trainer_preset/tutorials/and its team underconfig/greatnpc/trainer_team/tutorials/, keeping the.jsonextensions. - Run
/gnpc reloadand/gnpc validate. - Spawn the matching short trainer ID, such as
/gnpc spawn tutorials/practice-trainer. - Test with an ordinary player account as well as an administrator.
Administrator permissions can change the results of access conditions. These files do not configure custom skins, texture packs, or server-specific reward commands.
Practice trainer¶
Download practice-trainer.json
- One level-10 Pikachu, normal level mode, and random AI.
- Rematches allowed, with a five-minute cooldown after a player victory.
- The player's party is healed after a completed battle.
- No permission or prerequisite restriction.
After installing the file:
Download practice-team.json and place it in config/greatnpc/trainer_team/tutorials/practice-team.json. Both trainer examples already reference this shared file with "team": "tutorials/practice-team".
One-attempt trainer¶
Download one-attempt-trainer.json
The attempt is consumed by starting the battle, including a battle the player loses. This example intentionally enables rematches to show that One battle per player is a separate, stronger attempt restriction.
Copies using this trainer ID share the player's consumed attempt. Use the resetbattle command when testing rather than assuming that moving or copying the entity resets progression.
Restocking trader¶
Download restocking-trader.json
This preset selects two of three weighted offers at each stock generation, with a 30-minute restock interval. Its costs use actual GreatNPC coin items.
It also requires empty-team.json at config/greatnpc/trainer_team/tutorials/empty-team.json. The empty team satisfies the loader; interaction mode remains trade, so this character does not start trainer battles.
For a test inventory:
/give @s greatnpc:coin_gold 16
/give @s greatnpc:coin_iron 16
/gnpc spawn tutorials/restocking-trader
Silver keys are ordinary items here. This example does not create a lock or door-unlocking mechanic.
Town greeter¶
A two-page welcome dialogue with a close button. It is not a quest or mission: it does not track objectives or progression.
Use the same empty-team.json file as the trader. The dialogue is independent of battle Pokémon.
Adapting the examples¶
- Change
display_nameand menu metadata to match the world. - Use separate trainer IDs when cooldowns or attempts should be independent.
- Add requirements only after testing the unrestricted behavior.
- Verify species, moves, abilities, sounds, and item IDs against the installed mods and data packs.
- Use the inventory picker for component-sensitive item definitions.
- Keep backups before replacing preset/team files.
See Preset JSON fields for every declared preset property.