Skip to content

Commit

Permalink
Ensure consistent data generation ordering from TemplateBuilder
Browse files Browse the repository at this point in the history
  • Loading branch information
Gegy committed Oct 13, 2024
1 parent dff895b commit 78d848f
Show file tree
Hide file tree
Showing 7 changed files with 77 additions and 75 deletions.
6 changes: 3 additions & 3 deletions src/generated/resources/data/minecraft/tags/block/fences.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"values": [
"ltextras:stone_bricks_fence",
"ltextras:rusty_painted_metal_fence",
"ltextras:gold_block_fence",
"ltextras:quartz_block_fence",
"ltextras:stone_fence",
"ltextras:stone_bricks_fence",
"ltextras:cracked_stone_bricks_fence",
"ltextras:gold_block_fence"
"ltextras:rusty_painted_metal_fence"
]
}
58 changes: 29 additions & 29 deletions src/generated/resources/data/minecraft/tags/block/stairs.json
Original file line number Diff line number Diff line change
@@ -1,44 +1,44 @@
{
"values": [
"ltextras:lime_concrete_powder_stairs",
"ltextras:orange_concrete_powder_stairs",
"ltextras:black_concrete_powder_stairs",
"ltextras:gold_block_stairs",
"ltextras:cracked_stone_bricks_stairs",
"ltextras:white_concrete_powder_stairs",
"ltextras:rusty_painted_metal_stairs",
"ltextras:red_concrete_powder_stairs",
"ltextras:blue_concrete_powder_stairs",
"ltextras:purple_concrete_powder_stairs",
"ltextras:orange_concrete_powder_stairs",
"ltextras:magenta_concrete_powder_stairs",
"ltextras:light_gray_concrete_powder_stairs",
"ltextras:cracked_stone_bricks_stairs",
"ltextras:gray_concrete_powder_stairs",
"ltextras:light_blue_concrete_powder_stairs",
"ltextras:green_concrete_powder_stairs",
"ltextras:moss_block_stairs",
"ltextras:cyan_concrete_powder_stairs",
"ltextras:gold_block_stairs",
"ltextras:yellow_concrete_powder_stairs",
"ltextras:lime_concrete_powder_stairs",
"ltextras:pink_concrete_powder_stairs",
"ltextras:gray_concrete_powder_stairs",
"ltextras:light_gray_concrete_powder_stairs",
"ltextras:cyan_concrete_powder_stairs",
"ltextras:purple_concrete_powder_stairs",
"ltextras:blue_concrete_powder_stairs",
"ltextras:brown_concrete_powder_stairs",
"ltextras:lime_concrete_powder_slab",
"ltextras:orange_concrete_powder_slab",
"ltextras:black_concrete_powder_slab",
"ltextras:green_concrete_powder_stairs",
"ltextras:red_concrete_powder_stairs",
"ltextras:black_concrete_powder_stairs",
"ltextras:rusty_painted_metal_stairs",
"ltextras:moss_block_stairs",
"ltextras:gold_block_slab",
"ltextras:cracked_stone_bricks_slab",
"ltextras:white_concrete_powder_slab",
"ltextras:rusty_painted_metal_slab",
"ltextras:red_concrete_powder_slab",
"ltextras:blue_concrete_powder_slab",
"ltextras:purple_concrete_powder_slab",
"ltextras:orange_concrete_powder_slab",
"ltextras:magenta_concrete_powder_slab",
"ltextras:light_gray_concrete_powder_slab",
"ltextras:cracked_stone_bricks_slab",
"ltextras:gray_concrete_powder_slab",
"ltextras:light_blue_concrete_powder_slab",
"ltextras:green_concrete_powder_slab",
"ltextras:moss_block_slab",
"ltextras:cyan_concrete_powder_slab",
"ltextras:gold_block_slab",
"ltextras:yellow_concrete_powder_slab",
"ltextras:lime_concrete_powder_slab",
"ltextras:pink_concrete_powder_slab",
"ltextras:brown_concrete_powder_slab"
"ltextras:gray_concrete_powder_slab",
"ltextras:light_gray_concrete_powder_slab",
"ltextras:cyan_concrete_powder_slab",
"ltextras:purple_concrete_powder_slab",
"ltextras:blue_concrete_powder_slab",
"ltextras:brown_concrete_powder_slab",
"ltextras:green_concrete_powder_slab",
"ltextras:red_concrete_powder_slab",
"ltextras:black_concrete_powder_slab",
"ltextras:rusty_painted_metal_slab",
"ltextras:moss_block_slab"
]
}
10 changes: 5 additions & 5 deletions src/generated/resources/data/minecraft/tags/block/walls.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"values": [
"ltextras:rusty_painted_metal_wall",
"ltextras:polished_diorite_wall",
"ltextras:polished_granite_wall",
"ltextras:gold_block_wall",
"ltextras:quartz_block_wall",
"ltextras:polished_andesite_wall",
"ltextras:stone_wall",
"ltextras:cracked_stone_bricks_wall",
"ltextras:gold_block_wall"
"ltextras:polished_andesite_wall",
"ltextras:polished_granite_wall",
"ltextras:polished_diorite_wall",
"ltextras:rusty_painted_metal_wall"
]
}
6 changes: 3 additions & 3 deletions src/generated/resources/data/minecraft/tags/item/fences.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"values": [
"ltextras:stone_bricks_fence",
"ltextras:rusty_painted_metal_fence",
"ltextras:gold_block_fence",
"ltextras:quartz_block_fence",
"ltextras:stone_fence",
"ltextras:stone_bricks_fence",
"ltextras:cracked_stone_bricks_fence",
"ltextras:gold_block_fence"
"ltextras:rusty_painted_metal_fence"
]
}
58 changes: 29 additions & 29 deletions src/generated/resources/data/minecraft/tags/item/stairs.json
Original file line number Diff line number Diff line change
@@ -1,44 +1,44 @@
{
"values": [
"ltextras:lime_concrete_powder_stairs",
"ltextras:orange_concrete_powder_stairs",
"ltextras:black_concrete_powder_stairs",
"ltextras:gold_block_stairs",
"ltextras:cracked_stone_bricks_stairs",
"ltextras:white_concrete_powder_stairs",
"ltextras:rusty_painted_metal_stairs",
"ltextras:red_concrete_powder_stairs",
"ltextras:blue_concrete_powder_stairs",
"ltextras:purple_concrete_powder_stairs",
"ltextras:orange_concrete_powder_stairs",
"ltextras:magenta_concrete_powder_stairs",
"ltextras:light_gray_concrete_powder_stairs",
"ltextras:cracked_stone_bricks_stairs",
"ltextras:gray_concrete_powder_stairs",
"ltextras:light_blue_concrete_powder_stairs",
"ltextras:green_concrete_powder_stairs",
"ltextras:moss_block_stairs",
"ltextras:cyan_concrete_powder_stairs",
"ltextras:gold_block_stairs",
"ltextras:yellow_concrete_powder_stairs",
"ltextras:lime_concrete_powder_stairs",
"ltextras:pink_concrete_powder_stairs",
"ltextras:gray_concrete_powder_stairs",
"ltextras:light_gray_concrete_powder_stairs",
"ltextras:cyan_concrete_powder_stairs",
"ltextras:purple_concrete_powder_stairs",
"ltextras:blue_concrete_powder_stairs",
"ltextras:brown_concrete_powder_stairs",
"ltextras:lime_concrete_powder_slab",
"ltextras:orange_concrete_powder_slab",
"ltextras:black_concrete_powder_slab",
"ltextras:green_concrete_powder_stairs",
"ltextras:red_concrete_powder_stairs",
"ltextras:black_concrete_powder_stairs",
"ltextras:rusty_painted_metal_stairs",
"ltextras:moss_block_stairs",
"ltextras:gold_block_slab",
"ltextras:cracked_stone_bricks_slab",
"ltextras:white_concrete_powder_slab",
"ltextras:rusty_painted_metal_slab",
"ltextras:red_concrete_powder_slab",
"ltextras:blue_concrete_powder_slab",
"ltextras:purple_concrete_powder_slab",
"ltextras:orange_concrete_powder_slab",
"ltextras:magenta_concrete_powder_slab",
"ltextras:light_gray_concrete_powder_slab",
"ltextras:cracked_stone_bricks_slab",
"ltextras:gray_concrete_powder_slab",
"ltextras:light_blue_concrete_powder_slab",
"ltextras:green_concrete_powder_slab",
"ltextras:moss_block_slab",
"ltextras:cyan_concrete_powder_slab",
"ltextras:gold_block_slab",
"ltextras:yellow_concrete_powder_slab",
"ltextras:lime_concrete_powder_slab",
"ltextras:pink_concrete_powder_slab",
"ltextras:brown_concrete_powder_slab"
"ltextras:gray_concrete_powder_slab",
"ltextras:light_gray_concrete_powder_slab",
"ltextras:cyan_concrete_powder_slab",
"ltextras:purple_concrete_powder_slab",
"ltextras:blue_concrete_powder_slab",
"ltextras:brown_concrete_powder_slab",
"ltextras:green_concrete_powder_slab",
"ltextras:red_concrete_powder_slab",
"ltextras:black_concrete_powder_slab",
"ltextras:rusty_painted_metal_slab",
"ltextras:moss_block_slab"
]
}
10 changes: 5 additions & 5 deletions src/generated/resources/data/minecraft/tags/item/walls.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"values": [
"ltextras:rusty_painted_metal_wall",
"ltextras:polished_diorite_wall",
"ltextras:polished_granite_wall",
"ltextras:gold_block_wall",
"ltextras:quartz_block_wall",
"ltextras:polished_andesite_wall",
"ltextras:stone_wall",
"ltextras:cracked_stone_bricks_wall",
"ltextras:gold_block_wall"
"ltextras:polished_andesite_wall",
"ltextras:polished_granite_wall",
"ltextras:polished_diorite_wall",
"ltextras:rusty_painted_metal_wall"
]
}
4 changes: 3 additions & 1 deletion src/main/java/com/lovetropics/extras/ExtraBlocks.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
import com.tterrag.registrate.util.entry.BlockEntityEntry;
import com.tterrag.registrate.util.entry.BlockEntry;
import com.tterrag.registrate.util.nullness.NonNullSupplier;
import it.unimi.dsi.fastutil.objects.Object2ObjectArrayMap;
import it.unimi.dsi.fastutil.objects.Object2ObjectLinkedOpenHashMap;
import it.unimi.dsi.fastutil.objects.Object2ObjectOpenHashMap;
import net.minecraft.client.renderer.BiomeColors;
import net.minecraft.client.renderer.RenderType;
Expand Down Expand Up @@ -920,7 +922,7 @@ private static ResourceLocation getId(Holder<?> holder) {
}

public static final class TemplateBuilder<T extends Block, P> {
private final Map<Holder<Block>, P> templates = new Object2ObjectOpenHashMap<>();
private final Map<Holder<Block>, P> templates = new Object2ObjectLinkedOpenHashMap<>();

public TemplateBuilder<T, P> add(Block block, P parameter) {
return add(block.builtInRegistryHolder(), parameter);
Expand Down

0 comments on commit 78d848f

Please sign in to comment.