zen-flow 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2022 Chronocide
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,213 @@
1
+ <div align="center">
2
+ <img src="logo.png" width="512" alt="logo">
3
+ </div>
4
+
5
+ <div align="center">
6
+ <a href="/LICENSE">
7
+ <img alt="License MIT" src="https://img.shields.io/badge/license-MIT-blue.svg" />
8
+ </a>
9
+ <a href="https://www.npmjs.com/package/zen-flow">
10
+ <img alt="NPM" src="https://img.shields.io/npm/v/zen-flow?label=npm">
11
+ </a>
12
+ </div>
13
+
14
+ ## Install
15
+
16
+ ```shell
17
+ $ npm i zen-flow -D
18
+ ```
19
+
20
+ <i>Note: This package requires Node > 10.12.0 and Minecraft 1.7.10.</i>
21
+
22
+ ## Features
23
+
24
+ - Easy to use API, written in <b>TypeScript</b>.
25
+ - <b>Polymorphic</b> and <b>variadic</b>; do more with less code.
26
+ - Supports both [MineTweaker3](http://minetweaker3.powerofbytes.com/) and [ModTweaker](http://minetweaker3.powerofbytes.com/wiki/ModTweaker).
27
+ - <b>Formatted output</b>; makes debugging easier.
28
+
29
+ ## Getting started
30
+
31
+ <b>Crafting Table</b>
32
+ Add crafting recipe
33
+
34
+ ```TypeScript
35
+ import { vanilla } from 'zen-flow';
36
+
37
+ vanilla.add('<minecraft:saddle>', {
38
+ 1: '<minecraft:leather>', 2: '<minecraft:leather>', 3: '<minecraft:leather>',
39
+ 4: '<ore:ingotIron', 5: '<minecraft:string>', 6: '<ore:ingotIron>'
40
+ });
41
+
42
+ /**
43
+ * recipes.addShaped(<minecraft:saddle>, [
44
+ * [<minecraft:leather>, <minecraft:leather>, <minecraft:leather>],
45
+ * [<ore:ingotIron>, <minecraft:string>, <ore:ingotIron>],
46
+ * [null, null, null]
47
+ * ]);
48
+ * /
49
+ ```
50
+
51
+ <b>Extra Utilities generators</b>
52
+ Remove & hide generators
53
+
54
+ ```TypeScript
55
+ import { nei, vanilla } from 'zen-flow';
56
+
57
+ const generators = Array.from({ length: 11 })
58
+ .map((_, i) => [
59
+ `<ExtraUtilities:generator${i === 0 ? '' : `:${i}`}>`,
60
+ `<ExtraUtilities:generator.8${i === 0 ? '' : `:${i}`}>`,
61
+ `<ExtraUtilities:generator.64${i === 0 ? '' : `:${i}`}>`
62
+ ])
63
+ .flat()
64
+ .map(generator => [
65
+ vanilla.remove(generator),
66
+ nei.hide(generator)
67
+ ].join('\n'))
68
+
69
+ /**
70
+ * recipes.remove(<ExtraUtilities:generator>);
71
+ * NEI.hide(<ExtraUtilities:generator>);
72
+ * [...]
73
+ * recipes.remove(<ExtraUtilities:generator.64:10>);
74
+ * NEI.hide(<ExtraUtilities:generator.64:10>);
75
+ * /
76
+ ```
77
+
78
+ ## API
79
+
80
+ - MineCraft
81
+ - [Vanilla](#vanilla)
82
+ - [Items](#items)
83
+ - [Formatting](#formatting)
84
+ - Mods
85
+ - [Avaritia](#avaritia)
86
+ - [ExNihilo](#exnihilo)
87
+ - [ExtraUtilities](#extrautilities)
88
+ - [MineFactoryReloaded](#minefactoryreloaded)
89
+ - [NEI](#nei)
90
+ - [ThermalExpansion](#thermalexpansion)
91
+
92
+ ## Vanilla
93
+
94
+ - `add` - Add a crafting table recipe.
95
+ - Shaped recipe: `object`
96
+ - Shapeless recipe: `Array`
97
+ - `remove` - Removes both shaped and shapeless recipes
98
+ - `removeShaped` - Removes only shaped recipes
99
+ - `removeShapeless` - Removes only shaped recipes
100
+ - `addFurnace` - Adds furnace recipe
101
+ - `removeFurnace` - Removes furnace recipe
102
+
103
+ ## Items
104
+
105
+ - `withName` - Change item name
106
+ - `withTooltip` - Add item tooltip*
107
+ - `withTooltipShift` - Add shift item tooltip*
108
+ - `withTag` - Add item NBT tag data
109
+ - [Display properties](https://minecraft.fandom.com/wiki/Player.dat_format#Display_Properties)
110
+ - `withEnchantments` - Add item enchantments
111
+
112
+ <i>* It is currently not possible to remove item tooltips.</i>
113
+
114
+ ### Formatting
115
+
116
+ `withName`, `withTooltip` and `withTooltipShift` accept formatting strings:
117
+
118
+ ```TypeScript
119
+ // Bread
120
+ withName('<minecraft:bread>', 'Bread');
121
+
122
+ // Bread (with red text)
123
+ withName('<minecraft:bread>', ['Bread', { colour: 'red' }]);
124
+
125
+ // Bread (bold red text)
126
+ withName('<minecraft:bread>', ['Bread', { colour: 'red', format: 'bold' }]);
127
+
128
+ // Bread (normal text) with butter (yellow italic text)
129
+ withName('<minecraft:bread>', [
130
+ 'Bread',
131
+ ['with butter', { colour: 'yellow', format: 'italic' }]
132
+ ]);
133
+ ```
134
+
135
+ ## Avaritia
136
+
137
+ - `addCompressor` - Add Neutronium Compressor recipe
138
+ - `removeCompressor` - Remove Neutronium Compressor recipe
139
+ - `addExtreme` - Add Extreme Crafting recipe
140
+ - `removeExtreme` - Remove Extreme Crafting recipe
141
+
142
+ ## ExNihilo
143
+
144
+ - `addComposter` - Add item that can be composted to dirt
145
+ - `fill` must be a value between `0` and `1`
146
+ - `removeComposter` - Remove item that can be composted to dirt
147
+ - `addCrucible` - Add crucible recipe
148
+ - `removeCrucible` - Remove crucible recipe
149
+ - `addCrucibleSource` - Add crucible heat source
150
+ - `heat` must be a value between `0` and `1`
151
+ - `removeCrucibleSource` - Remove crucible heat source
152
+ - `addHammer` - Add hammer recipe
153
+ - `removeHammer` - Remove hammer recipe
154
+ - `addSieve` - Add sieve recipe
155
+ - Some percentages are impossible, such as
156
+ - `0.7 => 1 / 0.7 => ~1.42 => 1 (100%)`
157
+ - `0.13 => 1 / 0.13 => ~7.69 => 8 (12.5%)`
158
+ - `removeSieve` - Remove sieve recipe
159
+
160
+ ### Examples
161
+
162
+ ```TypeScript
163
+ import { exnihilo } from 'zen-flow';
164
+
165
+ exnilo.addHammer('<minecraft:cobblestone>', {
166
+ '<minecraft:stick>': [0.5], // 50%
167
+ '<minecraft:bread>': [1, 1, 0.5] // 100%, 100%, 50%
168
+ '<minecraft:stone>': [[1, 2], [0.5, 1]] // 100% with 2x modifier, 50% with 1x modifier
169
+ '<minecraft:coal>': [[1, 2], 1] // 100% with 2x modifier, 100%
170
+ });
171
+
172
+ exnihilo.addSieve('<minecraft:cobblestone>', {
173
+ '<minecraft:stick': 2.5 // 250%
174
+ '<minecraft:bread>': 0.33 // 33%
175
+ });
176
+ ```
177
+
178
+ ## ExtraUtilities
179
+
180
+ - `addQED` - Add QED recipe
181
+ - QED only accepts <b>shaped</b> recipes
182
+ - `removeQED` - Remove QED recipe
183
+
184
+ ## MineFactoryReloaded
185
+
186
+ - `addLaser` - Add ore to the Mining Laser ore table
187
+ - `removeLaser` - Remove ore from the Mining Laser ore table
188
+ - `addLaserPreferred` - Add ore to the Mining Laser lens
189
+ - `removeLaserPreferred` - Remove ore from the Mining Laser lens
190
+
191
+ ## NEI
192
+
193
+ - `hide` - Hide item from NEI
194
+ - `add` - Add item to NEI
195
+
196
+ ## ThermalExpansion
197
+
198
+ - `addCrucible` - Add Magma Crucible recipe
199
+ - `removeCrucible` - Remove Magma Crucible recipe
200
+ - `addFurnace` - Add Redstone Furnace recipe
201
+ - `removeFurnace` - Remove Redstone Furnace recipe
202
+ - `addInsolator` - Add Phytogenic Insolator recipe
203
+ - `removeInsolator` - Remove Phytogenic Insolator recipe
204
+ - `addPulverizer` - Add Pulverizer recipe
205
+ - `removePulverizer` - Remove Pulverizer recipe
206
+ - `addSawmill` - Add Sawmill recipe
207
+ - `removeSawmill` - Remove Sawmill recipe
208
+ - `addSmelter` - Add Induction Smelter recipe
209
+ - `removeSmelter` - Remove Induction Smelter recipe
210
+ - `addTransposerFill` - Add Fluid Transposer fill recipe
211
+ - `removeTransposerFill` - Remove Fluid Transposer fill recipe
212
+ - `addTransposerExtract` - Add Fluid Transposer extract recipe
213
+ - `removeTransposerExtract` - Remove Fluid Transposer extract recipe
@@ -0,0 +1,355 @@
1
+ 'use strict';
2
+
3
+ const createCode = (code) => `\\u00A7${code}`;
4
+ const createFormat = (type) => (tooltip) => `format.${type}(${tooltip})`;
5
+ const NAME_COLOUR = {
6
+ black: createCode("0"),
7
+ darkBlue: createCode("1"),
8
+ darkGreen: createCode("2"),
9
+ darkAqua: createCode("3"),
10
+ darkRed: createCode("4"),
11
+ darkPurple: createCode("5"),
12
+ gold: createCode("6"),
13
+ gray: createCode("7"),
14
+ darkGray: createCode("8"),
15
+ blue: createCode("9"),
16
+ green: createCode("a"),
17
+ aqua: createCode("b"),
18
+ red: createCode("c"),
19
+ lightPurple: createCode("d"),
20
+ yellow: createCode("e"),
21
+ white: createCode("f")
22
+ };
23
+ const TOOLTIP_COLOUR = {
24
+ black: createFormat("black"),
25
+ darkBlue: createFormat("darkBlue"),
26
+ darkGreen: createFormat("darkGreen"),
27
+ darkAqua: createFormat("darkAqua"),
28
+ darkRed: createFormat("darkRed"),
29
+ darkPurple: createFormat("darkPurple"),
30
+ gold: createFormat("gold"),
31
+ gray: createFormat("gray"),
32
+ darkGray: createFormat("darkGray"),
33
+ blue: createFormat("blue"),
34
+ green: createFormat("green"),
35
+ aqua: createFormat("aqua"),
36
+ red: createFormat("red"),
37
+ lightPurple: createFormat("lightPurple"),
38
+ yellow: createFormat("yellow"),
39
+ white: createFormat("white")
40
+ };
41
+ const NAME_FORMAT = {
42
+ obfuscated: createCode("k"),
43
+ bold: createCode("l"),
44
+ strikethrough: createCode("m"),
45
+ underline: createCode("n"),
46
+ italic: createCode("o"),
47
+ reset: createCode("r")
48
+ };
49
+ const TOOLTIP_FORMAT = {
50
+ obfuscated: createFormat("obfuscated"),
51
+ bold: createFormat("bold"),
52
+ strikethrough: createFormat("strikethrough"),
53
+ underline: createFormat("underline"),
54
+ italic: createFormat("italic")
55
+ };
56
+ const ENCHANTMENTS = {
57
+ protection: 0,
58
+ fireResistance: 1,
59
+ featherFalling: 2,
60
+ blastProtection: 3,
61
+ projectileProtection: 4,
62
+ respiration: 5,
63
+ aquaAffinity: 6,
64
+ thorns: 7,
65
+ sharpness: 16,
66
+ smite: 17,
67
+ baneOfAntrophods: 18,
68
+ knockback: 19,
69
+ fireAspect: 20,
70
+ looting: 21,
71
+ efficiency: 32,
72
+ silkTouch: 33,
73
+ unbreaking: 34,
74
+ fortune: 35,
75
+ power: 48,
76
+ punch: 49,
77
+ flame: 50,
78
+ infinity: 51
79
+ };
80
+ const MFR_LASER_LENSES = {
81
+ white: 0,
82
+ orange: 1,
83
+ lightBlue: 3,
84
+ yellow: 4,
85
+ lime: 5,
86
+ gray: 7,
87
+ lightGray: 8,
88
+ purple: 10,
89
+ blue: 11,
90
+ brown: 12,
91
+ red: 14,
92
+ black: 15
93
+ };
94
+
95
+ const isItem = (x) => Array.isArray(x) && x.length === 2 && typeof x[0] === "string" && typeof x[1] === "number";
96
+ const isRecipeShaped = (x) => !Array.isArray(x) && typeof x === "object";
97
+ const isTextFormat = (x) => Array.isArray(x) && x.length === 2 && (x[1].colour || x[1].format);
98
+
99
+ const formatItem = (item) => `${item[0]} * ${item[1]}`;
100
+ const formatList = (list) => `[${list.join(", ")}]`;
101
+ const formatIngredient = (ingredient) => ingredient ?? "null";
102
+ const formatEnchantment = (enchantment) => `{ id: ${ENCHANTMENTS[enchantment[0]]}, lvl: ${enchantment[1]} }`;
103
+ const formatName = (texts) => {
104
+ const format = (text) => [
105
+ text[1].colour && NAME_COLOUR[text[1].colour],
106
+ text[1].format && NAME_FORMAT[text[1].format],
107
+ text[0],
108
+ (text[1].colour || text[1].format) && NAME_FORMAT.reset
109
+ ].filter((x) => x).join("");
110
+ if (typeof texts === "string")
111
+ return `"${texts}"`;
112
+ if (isTextFormat(texts))
113
+ return `"${format(texts)}"`;
114
+ const formatted = texts.map((text) => typeof text === "string" ? text : format(text)).join("");
115
+ return `"${formatted}"`;
116
+ };
117
+ const formatTooltip = (texts) => {
118
+ const format = (text, options) => TOOLTIP_COLOUR[options?.colour ?? "gray"](options?.format ? TOOLTIP_FORMAT[options.format](`"${text}"`) : `"${text}"`);
119
+ if (!Array.isArray(texts))
120
+ return `"${texts}"`;
121
+ if (isTextFormat(texts))
122
+ return format(...texts);
123
+ return texts.map(formatTooltip).join(" + ");
124
+ };
125
+ const formatRecipeShaped = (recipe) => {
126
+ const matrix = [
127
+ [recipe[1], recipe[2], recipe[3]],
128
+ [recipe[4], recipe[5], recipe[6]],
129
+ [recipe[7], recipe[8], recipe[9]]
130
+ ].map((row) => formatList(row.map(formatIngredient)));
131
+ return `[
132
+ ${matrix.join(",\n ")}
133
+ ]`;
134
+ };
135
+ const formatArgs = (...args) => {
136
+ const list = args.filter((arg) => arg !== void 0).map((arg) => {
137
+ if (typeof arg === "number")
138
+ return `${arg}`;
139
+ if (isRecipeShaped(arg))
140
+ return formatRecipeShaped(arg);
141
+ if (isItem(arg))
142
+ return formatItem(arg);
143
+ if (Array.isArray(arg))
144
+ return formatList(arg);
145
+ return arg;
146
+ });
147
+ return list.length > 3 ? `
148
+ ${list.join(",\n ")}
149
+ ` : list.join(", ");
150
+ };
151
+
152
+ const addCompressor = (recipe) => `mods.avaritia.Compressor.add(${formatArgs(recipe.out, recipe.in[0], recipe.in[1])});`;
153
+ const removeCompressor = (ingredient) => `mods.avaritia.Compressor.remove(${ingredient});`;
154
+ const addExtreme = (item, recipe) => {
155
+ const out = formatArgs(item, recipe.map((row) => formatArgs(row.map(formatIngredient))));
156
+ return `mods.avaritia.ExtremeCrafting.addShaped(${out});`;
157
+ };
158
+ const removeExtreme = (ingredient) => `mods.avaritia.ExtremeCrafting.remove(${ingredient});`;
159
+
160
+ var avaritia = /*#__PURE__*/Object.freeze({
161
+ __proto__: null,
162
+ addCompressor: addCompressor,
163
+ removeCompressor: removeCompressor,
164
+ addExtreme: addExtreme,
165
+ removeExtreme: removeExtreme
166
+ });
167
+
168
+ const clamp = (min, max, n) => Math.max(min, Math.min(max, n));
169
+ const fill = (n, x) => Array.from({ length: n }).map((_, i) => x ?? i);
170
+
171
+ const addComposter = (recipe) => {
172
+ const out = formatArgs(recipe[0], clamp(0, 1, recipe[1]), recipe[2] && `"${recipe[2]}"`);
173
+ return `mods.exnihilo.Composting.addRecipe(${out});`;
174
+ };
175
+ const removeComposter = (ingredient) => `mods.exnihilo.Composting.removeRecipe(${ingredient});`;
176
+ const addCrucible$1 = (recipe) => `mods.exnihilo.Crucible.addRecipe(${formatArgs(...recipe)});`;
177
+ const removeCrucible$1 = (liquid) => `mods.exnihilo.Crucible.removeRecipe(${liquid});`;
178
+ const addCrucibleSource = (recipe) => {
179
+ const out = formatArgs(recipe[0], clamp(0, 1, recipe[1]));
180
+ return `mods.exnihilo.Crucible.addHeatSource(${out});`;
181
+ };
182
+ const removeCrucibleSource = (ingredient) => `mods.exnihilo.Crucible.removeHeatSource(${ingredient});`;
183
+ const addHammer = (ingredient, recipe) => {
184
+ const items = Object.entries(recipe).map((entry) => entry[1].map((chance) => ({
185
+ ingredient: entry[0],
186
+ chance: clamp(0, 1, Array.isArray(chance) ? chance[0] : chance),
187
+ modifier: Array.isArray(chance) ? chance[1] : 1
188
+ }))).flat();
189
+ const out = formatArgs(ingredient, items.map((item) => item.ingredient), items.map((item) => item.chance), items.map((item) => item.modifier));
190
+ return `mods.exnihilo.Hammer.addRecipe(${out});`;
191
+ };
192
+ const removeHammer = (ingredient) => `mods.exnihilo.Hammer.removeRecipe(${ingredient});`;
193
+ const addSieve = (ingredient, recipe) => {
194
+ const items = Object.entries(recipe).map((entry) => fill(Math.ceil(entry[1])).map((i) => ({
195
+ ingredient: entry[0],
196
+ chance: entry[1] - i < 1 ? Math.round(1 / (entry[1] - i)) : 1
197
+ }))).flat();
198
+ const out = formatArgs(ingredient, items.map((item) => item.ingredient), items.map((item) => item.chance));
199
+ return `mods.exnihilo.Sieve.addRecipe(${out});`;
200
+ };
201
+ const removeSieve = (ingredient) => `mods.exnihilo.Sieve.removeRecipe(${ingredient});`;
202
+
203
+ var exNihilo = /*#__PURE__*/Object.freeze({
204
+ __proto__: null,
205
+ addComposter: addComposter,
206
+ removeComposter: removeComposter,
207
+ addCrucible: addCrucible$1,
208
+ removeCrucible: removeCrucible$1,
209
+ addCrucibleSource: addCrucibleSource,
210
+ removeCrucibleSource: removeCrucibleSource,
211
+ addHammer: addHammer,
212
+ removeHammer: removeHammer,
213
+ addSieve: addSieve,
214
+ removeSieve: removeSieve
215
+ });
216
+
217
+ const addQED = (item, recipe) => `mods.extraUtils.QED.addShapedRecipe(${formatArgs(item, recipe)});`;
218
+ const removeQED = (ingredient) => `mods.extraUtils.QED.removeRecipe(${ingredient});`;
219
+
220
+ var extraUtilites = /*#__PURE__*/Object.freeze({
221
+ __proto__: null,
222
+ addQED: addQED,
223
+ removeQED: removeQED
224
+ });
225
+
226
+ const withName = (ingredient, name) => `${ingredient}.displayName = ${formatName(name)};`;
227
+ const withTooltip = (ingredient, tooltip) => `${ingredient}.addTooltip(${formatTooltip(tooltip)});`;
228
+ const withTooltipShift = (ingredient, tooltip) => `${ingredient}.addShiftTooltip(${formatTooltip(tooltip)});`;
229
+ const withTag = (tag) => (ingredient) => `${ingredient}.withTag(${tag});`;
230
+ const withEnchantments = (enchantments) => withTag(`{ ench: ${formatList(enchantments.map(formatEnchantment))} }`);
231
+
232
+ var items = /*#__PURE__*/Object.freeze({
233
+ __proto__: null,
234
+ withName: withName,
235
+ withTooltip: withTooltip,
236
+ withTooltipShift: withTooltipShift,
237
+ withTag: withTag,
238
+ withEnchantments: withEnchantments
239
+ });
240
+
241
+ const hide = (ingredient) => `NEI.hide(${ingredient});`;
242
+ const add$1 = (ingredient) => `NEI.addEntry(${ingredient});`;
243
+
244
+ var nei = /*#__PURE__*/Object.freeze({
245
+ __proto__: null,
246
+ hide: hide,
247
+ add: add$1
248
+ });
249
+
250
+ const addLaser = (item) => `MiningLaser.addOre(${formatArgs(item)});`;
251
+ const removeLaser = (ingredient) => `MiningLaser.removeOre(${ingredient});`;
252
+ const addLaserPreferred = (lens, ingredients) => ingredients.map((ingredient) => `MiningLaser.addPreferredOre(${formatArgs(MFR_LASER_LENSES[lens], ingredient)});`).join("\n");
253
+ const removedLaserPreferred = (lens, ingredient) => `MiningLaser.removePreferredOre(${formatArgs(MFR_LASER_LENSES[lens], ingredient)});`;
254
+
255
+ var mineFactoryReloaded = /*#__PURE__*/Object.freeze({
256
+ __proto__: null,
257
+ addLaser: addLaser,
258
+ removeLaser: removeLaser,
259
+ addLaserPreferred: addLaserPreferred,
260
+ removedLaserPreferred: removedLaserPreferred
261
+ });
262
+
263
+ const addCrucible = (recipe) => {
264
+ const out = formatArgs(recipe.rf, recipe.in, recipe.liquid);
265
+ return `mods.thermalexpansion.Crucible.addRecipe(${out});`;
266
+ };
267
+ const removeCrucible = (ingredient) => `mods.thermalexpansion.Crucible.removeRecipe(${ingredient});`;
268
+ const addFurnace$1 = (recipe) => {
269
+ const out = formatArgs(recipe.rf, recipe.in, recipe.out);
270
+ return `mods.thermalexpansion.Furnace.addRecipe(${out});`;
271
+ };
272
+ const removeFurnace$1 = (ingredient) => `mods.thermalexpansion.Furnace.removeRecipe(${ingredient});`;
273
+ const addInsolator = (recipe) => {
274
+ const out = formatArgs(recipe.rf, recipe.left, recipe.right, recipe.out, recipe.bonus);
275
+ return `mods.thermalexpansion.Insolator.addRecipe(${out});`;
276
+ };
277
+ const removeInsolator = (left, right) => `mods.thermalexpansion.Insolator.removeRecipe(${formatArgs(left, right)});`;
278
+ const addPulverizer = (recipe) => {
279
+ const out = formatArgs(recipe.rf, recipe.in, recipe.out, recipe.bonus);
280
+ return `mods.thermalexpansion.Pulverizer.addRecipe(${out});`;
281
+ };
282
+ const removePulverizer = (ingredient) => `mods.thermalexpansion.Pulverizer.removeRecipe(${ingredient});`;
283
+ const addSawmill = (recipe) => {
284
+ const out = formatArgs(recipe.rf, recipe.in, recipe.out, recipe.bonus);
285
+ return `mods.thermalexpansion.Sawmill.addRecipe(${out});`;
286
+ };
287
+ const removeSawmill = (ingredient) => `mods.thermalexpansion.Sawmill.removeRecipe(${ingredient});`;
288
+ const addSmelter = (recipe) => {
289
+ const out = formatArgs(recipe.rf, recipe.right, recipe.left, recipe.out, recipe.bonus);
290
+ return `mods.thermalexpansion.Smelter.addRecipe(${out});`;
291
+ };
292
+ const removeSmelter = (left, right) => `mods.thermalexpansion.Smelter.removeRecipe(${formatArgs(left, right)});`;
293
+ const addTransposerFill = (recipe) => {
294
+ const out = formatArgs(recipe.rf, recipe.in, recipe.out, recipe.liquid);
295
+ return `mods.thermalexpansion.Transposer.addFillRecipe(${out});`;
296
+ };
297
+ const removeTransposerFill = (ingredient, liquid) => `mods.thermalexpansion.Transposer.removeFillRecipe(${formatArgs(ingredient, liquid)});`;
298
+ const addTransposerExtract = (recipe) => {
299
+ const out = formatArgs(recipe.rf, recipe.in, recipe.liquid, recipe.bonus);
300
+ return `mods.thermalexpansion.Transposer.addExtractRecipe(${out});`;
301
+ };
302
+ const removeTransposerExtract = (ingredient) => `mods.thermalexpansion.Transposer.removeExtractRecipe(${ingredient});`;
303
+
304
+ var thermalexpansion = /*#__PURE__*/Object.freeze({
305
+ __proto__: null,
306
+ addCrucible: addCrucible,
307
+ removeCrucible: removeCrucible,
308
+ addFurnace: addFurnace$1,
309
+ removeFurnace: removeFurnace$1,
310
+ addInsolator: addInsolator,
311
+ removeInsolator: removeInsolator,
312
+ addPulverizer: addPulverizer,
313
+ removePulverizer: removePulverizer,
314
+ addSawmill: addSawmill,
315
+ removeSawmill: removeSawmill,
316
+ addSmelter: addSmelter,
317
+ removeSmelter: removeSmelter,
318
+ addTransposerFill: addTransposerFill,
319
+ removeTransposerFill: removeTransposerFill,
320
+ addTransposerExtract: addTransposerExtract,
321
+ removeTransposerExtract: removeTransposerExtract
322
+ });
323
+
324
+ const add = (item, recipe) => {
325
+ const type = Array.isArray(recipe) ? "Shapeless" : "Shaped";
326
+ return `recipes.add${type}(${formatArgs(item, recipe)});`;
327
+ };
328
+ const remove = (ingredient) => `recipes.remove(${ingredient});`;
329
+ const removeShaped = (ingredient) => `recipes.removeShaped(${ingredient});`;
330
+ const removeShapeless = (ingredient) => `recipes.removeShapeless(${ingredient});`;
331
+ const addFurnace = (recipe) => `furnace.addRecipe(${formatArgs(recipe.out, recipe.in)});`;
332
+ const removeFurnace = (ingredient) => `furnace.remove(${ingredient});`;
333
+
334
+ var vanilla = /*#__PURE__*/Object.freeze({
335
+ __proto__: null,
336
+ add: add,
337
+ remove: remove,
338
+ removeShaped: removeShaped,
339
+ removeShapeless: removeShapeless,
340
+ addFurnace: addFurnace,
341
+ removeFurnace: removeFurnace
342
+ });
343
+
344
+ var index = {
345
+ avaritia,
346
+ exNihilo,
347
+ extraUtilites,
348
+ items,
349
+ mineFactoryReloaded,
350
+ nei,
351
+ thermalexpansion,
352
+ vanilla
353
+ };
354
+
355
+ module.exports = index;