Back to mods
pkl4mc project artwork

CurseForge · Minecraft mod

pkl4mc

Brings the PKL language as a JSON replacement to Minecraft for mod and modpack creators.

Choose a version Pick your version below, then grab the matching file.

Quick answer

Which pkl4mc release should I use?

Updated last month
Latest stable file pkl4mc-0.11.0+mc.20.1
Game version 1.20.1
Loader Forge

pkl4mc-0.11.0+mc.20.1 targets 1.20.1 with Forge. The project page does not say whether this file belongs on the client, dedicated server, or both. All 1 required mods have matching files.

Where it goes

Is pkl4mc required on the client, server, or both?

The project page does not say whether this file belongs on the client, dedicated server, or both.

Client Source doesn’t say
Dedicated server Source doesn’t say
Loader for this release Forge
Required install it here Optional supported, not mandatory Not supported do not install here Source doesn’t say do not assume

The source does not explicitly classify this release as client-only or server-only.

What else does pkl4mc-0.11.0+mc.20.1 need?

pkl4mc-0.11.0+mc.20.1. Change the file and its required mods may change too.

All 1 required mods have matching files

Install Kotlin for Forge first. We found matching files for this game-version and loader setup.

Kotlin for Forge Needed by pkl4mc-0.11.0+mc.20.1
required
Matching file found Matched file: Kotlin for Forge 4.12.0
EMI Optional for pkl4mc-0.11.0+mc.20.1
optional
Matching file found Matched file: emi-1.1.24+1.20.1+forge

We only count dependency files that match this setup. A file for another loader does not fill the gap.

Before you install it

Add pkl4mc without breaking your instance.

Built for pkl4mc-0.11.0+mc.20.1. Pick another file and the loader, install side or required mods may change.

  1. 01

    Stick to this file

    Use pkl4mc-0.11.0+mc.20.1. It targets 1.20.1 with Forge; another release may have different loader, side or dependency requirements.

  2. 02

    Bring the mods it needs

    Install Kotlin for Forge first. We found matching files for this game-version and loader setup.

  3. 03

    Put it on the correct side

    The project page does not say whether this file belongs on the client, dedicated server, or both.

  4. 04

    Pick the file you checked

    Use the “Get this file” button beside pkl4mc-0.11.0+mc.20.1. It opens that exact file at the source.

About this project

What does pkl4mc add?

pkl4mc


[DISCLAIMER] This was originally a dumb idea I had and built for self use and to learn more about PKL runtime and JVM. If it's useful to you too, great. Btw I also used Gemini for bugfixing and planning, so kill me for that.

Brings the PKL language as a JSON replacement to Minecraft for mod and modpack creators.

What the hell is PKL?

PKL is a configuration language by Apple, which has type-safetines, autocompletion, validation and schemas.

With pkl4mc you can create any vanilla datapack in PKL instead of JSON. Which brings a consistent sytax for mod support and error caughting in your ide instead of the game log (lol).

Unlike KubeJS, pkl4mc is NOT a scripting mod, it is a typed data format, where everything is reloadable at runtime with /pkl reload. This also shows up in reload times:

Both mods had the same 100 recipes, including adding, removing, replacing (input and output).

recipe step per reload (median)
pkl4mc ~ 7–9 ms
KubeJS (2001.6.5 + Rhino) ~ 30–65 ms

And to be fair KubeJS is doing way more than recipes. If you need scripting logic, use KubeJS. If you need typed, fast, reloadable data, use pkl4mc.

Who is the Project for?

Probably for modpack and datapack devs, who wanna have autocmpletion and typecheking instead of guessing, or maybe hate JSON for some reason (a camp I'm in too).

For modpack devs with companion mods, who just want a better workflow for recipe adjustments and unifications (another camp I'm in too).

Also for mod devs who wanna depend on pkl4mc as a library and load typed configs via PklConfig.load<T>(), or register their own schemas (You can guess it).

Dependencies

  • Currently only mc.20.1 and Forge
  • Kotlin for Forge
  • pkl-core (Already included inside the jar fyi)

For Dev

Installation

thats just a placeholder gif for now installation

Example

Here is a smelting recipe in JSON:

{
  "type": "minecraft:smelting",
  "category": "misc",
  "ingredient": { "item": "minecraft:sea_pickle" },
  "result": "nothingcore:cooked_sea_pickle",
  "experience": 0.7,
  "cookingtime": 200
}

And here in PKL:

amends "@pkl4mc/recipes.pkl"

smelting {
  new {
    name = "example_smelting"
    category = "misc"
    input { item = "minecraft:sea_pickle" }
    output { item = "nothingcore:cooked_sea_pickle" }
    experience = 0.7
    cookingTime = 200
  }
}

How to get help

There are docs in progress (like KubeJS LOL): docs.nothingseries.org and also examples for each mod integration.

If something is missing pls make a issue on the issue tracker.

If you need help join the Nothing Series Hub and make a ticket or ask in the support channel.

Contributing

Currently the most useful contribution is bug reporting and schema creation for a mods that doesn't have one yet.

License


Feel free to use this badges in your modpacks or mods.


Project description from CurseForge.

Pick your setup

pkl4mc by Minecraft version and loader

Choose the version and loader you play, then open the matching release.

1 available setups

Check the dependencies, then try the file in a copied instance before changing a world you care about.

Recent files

pkl4mc versions and loaders

2 of 2 releases match

Looking for an older file? The official CurseForge project page is in Resources.