SPIGOT-6130: Fix API loot table generation with certain contexts

This commit is contained in:
md_5 2020-10-03 10:27:00 +10:00
parent 5c77bd2816
commit aa8206a857
No known key found for this signature in database
GPG Key ID: E8E901AC7C617C11

View File

@ -75,6 +75,7 @@ public class CraftLootTable implements org.bukkit.loot.LootTable {
WorldServer handle = ((CraftWorld) loc.getWorld()).getHandle(); WorldServer handle = ((CraftWorld) loc.getWorld()).getHandle();
LootTableInfo.Builder builder = new LootTableInfo.Builder(handle); LootTableInfo.Builder builder = new LootTableInfo.Builder(handle);
builder.set(LootContextParameters.ORIGIN, new Vec3D(loc.getX(), loc.getY(), loc.getZ()));
if (getHandle() != LootTable.EMPTY) { if (getHandle() != LootTable.EMPTY) {
// builder.luck(context.getLuck()); // builder.luck(context.getLuck());