Cataclysm-DDA icon indicating copy to clipboard operation
Cataclysm-DDA copied to clipboard

Enchanted Tailoring Kit can repair nylon

Open OtpalTS opened this issue 3 years ago • 4 comments

Summary

Bugfixes "Enchanted Tailoring kit can repair nylon"

Purpose of change

The normal tailoring kit has the ability to repair nylon (synthetic fabric), so I believe this to be just an oversight similar to it not being able to repair lycra some time ago( #47955 )

Describe the solution

Adding nylon to the things it can repair

Describe alternatives you've considered

Putting it off another day.

Testing

Loaded game and repaired + reinforced LBV using the enchanted tailoring kit

Additional context

Had to close the previous one and fix my repository since it was showing previous commits. This one is hopefully fixed

OtpalTS avatar Aug 08 '22 10:08 OtpalTS

This looks like one of the inheritance issues. Where perhaps more is written into the mod definitions of the tool than is needed. mtailors_kit has the property "copy-from": "tailors_kit". Magiclysm has a tailors_kit override that adds "black_dragon_hide" and "demon_chitin" to the materials list, nylon is added there.

Is it possible to instead use "copy-from" and "extend" to inherit the materials list from vanilla and just add the hide and chitin to the list? This will make sure that it is in line with vanilla on further updates there.

Possible issue is that the move cost for the use action is different between the mtailors_kit and the tailors_kit. I do not know if this is intended or an artifact of a change not being carried over to the mod.

I will have a look at this tonight myself if no one else steps in.

Knut-Aage-Hofseth avatar Aug 08 '22 11:08 Knut-Aage-Hofseth

The issue is that it's pulling the materials from the vanilla tailor kit not the overwritten magiclysm tailors kit, otherwise one could just delete the materials on the mtailors_kit. If someone knows how to change that it would be great, but I'm very limited in what i know how to do.

OtpalTS avatar Aug 08 '22 12:08 OtpalTS

Can someone explain why that test is failing and how I can fix it?

OtpalTS avatar Aug 09 '22 09:08 OtpalTS

Not your fault, nothing to do, don't worry. https://github.com/CleverRaven/Cataclysm-DDA/runs/7723494883?check_suite_focus=true#step:16:349

anothersimulacrum avatar Aug 09 '22 16:08 anothersimulacrum

Is it possible to instead use "copy-from" and "extend" to inherit the materials list from vanilla and just add the hide and chitin to the list?

AFAIK "copy-from" and "extend" aren't able to get to and modify an array within a nested JSON object, that is within another array of another JSON object. Let me know if I'm wrong, my life would become a whole lot easier.

catdach avatar Aug 11 '22 17:08 catdach