Dungeons Gear

Dungeons Gear

6M Downloads

Dungeon Gears does not use the loot table from the context when generating loot

TelepathicGrunt opened this issue · 5 comments

commented

Hello! I gotten a report on my mod Repurposed Structures about my mod no longer importing Dungeon Gear's modded loot from vanilla loot tables.
TelepathicGrunt/RepurposedStructures#121

After looking closely and debugging, I found the reason why rolling vanilla's loot tables in my GLM does not spawn Dungeons Gear's loot is because Dungeon Gear is checking the loot table of the block directly.
image

You actually do not need to do that at all. The loot table to spawn is already in the LootContext context parameter and can be grabbed by doing context.getQueriedLootTableId(). If you switch to using that, it'll help simplify your code a bit and make my mod's modded loot importing work again with Dungeon Gears. It may also help with compat for other mods that tries to roll loot table loot outside of chests to try and analyze the loot outputs or something unique or wacky.

commented

This is because the loot table id in context wasn’t a thing in the version of forge this mod was compiled against. Will need to update my Forge version to latest to get this fixed.

commented

Ah. That makes sense! Yeah the new context stuff is super useful

commented

Fix has been implemented and should come in a future version.

commented

Fix available in 3.0.21