Page 1 of 1

Hand crafting for resource category

Posted: Sat Nov 17, 2018 2:04 am
by H8UL
In an upcoming mod I've got trees as resources. This seems the "proper" way to make them automatable. I don't need custom mining logic in control.lua, which is very helpful for UPS given this is aimed at big bases. And the yield is reported on the map.

Both for balance and appearance, they don't use the standard basic solid resource and miners. There are dedicated harvesters with tuned mining speed, energy consumption and module slots. Burner drills would look especially odd, too, drilling for wood. So I enforce this with a separate resource category.

This mostly works great!

The downside is that players cannot hand mind these trees, being in a custom resource category. To work around this, I've added in normal tree type entities, so players can at least mine some wood. But it's not entirely satisfactory because players will expect everything that looks like a tree to be hand minable.

My proposal:

Allow either resource categories or resource entities to override the default behaviour, and enable hand crafting, as long as the results are items.

Re: Hand crafting for resource category

Posted: Sat Nov 17, 2018 7:44 am
by Bilka
Do I understand correctly that your goal is to allow the player to handmine a custom resource category? If yes, simply add it to the player prototype mining categories: https://wiki.factorio.com/Prototype/Cha ... categories

Re: Hand crafting for resource category

Posted: Sat Nov 17, 2018 9:40 am
by H8UL
Facepalm. Yes that's exactly it. I never thought to look at the player prototype. I should study it to see what else it can do. :oops:

Thanks!