Wear and Tear

by withers

Adds wear and tear mechanics to the game, plus automated maintenance.

6 years ago
0.14 - 0.15
14

b Bug with angel's heavy pump

7 years ago
(updated 7 years ago)

Hi, factorio does not start when using your mod together with angels petrochem.

13.406 Error Util.cpp:57: Error while loading recipe prototype "Recycle Old_heavy-pump" (recipe): Recipe Recycle Old_heavy-pump must have at least one product.
Modifications: WearAndTear › angelspetrochem

Otherwise great mod, works without angel without problems

7 years ago

Should be fixed now.

7 years ago
(updated 7 years ago)

This one is fixed, but there is another issue with the way you generate the aging_xxx entities. I added myself another recipe for the Electric multi-purpose furnace so that i can craft it from the chemical and mixing electric furnace. The recipe got the name "electric-chemical-mixing-furnace-var" which does not belong to an exisiting entity, hence the mod tries to access a non exisiting element and the game crashes.

I added in data-final-fixes.lua to the first if statement the check if data.raw["assembling-machine"][entity.name] exists, i.e. the recipe name as entity. Works fine for me.

7 years ago

Okay hopefully it's fixed now. It was actually a typo. Your question confused me because I don't actually use the recipe.name for anything. I just scan all the recipes and create a local variable called "entity_name" which is assigned the name of a recipe's result.

The problem was I mistakenly used entity.name instead of entity_name in a few places.

Should be fixed now. I tested using a dummy recipe to try and simulate your issue. Working on my end. Please let know if a problem persists.

7 years ago

Now everything works, thanks for the patches

New response