VanillaLootTableProvider .java

net.minecraft.data.loot.packs.VanillaLootTableProvider (class, 31 lines): members: create. imports: LootTableProvider, SingleRegistryBootstrap, LootTable.

net.minecraft.data.loot.packsclass31 linescommon1.8 KB

API Surface (1)

SingleRegistryBootstrap<LootTable> create()

Code Graph: Dependencies (5)

Edges (calls / imports / inherits / references) resolved by graphify from the AST. Every chip opens the class source.

Full Source

VanillaLootTableProvider.java31 lines · Minecraft 26.3 · verbatim
1
package net.minecraft.data.loot.packs;
2
3
import java.util.List;
4
import net.minecraft.core.registries.SingleRegistryBootstrap;
5
import net.minecraft.data.loot.LootTableProvider;
6
import net.minecraft.world.level.storage.loot.BuiltInLootTables;
7
import net.minecraft.world.level.storage.loot.LootTable;
8
import net.minecraft.world.level.storage.loot.parameters.LootContextParamSets;
9
10
public class VanillaLootTableProvider {
11
	public static SingleRegistryBootstrap<LootTable> create() {
12
		return new LootTableProvider(
13
			BuiltInLootTables.all(),
14
			List.of(
15
				new LootTableProvider.SubProviderEntry(VanillaFishingLoot::new, LootContextParamSets.FISHING),
16
				new LootTableProvider.SubProviderEntry(VanillaChestLoot::new, LootContextParamSets.CHEST),
17
				new LootTableProvider.SubProviderEntry(VanillaEntityLoot::new, LootContextParamSets.ENTITY),
18
				new LootTableProvider.SubProviderEntry(VanillaEquipmentLoot::new, LootContextParamSets.EQUIPMENT),
19
				new LootTableProvider.SubProviderEntry(VanillaBlockLoot::new, LootContextParamSets.BLOCK),
20
				new LootTableProvider.SubProviderEntry(VanillaPiglinBarterLoot::new, LootContextParamSets.PIGLIN_BARTER),
21
				new LootTableProvider.SubProviderEntry(VanillaGiftLoot::new, LootContextParamSets.GIFT),
22
				new LootTableProvider.SubProviderEntry(VanillaArchaeologyLoot::new, LootContextParamSets.ARCHAEOLOGY),
23
				new LootTableProvider.SubProviderEntry(VanillaShearingLoot::new, LootContextParamSets.SHEARING),
24
				new LootTableProvider.SubProviderEntry(VanillaEntityInteractLoot::new, LootContextParamSets.ENTITY_INTERACT),
25
				new LootTableProvider.SubProviderEntry(VanillaBlockInteractLoot::new, LootContextParamSets.BLOCK_INTERACT),
26
				new LootTableProvider.SubProviderEntry(VanillaChargedCreeperExplosionLoot::new, LootContextParamSets.ENTITY)
27
			)
28
		);
29
	}
30
}
31

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