TrailRuinsStructurePools .java

net.minecraft.data.worldgen.TrailRuinsStructurePools (class): members: START, bootstrap. strings: "trail_ruins/buildings/group_lower_1". imports: Pair.

net.minecraft.data.worldgenclass178 linescommon10.9 KB

API Surface (1)

void bootstrap(final BootstrapContext<StructureTemplatePool> context)

Fields & Constants (1)

START

String literals (91)

"trail_ruins/tower"
"trail_ruins/tower/tower_1"
"trail_ruins/tower/tower_2"
"trail_ruins/tower/tower_3"
"trail_ruins/tower/tower_4"
"trail_ruins/tower/tower_5"
"trail_ruins/tower/tower_top"
"trail_ruins/tower/tower_top_1"
"trail_ruins/tower/tower_top_2"
"trail_ruins/tower/tower_top_3"
"trail_ruins/tower/tower_top_4"
"trail_ruins/tower/tower_top_5"
"trail_ruins/tower/additions"
"trail_ruins/tower/hall_1"
"trail_ruins/tower/hall_2"
"trail_ruins/tower/hall_3"
"trail_ruins/tower/hall_4"
"trail_ruins/tower/hall_5"
"trail_ruins/tower/large_hall_1"
"trail_ruins/tower/large_hall_2"
"trail_ruins/tower/large_hall_3"
"trail_ruins/tower/large_hall_4"
"trail_ruins/tower/large_hall_5"
"trail_ruins/tower/one_room_1"

Full Source

TrailRuinsStructurePools.java178 lines · Minecraft 26.3 · verbatim
1
package net.minecraft.data.worldgen;
2
3
import com.mojang.datafixers.util.Pair;
4
import java.util.List;
5
import net.minecraft.core.Holder;
6
import net.minecraft.core.HolderGetter;
7
import net.minecraft.core.registries.Registries;
8
import net.minecraft.resources.ResourceKey;
9
import net.minecraft.world.level.levelgen.structure.pools.StructurePoolElement;
10
import net.minecraft.world.level.levelgen.structure.pools.StructureTemplatePool;
11
import net.minecraft.world.level.levelgen.structure.templatesystem.StructureProcessorList;
12
13
public class TrailRuinsStructurePools {
14
	public static final ResourceKey<StructureTemplatePool> START = Pools.createKey("trail_ruins/tower");
15
16
	public static void bootstrap(final BootstrapContext<StructureTemplatePool> context) {
17
		HolderGetter<StructureTemplatePool> pools = context.lookup(Registries.TEMPLATE_POOL);
18
		Holder<StructureTemplatePool> empty = pools.getOrThrow(Pools.EMPTY);
19
		HolderGetter<StructureProcessorList> processorLists = context.lookup(Registries.PROCESSOR_LIST);
20
		Holder<StructureProcessorList> housesArchyProcessor = processorLists.getOrThrow(ProcessorLists.TRAIL_RUINS_HOUSES_ARCHAEOLOGY);
21
		Holder<StructureProcessorList> roadsArchyProcessor = processorLists.getOrThrow(ProcessorLists.TRAIL_RUINS_ROADS_ARCHAEOLOGY);
22
		Holder<StructureProcessorList> towerTopArchyProcessor = processorLists.getOrThrow(ProcessorLists.TRAIL_RUINS_TOWER_TOP_ARCHAEOLOGY);
23
		context.register(
24
			START,
25
			new StructureTemplatePool(
26
				empty,
27
				List.of(
28
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_1", housesArchyProcessor), 1),
29
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_2", housesArchyProcessor), 1),
30
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_3", housesArchyProcessor), 1),
31
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_4", housesArchyProcessor), 1),
32
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_5", housesArchyProcessor), 1)
33
				),
34
				StructureTemplatePool.Projection.RIGID
35
			)
36
		);
37
		Pools.register(
38
			context,
39
			"trail_ruins/tower/tower_top",
40
			new StructureTemplatePool(
41
				empty,
42
				List.of(
43
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_top_1", towerTopArchyProcessor), 1),
44
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_top_2", towerTopArchyProcessor), 1),
45
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_top_3", towerTopArchyProcessor), 1),
46
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_top_4", towerTopArchyProcessor), 1),
47
					Pair.of(StructurePoolElement.single("trail_ruins/tower/tower_top_5", towerTopArchyProcessor), 1)
48
				),
49
				StructureTemplatePool.Projection.RIGID
50
			)
51
		);
52
		Pools.register(
53
			context,
54
			"trail_ruins/tower/additions",
55
			new StructureTemplatePool(
56
				empty,
57
				List.of(
58
					Pair.of(StructurePoolElement.single("trail_ruins/tower/hall_1", housesArchyProcessor), 1),
59
					Pair.of(StructurePoolElement.single("trail_ruins/tower/hall_2", housesArchyProcessor), 1),
60
					Pair.of(StructurePoolElement.single("trail_ruins/tower/hall_3", housesArchyProcessor), 1),
61
					Pair.of(StructurePoolElement.single("trail_ruins/tower/hall_4", housesArchyProcessor), 1),
62
					Pair.of(StructurePoolElement.single("trail_ruins/tower/hall_5", housesArchyProcessor), 1),
63
					Pair.of(StructurePoolElement.single("trail_ruins/tower/large_hall_1", housesArchyProcessor), 1),
64
					Pair.of(StructurePoolElement.single("trail_ruins/tower/large_hall_2", housesArchyProcessor), 1),
65
					Pair.of(StructurePoolElement.single("trail_ruins/tower/large_hall_3", housesArchyProcessor), 1),
66
					Pair.of(StructurePoolElement.single("trail_ruins/tower/large_hall_4", housesArchyProcessor), 1),
67
					Pair.of(StructurePoolElement.single("trail_ruins/tower/large_hall_5", housesArchyProcessor), 1),
68
					Pair.of(StructurePoolElement.single("trail_ruins/tower/one_room_1", housesArchyProcessor), 1),
69
					Pair.of(StructurePoolElement.single("trail_ruins/tower/one_room_2", housesArchyProcessor), 1),
70
					Pair.of(StructurePoolElement.single("trail_ruins/tower/one_room_3", housesArchyProcessor), 1),
71
					Pair.of(StructurePoolElement.single("trail_ruins/tower/one_room_4", housesArchyProcessor), 1),
72
					Pair.of(StructurePoolElement.single("trail_ruins/tower/one_room_5", housesArchyProcessor), 1),
73
					Pair.of(StructurePoolElement.single("trail_ruins/tower/platform_1", housesArchyProcessor), 1),
74
					Pair.of(StructurePoolElement.single("trail_ruins/tower/platform_2", housesArchyProcessor), 1),
75
					Pair.of(StructurePoolElement.single("trail_ruins/tower/platform_3", housesArchyProcessor), 1),
76
					Pair.of(StructurePoolElement.single("trail_ruins/tower/platform_4", housesArchyProcessor), 1),
77
					Pair.of(StructurePoolElement.single("trail_ruins/tower/platform_5", housesArchyProcessor), 1),
78
					Pair.of(StructurePoolElement.single("trail_ruins/tower/stable_1", housesArchyProcessor), 1),
79
					Pair.of(StructurePoolElement.single("trail_ruins/tower/stable_2", housesArchyProcessor), 1),
80
					Pair.of(StructurePoolElement.single("trail_ruins/tower/stable_3", housesArchyProcessor), 1),
81
					Pair.of(StructurePoolElement.single("trail_ruins/tower/stable_4", housesArchyProcessor), 1),
82
					Pair.of(StructurePoolElement.single("trail_ruins/tower/stable_5", housesArchyProcessor), 1)
83
				),
84
				StructureTemplatePool.Projection.RIGID
85
			)
86
		);
87
		Pools.register(
88
			context,
89
			"trail_ruins/roads",
90
			new StructureTemplatePool(
91
				empty,
92
				List.of(
93
					Pair.of(StructurePoolElement.single("trail_ruins/roads/long_road_end", roadsArchyProcessor), 1),
94
					Pair.of(StructurePoolElement.single("trail_ruins/roads/road_end_1", roadsArchyProcessor), 1),
95
					Pair.of(StructurePoolElement.single("trail_ruins/roads/road_section_1", roadsArchyProcessor), 1),
96
					Pair.of(StructurePoolElement.single("trail_ruins/roads/road_section_2", roadsArchyProcessor), 1),
97
					Pair.of(StructurePoolElement.single("trail_ruins/roads/road_section_3", roadsArchyProcessor), 1),
98
					Pair.of(StructurePoolElement.single("trail_ruins/roads/road_section_4", roadsArchyProcessor), 1),
99
					Pair.of(StructurePoolElement.single("trail_ruins/roads/road_spacer_1", roadsArchyProcessor), 1)
100
				),
101
				StructureTemplatePool.Projection.RIGID
102
			)
103
		);
104
		Pools.register(
105
			context,
106
			"trail_ruins/buildings",
107
			new StructureTemplatePool(
108
				empty,
109
				List.of(
110
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_hall_1", housesArchyProcessor), 1),
111
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_hall_2", housesArchyProcessor), 1),
112
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_hall_3", housesArchyProcessor), 1),
113
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_hall_4", housesArchyProcessor), 1),
114
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_hall_5", housesArchyProcessor), 1),
115
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/large_room_1", housesArchyProcessor), 1),
116
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/large_room_2", housesArchyProcessor), 1),
117
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/large_room_3", housesArchyProcessor), 1),
118
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/large_room_4", housesArchyProcessor), 1),
119
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/large_room_5", housesArchyProcessor), 1),
120
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/one_room_1", housesArchyProcessor), 1),
121
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/one_room_2", housesArchyProcessor), 1),
122
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/one_room_3", housesArchyProcessor), 1),
123
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/one_room_4", housesArchyProcessor), 1),
124
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/one_room_5", housesArchyProcessor), 1)
125
				),
126
				StructureTemplatePool.Projection.RIGID
127
			)
128
		);
129
		Pools.register(
130
			context,
131
			"trail_ruins/buildings/grouped",
132
			new StructureTemplatePool(
133
				empty,
134
				List.of(
135
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_full_1", housesArchyProcessor), 1),
136
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_full_2", housesArchyProcessor), 1),
137
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_full_3", housesArchyProcessor), 1),
138
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_full_4", housesArchyProcessor), 1),
139
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_full_5", housesArchyProcessor), 1),
140
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_lower_1", housesArchyProcessor), 1),
141
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_lower_2", housesArchyProcessor), 1),
142
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_lower_3", housesArchyProcessor), 1),
143
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_lower_4", housesArchyProcessor), 1),
144
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_lower_5", housesArchyProcessor), 1),
145
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_upper_1", housesArchyProcessor), 1),
146
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_upper_2", housesArchyProcessor), 1),
147
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_upper_3", housesArchyProcessor), 1),
148
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_upper_4", housesArchyProcessor), 1),
149
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_upper_5", housesArchyProcessor), 1),
150
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_room_1", housesArchyProcessor), 1),
151
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_room_2", housesArchyProcessor), 1),
152
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_room_3", housesArchyProcessor), 1),
153
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_room_4", housesArchyProcessor), 1),
154
					Pair.of(StructurePoolElement.single("trail_ruins/buildings/group_room_5", housesArchyProcessor), 1)
155
				),
156
				StructureTemplatePool.Projection.RIGID
157
			)
158
		);
159
		Pools.register(
160
			context,
161
			"trail_ruins/decor",
162
			new StructureTemplatePool(
163
				empty,
164
				List.of(
165
					Pair.of(StructurePoolElement.single("trail_ruins/decor/decor_1", housesArchyProcessor), 1),
166
					Pair.of(StructurePoolElement.single("trail_ruins/decor/decor_2", housesArchyProcessor), 1),
167
					Pair.of(StructurePoolElement.single("trail_ruins/decor/decor_3", housesArchyProcessor), 1),
168
					Pair.of(StructurePoolElement.single("trail_ruins/decor/decor_4", housesArchyProcessor), 1),
169
					Pair.of(StructurePoolElement.single("trail_ruins/decor/decor_5", housesArchyProcessor), 1),
170
					Pair.of(StructurePoolElement.single("trail_ruins/decor/decor_6", housesArchyProcessor), 1),
171
					Pair.of(StructurePoolElement.single("trail_ruins/decor/decor_7", housesArchyProcessor), 1)
172
				),
173
				StructureTemplatePool.Projection.RIGID
174
			)
175
		);
176
	}
177
}
178

Decompiled Minecraft 26.3 source of TrailRuinsStructurePools (net/minecraft/data/worldgen/TrailRuinsStructurePools.java) with Mojang official mappings, stored verbatim on the site.