CurseForge · Minecraft mod
env.json
A small FabricMC library allowing to convert an `env.json` file into a Java Object. It is mostly used by Environment Driven Assets and Environment Driven Data.
Quick answer
Which env.json release matches 1.21?
env.json 0.4.3-beta targets 1.21, 1.21.1 with Fabric, Quilt. 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 env.json required on the client, server, or both?
The project page does not say whether this file belongs on the client, dedicated server, or both.
The source does not explicitly classify this release as client-only or server-only.
What else does env.json 0.4.3-beta need?
0.4.3-beta on 1.21. Every mod below is checked against that same setup.
Install Fabric API first. We found matching files for this game-version and loader setup.
We only count dependency files that match this setup. A file for another loader does not fill the gap.
Before you install it
Add env.json without breaking your instance.
Built for env.json 0.4.3-beta on 1.21. Pick another file and the loader, install side or required mods may change.
- 01
Stick to this file
Use 0.4.3-beta. It targets 1.21, 1.21.1 with Fabric, Quilt; another release may have different loader, side or dependency requirements.
- 02
Bring the mods it needs
Install Fabric API first. We found matching files for this game-version and loader setup.
- 03
Put it on the correct side
The project page does not say whether this file belongs on the client, dedicated server, or both.
- 04
Pick the file you checked
Use the “Get this file” button beside 0.4.3-beta. It opens that exact file at the source.
About this project
What does env.json add?
You can click on the banner to join our Discord.
env.json
Supports
Requirements
Concept
env.json is a Minecraft Library introducing a new sub json file extension format, with the goal of redirecting minecraft resources to other ones based on the environment context.
Implementations
env.json doesn't provide these redirections directly, but only the operations around env.json files and their resource reload management.
There is currently two official implementations of env.json:
Mod Identifier: env-driven-assets.
Environments: Client
Applies env.json operations to Minecraft Vanilla asset types.
Mod Identifier: env-driven-data.
Environments: Common & Server
Applies env.json operations to Minecraft Vanilla data types.
The env.json Format
[
{
"rules": [ // the primary set of rules, is an "any" type
{
"type": "sequence", // all rules in the sequence must pass
"rule": [] // the rules
},
{
"type": "any", // passes if at least one rule passes
"rule": [] // the rules
},
{
"type": "not", // reverses the rule
"rule": { // the rule
"type": "...",
"rule": "..."
}
},
{
"type": "dimension", // passes if the current dimension matches this one
"rule": "minecraft:overworld" // the dimension, can also be a tag
},
{
"type": "biome", // passes if the current biome matches this one
"rule": "minecraft:plains" // the biome, can also be a tag
},
{
"type": "x_coord", // passes if the following operations on the x-axis are valid
"rule": {
"comparator": "==", // must be <, >, ==, <=, >=, =< or =>
"value": "100" // must be an integer
}
},
{
"type": "y_coord", // passes if the following operations on the y-axis are valid
"rule": {
"comparator": "==", // must be <, >, ==, <=, >=, =< or =>
"value": "100" // must be an integer
}
},
{
"type": "z_coord", // passes if the following operations on the z-axis are valid
"rule": {
"comparator": "==", // must be <, >, ==, <=, >=, =< or =>
"value": "100" // must be an integer
}
},
{
"type": "submerged", // passes if the current context is surrounded by water or not
"rule": true // true for "if it is submerged" and false for "if it is not submerged"
},
{
"type": "sky", // passes if the context is above the sky limit, at or below
"rule": "at" // must be "above", "at" or "below"
},
{
"type": "water", // passes if the context is above the water level, at or below
"rule": "at" // must be "above", "at" or "below"
},
{
"type": "void", // passes if the context is above the void limit, at or below
"rule": "at" // must be "above", "at" or "below"
}
],
"result": "minecraft:block/stone" // the redirected resource
}
]
The file must be registered under this format: redirected_resource_name-redirected_resource_extension.env.json.
Usage For Developers
In your build.gradle
repositories {
// ...
maven { url 'https://jitpack.io' }
}
// ...
dependencies {
// ...
modImplementation "com.mmodding:env.json:${theMostBeautifulVersionYouCanFind}"
}
You can now get your EnvJson object from a Resource object thanks to ExtendedResource#of(Resource)#getEnvJson or parse it with EnvJson#parse(Path) or EnvJson#parse(InputStream).
Badge For Developers
[<img src="https://github.com/MModding/art/blob/main/mods/env_json/requires_env_json.png?raw=true" width="256" alt="Requires env.json">](https://modrinth.com/mod/env.json)
Promotion
//raw.githubusercontent.com/ModFest/art/3bf66556e674d670e30f647d6a48c4e1798c21d4/badge/128h/ModFest" rel="noopener noreferrer" target="_blank">https://raw.githubusercontent.com/ModFest/art/3bf66556e674d670e30f647d6a48c4e1798c21d4/badge/128h/ModFest 1.20 Badge Cozy.png" alt="ModFest 1.20">
Project description from CurseForge.
Pick your setup
env.json by Minecraft version and loader
Choose the version and loader you play, then open the matching release.
1.21.1
2 loader builds1.21
2 loader builds1.20.6
2 loader builds1.20.5
2 loader builds1.20.4
2 loader builds1.20.3
2 loader builds1.20.2
2 loader builds1.20.1
2 loader buildsCheck the dependencies, then try the file in a copied instance before changing a world you care about.
Recent files
env.json versions and loaders
0.4.3-beta
env_json-0.4.3-beta.jar
9 Sept 2024
0.4.2-beta
env_json-0.4.2-beta.jar
16 Jun 2024
Looking for an older file? The official CurseForge project page is in Resources.




