Hand crafting for resource category

Things that already exist in the current mod API
Post Reply
User avatar
H8UL
Fast Inserter
Fast Inserter
Posts: 114
Joined: Mon May 15, 2017 4:02 pm
Contact:

Hand crafting for resource category

Post 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.
Shameless mod plugging: Ribbon Maze

Bilka
Factorio Staff
Factorio Staff
Posts: 3128
Joined: Sat Aug 13, 2016 9:20 am
Contact:

Re: Hand crafting for resource category

Post 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
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.

User avatar
H8UL
Fast Inserter
Fast Inserter
Posts: 114
Joined: Mon May 15, 2017 4:02 pm
Contact:

Re: Hand crafting for resource category

Post 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!
Shameless mod plugging: Ribbon Maze

Post Reply

Return to “Already exists”