SilentChaos512 / Silent-Gear

Modular tool/armor mod (formerly part of Silent's Gems)
https://www.curseforge.com/minecraft/mc-mods/silent-gear
MIT License
74 stars 34 forks source link

Loot not generating #625

Closed CerulanLumina closed 7 months ago

CerulanLumina commented 9 months ago

Versions

Expected Behavior

Opening a chest with one of several nether-based loot tables may yield some Silent Gear items

Actual Behavior

No Silent Gear loot is generated

Links/Images

N/a

Steps to Reproduce the Problem

  1. Run command /setblock ~ ~ ~ chest{LootTable:"minecraft:chests/bastion_other"}
  2. Open chest
  3. Observe there is no Silent Gear loot
  4. Repeat

In earlier versions, there seemed to be an event hook that injected loot into certain loot table. The event hook was removed, but there doesn't seem to be a replacement. LootTableInjectorLootModifier seems like it was intended to replace it, but it is not registered, nor referenced in forge:loot_modifiers/global_loot_modifiers. I tested out a local fix that consisted of registering the modifier in SgLoot, creating the JSON file, and appending the modifier ID to global_loot_modifiers, that seems to work fine. The modifier is applied to all loot tables, but it ends up retrieving an empty loot table for tables without injections, and so adds no items. This could probably be optimized, but eh. I can submit a PR if desired.

uhloin commented 9 months ago

Hit same issue, cannot get netherwood saplings as result (MC 1.20.1)

Medivha commented 8 months ago

i can assume that this also affects spider/cave spider with Fine_silk drops?! Because i don't get any after killing hundreds of them(me as a player and not with a machine)

SilentChaos512 commented 8 months ago

I can't remember if that issue is the same thing or not, but it is something that needs to get fixed.