Pyrotech

Pyrotech

897k Downloads

Hammer tiers can't be changed

jamesjimmy88 opened this issue ยท 2 comments

commented

Issue Description

It's not possible to change hammer tiers for custom recipes in the granite/ironclad anvil

What Happens

After creating a custom recipe for the anvil that uses the hammer as tool and changing the config in module.Tool.cfg to make it so obsidian tools have the same harvest level as diamond (3), the recipes still require the same number of hits as before; this is also shown in the JEI recipe window.
I also tried changing the hammer's harvest level with CraftTweaker, but that doesn't change anything.
The same issue applies to all hammers; I tried setting the harvest level for all tools to 3 but the recipe still shows the usual amount of hits.
Also there's no way to change the harvest level of the hammers made with vanilla materials.

What You Expect to Happen

That the number of hammer hit required for the recipes respects the harvest level of the tools (it probably does already and it's simply a matter of the config ignoring hammers)

Script

//script used to change harvest level, but that doesn't change in the anvil recipe
<pyrotech:obsidian_hammer>.definition.setHarvestLevel("hammer", 3);
//cobble to gravel
mods.pyrotech.GraniteAnvil.addRecipe("custom_anvil_gravel", <minecraft:gravel>, <minecraft:cobblestone>, 6, "hammer");

Affected Versions

  • Minecraft: 1.12.2
  • Forge: 14.23.5.2838
  • CraftTweaker: 4.1.20
  • Dropt: 1.16.1
  • Pyrotech: 1.4.21
  • Athenaeum: 1.17.4
commented

Thanks for the report. I had to look it up because I couldn't remember how it worked.

Hammer harvest level doesn't go off of the tool harvest level directly, instead it uses a list in the core config. To change the obsidian hammer harvest level as it relates to worktables, anvils, and blooms, change it in the hammers -> HAMMER_LIST in core.cfg:

        # Hammers are used on the worktables, anvils, and blooms.
        # Use this to add items that you want to be valid for hammer recipes.
        # The harvest level is used for hammer hit reduction with anvil recipes
        # and for the bloom hammer power modifier.
        # 
        # Items you add are assumed to have durability.
        # 
        # String format is a resource location: (domain):(path);(harvest_level)
        S:HAMMER_LIST <
            pyrotech:crude_hammer;0
            pyrotech:stone_hammer;1
            pyrotech:bone_hammer;1
            pyrotech:flint_hammer;1
            pyrotech:iron_hammer;2
            pyrotech:gold_hammer;1
            pyrotech:obsidian_hammer;2
            pyrotech:diamond_hammer;3
         >
commented

I missed that badly, huh? Anyway, this fixes all the issues I was having, thank you.