Advertisement
YTMango

KubeJS - TFC Heating Ingot to Create Mixing Recipe

Dec 26th, 2023 (edited)
1,320
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
JavaScript 0.52 KB | Source Code | 0 0
  1. // requires: create
  2. // requires: kubejs_create
  3. // requires: tfc
  4.  
  5. ServerEvents.recipes((event) => {
  6.   const { create } = event.recipes;
  7.  
  8.   event.forEachRecipe({ type: "tfc:heating" }, (recipe) => {
  9.     const { json } = recipe;
  10.  
  11.     if (!json.has("result_fluid")) return;
  12.     const ingredient = json.get("ingredient");
  13.     const result_fluid = json.get("result_fluid");
  14.  
  15.     create.mixing(
  16.       [Fluid.of(result_fluid.get("fluid"), result_fluid.get("amount"))],
  17.       [ingredient.get("item")]
  18.     ).heated();
  19.   });
  20. });
Tags: kubejs
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement