Dumpster
Dumpster
This utility mod provides convenient commands for exporting various game data directly to local files. With it, developers can easily analyze the state of game systems.
Main Features
The mod offers several commands for data export:
/dump registries— exports all game registries/dump data— saves various game data including tags, recipes, and much more/dump data <type>— allows exporting specific data types such as tags, recipes, loot tables, and others/dump— performs a complete export of all available data
Configuration
Includes a configuration file where you can set export parameters. You can define which specific data should be exported when using commands, as well as configure automatic export upon reload or game startup. Options for organizing output file structure are also available.
The configuration file is located in the config folder under the name dumpster.properties.
Server and Client Operation
The mod intelligently handles various usage scenarios:
- On server: only operators can use the
/dumpstercommand, which saves data to server files - On client: any player can use the
/dumpstercommand without restrictions - When installed on both sides: the client command is automatically renamed to
/dump-clientfor proper operation
Purpose
This mod is not intended for regular gameplay! It is created exclusively as a useful tool for datapack, mod, and modpack developers, allowing them to check the impact of their changes on game systems.
Compatibility
By default, the mod does not process custom recipe types from other mods. For compatibility, additional implementation is required from the mod adding the new recipe type, or through intermediary mods.
Compatibility Implementation
For integration, you can use Modrinth maven API as indicated in the documentation. You need to implement the RecipeJsonParser interface in a class and register it as an entry-point recipe-dump, similar to the example in the fabric.mod.json file.
The class must also be annotated with @TargetRecipeType specifying the target recipe type. If necessary, you can set a priority to override other parsers.
Example class implementation (using Yarn mappings):
import com.google.gson.JsonObject;
import mc.recraftors.dumpster.recipes.RecipeJsonParser;
import mc.recraftors.dumpster.recipes.TargetRecipeType;
import net.minecraft.recipe.Recipe;
@TargetRecipeType("mymod:myrecipetype")
public class MyRecipeTypeJsonParser implements RecipeJsonParser {
private MyRecipe recipe;
@Override
public JsonParser.InResult in(Recipe<?> recipe) {
if (recipe instanceof MyRecipe myRecipe) {
this.recipe = myRecipe;
return RecipeJsonParser.InResult.SUCCESS;
}
return RecipeJsonParser.InResult.FAILURE;
}
@Override
public JsonObject toJson() {
// implement your parsing method here
}
}
Additional methods are available for extended functionality, such as grouping multiple recipes from a single file or supporting alternative recipe type identifiers.