Skip to content

Commit 8be6cef

Browse files
authored
Fix fuel loader and add recipe (#339)
* feat: fuel loader recipe * fix: fuel loader not being registered
1 parent 4979d91 commit 8be6cef

File tree

4 files changed

+72
-0
lines changed

4 files changed

+72
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
{
2+
"parent": "minecraft:recipes/root",
3+
"criteria": {
4+
"has_fuel_bucket": {
5+
"conditions": {
6+
"items": [
7+
{
8+
"items": [
9+
"galacticraft:fuel_bucket"
10+
]
11+
}
12+
]
13+
},
14+
"trigger": "minecraft:inventory_changed"
15+
},
16+
"has_the_recipe": {
17+
"conditions": {
18+
"recipe": "galacticraft:fuel_loader"
19+
},
20+
"trigger": "minecraft:recipe_unlocked"
21+
}
22+
},
23+
"requirements": [
24+
[
25+
"has_the_recipe",
26+
"has_fuel_bucket"
27+
]
28+
],
29+
"rewards": {
30+
"recipes": [
31+
"galacticraft:fuel_loader"
32+
]
33+
}
34+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
{
2+
"type": "minecraft:crafting_shaped",
3+
"category": "misc",
4+
"key": {
5+
"C": {
6+
"item": "galacticraft:tin_canister"
7+
},
8+
"T": {
9+
"item": "galacticraft:compressed_tin"
10+
},
11+
"U": {
12+
"item": "galacticraft:compressed_copper"
13+
},
14+
"W": {
15+
"item": "galacticraft:basic_wafer"
16+
}
17+
},
18+
"pattern": [
19+
"UUU",
20+
"UCU",
21+
"TWT"
22+
],
23+
"result": {
24+
"item": "galacticraft:fuel_loader"
25+
}
26+
}

src/main/java/dev/galacticraft/mod/data/recipes/GCMachineRecipes.java

+11
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,17 @@ public void buildRecipes(RecipeOutput output) {
236236
.unlockedBy(getHasName(GCItems.CRUDE_OIL_BUCKET), has(GCItems.CRUDE_OIL_BUCKET))
237237
.save(output);
238238

239+
ShapedRecipeBuilder.shaped(RecipeCategory.MISC, GCItems.FUEL_LOADER)
240+
.define('U', GCItems.COMPRESSED_COPPER)
241+
.define('C', GCItems.TIN_CANISTER)
242+
.define('T', GCItems.COMPRESSED_TIN)
243+
.define('W', GCItems.BASIC_WAFER)
244+
.pattern("UUU")
245+
.pattern("UCU")
246+
.pattern("TWT")
247+
.unlockedBy(getHasName(GCItems.FUEL_BUCKET), has(GCItems.FUEL_BUCKET))
248+
.save(output);
249+
239250
// Wires + Pipes
240251
ShapedRecipeBuilder.shaped(RecipeCategory.MISC, GCItems.GLASS_FLUID_PIPE, 6)
241252
.define('X', Items.GLASS_PANE)

src/main/java/dev/galacticraft/mod/lookup/GCApiLookupProviders.java

+1
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ public class GCApiLookupProviders {
5050
GCBlocks.ELECTRIC_FURNACE,
5151
GCBlocks.ELECTRIC_ARC_FURNACE,
5252
GCBlocks.REFINERY,
53+
GCBlocks.FUEL_LOADER,
5354
GCBlocks.OXYGEN_COLLECTOR,
5455
GCBlocks.OXYGEN_COMPRESSOR,
5556
GCBlocks.OXYGEN_DECOMPRESSOR,

0 commit comments

Comments
 (0)