DoubleDoorDevelopment / Lumberjack

Boom. Tree gone!
BSD 3-Clause "New" or "Revised" License
5 stars 7 forks source link

[1.11.2] Steel Lumberaxe not craftable #17

Closed drakray closed 7 years ago

drakray commented 7 years ago

Self explanatory, I have 2 mod that add ingotSteel (GrimPack&FunOres), but Steel Lumberaxe is not craftable.

Claycorp commented 7 years ago

I assume the axes show up but they have no recipe. If the mods exist in 1.10 do they show up? I assume it's happening because they don't set the repair item for their material thus the mod doesn't know what the recipe for the axe should be. (It happens quite often.)

You can either add your own recipe via Minetweaker, add the repair material via D3Core or ask the mod devs to add a repair item to their material. Then it will have a recipe.

I will keep this open till we can figure out exactly what's going on and hopefully get it fixed on whoevers end it needs to be fixed on.

drakray commented 7 years ago

I think I found the culprit by looking at latest.log: New LumberAxe SOULFORGED_STEEL (steel) From axe betterwithmods:steel_axe I added "SOULFORGED_STEEL": "betterwithmods:material 14 1" to my material.json I still added a recipe to use ingotSteel, as betterwithmods:material 14 is ingotSoulforgeSteel Don't know why D3 think it's regular steel though

Claycorp commented 7 years ago

Hmm. I will need to look into it a bit more. I'll test with GrimPack, Fun Ores and BWM and see what gets made.

drakray commented 7 years ago

using B:useAllMaterials=true I found out that a lumberaxe named lumberaxeMulti got created that use Steel as ingot, will talk with Grim about that

drakray commented 7 years ago

are you looking for a special format for the repairMaterials?

drakray commented 7 years ago

I don't understand what is happening, I restarted my game, Silver and Lead lumberaxe where no longer available, and now the lumberaxeMulti is using Obsidian to craft :/

edit: looking at logs, I think it have something to do with Grimpack's Multitools

dries007 commented 7 years ago

The issues is that Grimpack's Multitools use a suffix instead of a prefix (like every other mod we've come across while making this) so the Lumberjack code takes the wrong part of the ID. Since Lumberjack tries its best not to create multiple axes with the same material, it filters out all common prefixes and other crap, then selects the last part of the name if there are multiple (since all mods we saw used prefixes). Because Grimpack's Multitools goes against that, and 'tool' is one of the filterwords, the eventual name becomes "multi".

Relevant code here.

Example: black_diamond_multitool -> black diamond multi -> multi

As far as I can tell this issue would be most easily resolved by Grimpack's Multitools not using an extra tool material for the multitool, since its not required for what it's being used for. Its only use is the max durability multiplier, which can be replaced with a call to setMaxDamage in the constructor of the ItemMultiTool class.

Claycorp commented 7 years ago

Grim has fixed it on his side. Closing this as it should be gone. If steel axes still are acting odd feel free to comment and we can look into it further.

drakray commented 7 years ago

only thing left is I think Grim is not setting Steel as a tool material, because I still don't get a recipe without materials.json

EDIT: something weird, in my crash it say steel is already registered, but the recipe won't show up :/

Claycorp commented 7 years ago

TBH I wouldn't worry about it. As long as you can set the repair material without crashing, everything is working as it should and you get the recipe without waiting on an update.

drakray commented 7 years ago

I think I found culprit: SOULFORGED_STEEL [16:42:24] [Client thread/INFO] [lumberjack/lumberjack]: LumberAxe steel without recipe! Ask the mod author of SOULFORGED_STEEL for a ToolMaterial repairStack OR use D3Core's materials.json file to set it yourself.

drakray commented 7 years ago

seems like a conflict between normal steel and BWM soulforged steel

Claycorp commented 7 years ago

The mod is culling the Soulforged_ from the front and making it "steel" it's possible to fix but then you would get a "Soulforged steel axe" and a "Steel axe". Do you really want both?

drakray commented 7 years ago

I don't really, I just want normal Steel, as added by FunOres and Grimpack (this is what happen when there is no clear convention lol)

edit: but that is just my own preference, maybe some other case could arise where both are different enough to want both

Claycorp commented 7 years ago

Then I recommend oredic all the materials you want for the axe and then set the material repair stack to any of the ones oredic'ed together. It will have the soulforged steel stats but it's mostly all the same anyway.

The joys of pack making is the hackery just to get things working ;)

drakray commented 7 years ago

Excluding SOULFORGED_* in lumberjack.cfg did the trick, removed entry from log and allowed regular Steel recipe to register correctly

Claycorp commented 7 years ago

I totally forgot that existed..... LOL!

drakray commented 7 years ago

for this particular case it worked nicely, so it's a good thing I think I can say we manage to crush this pesky intermod crash/bug :D