Skip to content

Commit 4a5f2f5

Browse files
committed
Add data generation
1 parent d7e4b27 commit 4a5f2f5

312 files changed

Lines changed: 5132 additions & 223 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 0 additions & 109 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
package github.killarexe.copper_extension;
22

33
import net.minecraft.world.effect.MobEffectInstance;
4-
import net.minecraft.world.effect.MobEffects;
54
import net.minecraft.world.item.Item;
6-
import net.minecraft.world.item.Items;
75
import oshi.util.tuples.Pair;
86

97
import java.util.HashMap;
@@ -12,111 +10,4 @@ public class CEMaps {
1210
public static final HashMap<Item, Pair<Item, Float>> OXIDATION_MAP_ITEMS = new HashMap<>();
1311
public static final HashMap<Item, Item> WAXING_MAP_ITEMS = new HashMap<>();
1412
public static final HashMap<Item, MobEffectInstance> ARMOR_EFFECTS = new HashMap<>();
15-
16-
static {
17-
OXIDATION_MAP_ITEMS.put(Items.COPPER_BLOCK, new Pair<>(Items.EXPOSED_COPPER, 1.0f));
18-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_COPPER, new Pair<>(Items.WEATHERED_COPPER, 1.0f));
19-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_COPPER, new Pair<>(Items.OXIDIZED_COPPER, 1.0f));
20-
21-
OXIDATION_MAP_ITEMS.put(Items.CUT_COPPER, new Pair<>(Items.EXPOSED_CUT_COPPER, 1.0f));
22-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_CUT_COPPER, new Pair<>(Items.WEATHERED_CUT_COPPER, 1.0f));
23-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_CUT_COPPER, new Pair<>(Items.OXIDIZED_CUT_COPPER, 1.0f));
24-
25-
OXIDATION_MAP_ITEMS.put(Items.CUT_COPPER_SLAB, new Pair<>(Items.EXPOSED_CUT_COPPER_SLAB, 1.0f));
26-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_CUT_COPPER_SLAB, new Pair<>(Items.WEATHERED_CUT_COPPER_SLAB, 1.0f));
27-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_CUT_COPPER_SLAB, new Pair<>(Items.OXIDIZED_CUT_COPPER_SLAB, 1.0f));
28-
29-
OXIDATION_MAP_ITEMS.put(Items.CUT_COPPER_STAIRS, new Pair<>(Items.EXPOSED_CUT_COPPER_STAIRS, 1.0f));
30-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_CUT_COPPER_STAIRS, new Pair<>(Items.WEATHERED_CUT_COPPER_STAIRS, 1.0f));
31-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_CUT_COPPER_STAIRS, new Pair<>(Items.OXIDIZED_CUT_COPPER_STAIRS, 1.0f));
32-
33-
OXIDATION_MAP_ITEMS.put(Items.COPPER_BULB, new Pair<>(Items.EXPOSED_COPPER_BULB, 1.0f));
34-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_COPPER_BULB, new Pair<>(Items.WEATHERED_COPPER_BULB, 1.0f));
35-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_COPPER_BULB, new Pair<>(Items.OXIDIZED_COPPER_BULB, 1.0f));
36-
37-
OXIDATION_MAP_ITEMS.put(Items.COPPER_DOOR, new Pair<>(Items.EXPOSED_COPPER_DOOR, 1.0f));
38-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_COPPER_DOOR, new Pair<>(Items.WEATHERED_COPPER_DOOR, 1.0f));
39-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_COPPER_DOOR, new Pair<>(Items.OXIDIZED_COPPER_DOOR, 1.0f));
40-
41-
OXIDATION_MAP_ITEMS.put(Items.COPPER_GRATE, new Pair<>(Items.EXPOSED_COPPER_GRATE, 1.0f));
42-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_COPPER_GRATE, new Pair<>(Items.WEATHERED_COPPER_GRATE, 1.0f));
43-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_COPPER_GRATE, new Pair<>(Items.OXIDIZED_COPPER_GRATE, 1.0f));
44-
45-
OXIDATION_MAP_ITEMS.put(Items.COPPER_TRAPDOOR, new Pair<>(Items.EXPOSED_COPPER_TRAPDOOR, 1.0f));
46-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_COPPER_TRAPDOOR, new Pair<>(Items.WEATHERED_COPPER_TRAPDOOR, 1.0f));
47-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_COPPER_TRAPDOOR, new Pair<>(Items.OXIDIZED_COPPER_TRAPDOOR, 1.0f));
48-
49-
OXIDATION_MAP_ITEMS.put(Items.CHISELED_COPPER, new Pair<>(Items.EXPOSED_CHISELED_COPPER, 1.0f));
50-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_CHISELED_COPPER, new Pair<>(Items.WEATHERED_CHISELED_COPPER, 1.0f));
51-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_CHISELED_COPPER, new Pair<>(Items.OXIDIZED_CHISELED_COPPER, 1.0f));
52-
53-
OXIDATION_MAP_ITEMS.put(Items.COPPER_LANTERN.unaffected(), new Pair<>(Items.COPPER_LANTERN.exposed(), 1.0f));
54-
OXIDATION_MAP_ITEMS.put(Items.COPPER_LANTERN.exposed(), new Pair<>(Items.COPPER_LANTERN.weathered(), 1.0f));
55-
OXIDATION_MAP_ITEMS.put(Items.COPPER_LANTERN.weathered(), new Pair<>(Items.COPPER_LANTERN.oxidized(), 1.0f));
56-
57-
OXIDATION_MAP_ITEMS.put(Items.COPPER_CHEST, new Pair<>(Items.EXPOSED_COPPER_CHEST, 1.0f));
58-
OXIDATION_MAP_ITEMS.put(Items.EXPOSED_COPPER_CHEST, new Pair<>(Items.WEATHERED_COPPER_CHEST, 1.0f));
59-
OXIDATION_MAP_ITEMS.put(Items.WEATHERED_COPPER_CHEST, new Pair<>(Items.OXIDIZED_COPPER_CHEST, 1.0f));
60-
61-
62-
WAXING_MAP_ITEMS.put(Items.COPPER_BLOCK, Items.WAXED_COPPER_BLOCK);
63-
WAXING_MAP_ITEMS.put(Items.EXPOSED_COPPER, Items.WAXED_EXPOSED_COPPER);
64-
WAXING_MAP_ITEMS.put(Items.WEATHERED_COPPER, Items.WAXED_WEATHERED_COPPER);
65-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_COPPER, Items.WAXED_WEATHERED_COPPER);
66-
67-
WAXING_MAP_ITEMS.put(Items.CUT_COPPER, Items.WAXED_CUT_COPPER);
68-
WAXING_MAP_ITEMS.put(Items.EXPOSED_CUT_COPPER, Items.WAXED_EXPOSED_CUT_COPPER);
69-
WAXING_MAP_ITEMS.put(Items.WEATHERED_CUT_COPPER, Items.WAXED_WEATHERED_CUT_COPPER);
70-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_CUT_COPPER, Items.WAXED_OXIDIZED_CUT_COPPER);
71-
72-
WAXING_MAP_ITEMS.put(Items.CUT_COPPER_SLAB, Items.WAXED_CUT_COPPER_SLAB);
73-
WAXING_MAP_ITEMS.put(Items.EXPOSED_CUT_COPPER_SLAB, Items.WAXED_EXPOSED_CUT_COPPER_SLAB);
74-
WAXING_MAP_ITEMS.put(Items.WEATHERED_CUT_COPPER_SLAB, Items.WAXED_WEATHERED_CUT_COPPER_SLAB);
75-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_CUT_COPPER_SLAB, Items.WAXED_OXIDIZED_CUT_COPPER_SLAB);
76-
77-
WAXING_MAP_ITEMS.put(Items.CUT_COPPER_STAIRS, Items.WAXED_CUT_COPPER_STAIRS);
78-
WAXING_MAP_ITEMS.put(Items.EXPOSED_CUT_COPPER_STAIRS, Items.WAXED_EXPOSED_CUT_COPPER_STAIRS);
79-
WAXING_MAP_ITEMS.put(Items.WEATHERED_CUT_COPPER_STAIRS, Items.WAXED_WEATHERED_CUT_COPPER_STAIRS);
80-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_CUT_COPPER_STAIRS, Items.WAXED_OXIDIZED_CUT_COPPER_STAIRS);
81-
82-
WAXING_MAP_ITEMS.put(Items.COPPER_BULB, Items.WAXED_COPPER_BULB);
83-
WAXING_MAP_ITEMS.put(Items.EXPOSED_COPPER_BULB, Items.WAXED_EXPOSED_COPPER_BULB);
84-
WAXING_MAP_ITEMS.put(Items.WEATHERED_COPPER_BULB, Items.WAXED_WEATHERED_COPPER_BULB);
85-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_COPPER_BULB, Items.WAXED_OXIDIZED_COPPER_BULB);
86-
87-
WAXING_MAP_ITEMS.put(Items.COPPER_DOOR, Items.WAXED_COPPER_DOOR);
88-
WAXING_MAP_ITEMS.put(Items.EXPOSED_COPPER_DOOR, Items.WAXED_EXPOSED_COPPER_DOOR);
89-
WAXING_MAP_ITEMS.put(Items.WEATHERED_COPPER_DOOR, Items.WAXED_WEATHERED_COPPER_DOOR);
90-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_COPPER_DOOR, Items.WAXED_OXIDIZED_COPPER_DOOR);
91-
92-
WAXING_MAP_ITEMS.put(Items.COPPER_GRATE, Items.WAXED_COPPER_GRATE);
93-
WAXING_MAP_ITEMS.put(Items.EXPOSED_COPPER_GRATE, Items.WAXED_EXPOSED_COPPER_GRATE);
94-
WAXING_MAP_ITEMS.put(Items.WEATHERED_COPPER_GRATE, Items.WAXED_WEATHERED_COPPER_GRATE);
95-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_COPPER_GRATE, Items.WAXED_OXIDIZED_COPPER_GRATE);
96-
97-
WAXING_MAP_ITEMS.put(Items.COPPER_TRAPDOOR, Items.WAXED_COPPER_TRAPDOOR);
98-
WAXING_MAP_ITEMS.put(Items.EXPOSED_COPPER_TRAPDOOR, Items.WAXED_EXPOSED_COPPER_TRAPDOOR);
99-
WAXING_MAP_ITEMS.put(Items.WEATHERED_COPPER_TRAPDOOR, Items.WAXED_WEATHERED_COPPER_TRAPDOOR);
100-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_COPPER_TRAPDOOR, Items.WAXED_OXIDIZED_COPPER_TRAPDOOR);
101-
102-
WAXING_MAP_ITEMS.put(Items.CHISELED_COPPER, Items.WAXED_CHISELED_COPPER);
103-
WAXING_MAP_ITEMS.put(Items.EXPOSED_CHISELED_COPPER, Items.WAXED_EXPOSED_CHISELED_COPPER);
104-
WAXING_MAP_ITEMS.put(Items.WEATHERED_CHISELED_COPPER, Items.WAXED_WEATHERED_CHISELED_COPPER);
105-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_CHISELED_COPPER, Items.WAXED_OXIDIZED_CHISELED_COPPER);
106-
107-
WAXING_MAP_ITEMS.put(Items.COPPER_LANTERN.unaffected(), Items.COPPER_LANTERN.waxed());
108-
WAXING_MAP_ITEMS.put(Items.COPPER_LANTERN.exposed(), Items.COPPER_LANTERN.waxedExposed());
109-
WAXING_MAP_ITEMS.put(Items.COPPER_LANTERN.weathered(), Items.COPPER_LANTERN.waxedWeathered());
110-
WAXING_MAP_ITEMS.put(Items.COPPER_LANTERN.oxidized(), Items.COPPER_LANTERN.waxedOxidized());
111-
112-
WAXING_MAP_ITEMS.put(Items.COPPER_CHEST, Items.WAXED_COPPER_CHEST);
113-
WAXING_MAP_ITEMS.put(Items.EXPOSED_COPPER_CHEST, Items.WAXED_EXPOSED_COPPER_CHEST);
114-
WAXING_MAP_ITEMS.put(Items.WEATHERED_COPPER_CHEST, Items.WAXED_WEATHERED_COPPER_CHEST);
115-
WAXING_MAP_ITEMS.put(Items.OXIDIZED_COPPER_CHEST, Items.WAXED_OXIDIZED_COPPER_CHEST);
116-
117-
ARMOR_EFFECTS.put(Items.COPPER_HELMET, new MobEffectInstance(MobEffects.HASTE, 600, 0));
118-
ARMOR_EFFECTS.put(Items.COPPER_CHESTPLATE, new MobEffectInstance(MobEffects.HASTE, 600, 0));
119-
ARMOR_EFFECTS.put(Items.COPPER_LEGGINGS, new MobEffectInstance(MobEffects.HASTE, 600, 0));
120-
ARMOR_EFFECTS.put(Items.COPPER_BOOTS, new MobEffectInstance(MobEffects.HASTE, 600, 0));
121-
}
12213
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"parent": "minecraft:recipes/root",
3+
"criteria": {
4+
"has_exposed_copper_ingot": {
5+
"conditions": {
6+
"items": [
7+
{
8+
"items": "copper_extension:exposed_copper_ingot"
9+
}
10+
]
11+
},
12+
"trigger": "minecraft:inventory_changed"
13+
},
14+
"has_the_recipe": {
15+
"conditions": {
16+
"recipe": "copper_extension:exposed_copper_boots"
17+
},
18+
"trigger": "minecraft:recipe_unlocked"
19+
}
20+
},
21+
"requirements": [
22+
[
23+
"has_the_recipe",
24+
"has_exposed_copper_ingot"
25+
]
26+
],
27+
"rewards": {
28+
"recipes": [
29+
"copper_extension:exposed_copper_boots"
30+
]
31+
}
32+
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"parent": "minecraft:recipes/root",
3+
"criteria": {
4+
"has_exposed_copper_ingot": {
5+
"conditions": {
6+
"items": [
7+
{
8+
"items": "copper_extension:exposed_copper_ingot"
9+
}
10+
]
11+
},
12+
"trigger": "minecraft:inventory_changed"
13+
},
14+
"has_the_recipe": {
15+
"conditions": {
16+
"recipe": "copper_extension:exposed_copper_chestplate"
17+
},
18+
"trigger": "minecraft:recipe_unlocked"
19+
}
20+
},
21+
"requirements": [
22+
[
23+
"has_the_recipe",
24+
"has_exposed_copper_ingot"
25+
]
26+
],
27+
"rewards": {
28+
"recipes": [
29+
"copper_extension:exposed_copper_chestplate"
30+
]
31+
}
32+
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"parent": "minecraft:recipes/root",
3+
"criteria": {
4+
"has_exposed_copper_ingot": {
5+
"conditions": {
6+
"items": [
7+
{
8+
"items": "copper_extension:exposed_copper_ingot"
9+
}
10+
]
11+
},
12+
"trigger": "minecraft:inventory_changed"
13+
},
14+
"has_the_recipe": {
15+
"conditions": {
16+
"recipe": "copper_extension:exposed_copper_helmet"
17+
},
18+
"trigger": "minecraft:recipe_unlocked"
19+
}
20+
},
21+
"requirements": [
22+
[
23+
"has_the_recipe",
24+
"has_exposed_copper_ingot"
25+
]
26+
],
27+
"rewards": {
28+
"recipes": [
29+
"copper_extension:exposed_copper_helmet"
30+
]
31+
}
32+
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"parent": "minecraft:recipes/root",
3+
"criteria": {
4+
"has_exposed_copper_ingot": {
5+
"conditions": {
6+
"items": [
7+
{
8+
"items": "copper_extension:exposed_copper_ingot"
9+
}
10+
]
11+
},
12+
"trigger": "minecraft:inventory_changed"
13+
},
14+
"has_the_recipe": {
15+
"conditions": {
16+
"recipe": "copper_extension:exposed_copper_leggings"
17+
},
18+
"trigger": "minecraft:recipe_unlocked"
19+
}
20+
},
21+
"requirements": [
22+
[
23+
"has_the_recipe",
24+
"has_exposed_copper_ingot"
25+
]
26+
],
27+
"rewards": {
28+
"recipes": [
29+
"copper_extension:exposed_copper_leggings"
30+
]
31+
}
32+
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"parent": "minecraft:recipes/root",
3+
"criteria": {
4+
"has_exposed_copper_ingot": {
5+
"conditions": {
6+
"items": [
7+
{
8+
"items": "copper_extension:exposed_copper_ingot"
9+
}
10+
]
11+
},
12+
"trigger": "minecraft:inventory_changed"
13+
},
14+
"has_the_recipe": {
15+
"conditions": {
16+
"recipe": "copper_extension:exposed_copper_pickaxe"
17+
},
18+
"trigger": "minecraft:recipe_unlocked"
19+
}
20+
},
21+
"requirements": [
22+
[
23+
"has_the_recipe",
24+
"has_exposed_copper_ingot"
25+
]
26+
],
27+
"rewards": {
28+
"recipes": [
29+
"copper_extension:exposed_copper_pickaxe"
30+
]
31+
}
32+
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"parent": "minecraft:recipes/root",
3+
"criteria": {
4+
"has_exposed_copper_ingot": {
5+
"conditions": {
6+
"items": [
7+
{
8+
"items": "copper_extension:exposed_copper_ingot"
9+
}
10+
]
11+
},
12+
"trigger": "minecraft:inventory_changed"
13+
},
14+
"has_the_recipe": {
15+
"conditions": {
16+
"recipe": "copper_extension:exposed_copper_sword"
17+
},
18+
"trigger": "minecraft:recipe_unlocked"
19+
}
20+
},
21+
"requirements": [
22+
[
23+
"has_the_recipe",
24+
"has_exposed_copper_ingot"
25+
]
26+
],
27+
"rewards": {
28+
"recipes": [
29+
"copper_extension:exposed_copper_sword"
30+
]
31+
}
32+
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"parent": "minecraft:recipes/root",
3+
"criteria": {
4+
"has_oxidized_copper_ingot": {
5+
"conditions": {
6+
"items": [
7+
{
8+
"items": "copper_extension:oxidized_copper_ingot"
9+
}
10+
]
11+
},
12+
"trigger": "minecraft:inventory_changed"
13+
},
14+
"has_the_recipe": {
15+
"conditions": {
16+
"recipe": "copper_extension:oxidized_copper_boots"
17+
},
18+
"trigger": "minecraft:recipe_unlocked"
19+
}
20+
},
21+
"requirements": [
22+
[
23+
"has_the_recipe",
24+
"has_oxidized_copper_ingot"
25+
]
26+
],
27+
"rewards": {
28+
"recipes": [
29+
"copper_extension:oxidized_copper_boots"
30+
]
31+
}
32+
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"parent": "minecraft:recipes/root",
3+
"criteria": {
4+
"has_oxidized_copper_ingot": {
5+
"conditions": {
6+
"items": [
7+
{
8+
"items": "copper_extension:oxidized_copper_ingot"
9+
}
10+
]
11+
},
12+
"trigger": "minecraft:inventory_changed"
13+
},
14+
"has_the_recipe": {
15+
"conditions": {
16+
"recipe": "copper_extension:oxidized_copper_chestplate"
17+
},
18+
"trigger": "minecraft:recipe_unlocked"
19+
}
20+
},
21+
"requirements": [
22+
[
23+
"has_the_recipe",
24+
"has_oxidized_copper_ingot"
25+
]
26+
],
27+
"rewards": {
28+
"recipes": [
29+
"copper_extension:oxidized_copper_chestplate"
30+
]
31+
}
32+
}

0 commit comments

Comments
 (0)