hello,
I am working on a custom machine for my mod and wondering how would I make a custom module. Simple it just sieves stone to ores. Hopefully, you get the idea I am not the best at getting the words from my head down into writing. Also sorry about my spelling.
example
default recipe 4 stone = 1 copper ore, 1 iron ore
copper sieve recipe 4 stone = 2 copper ore , 1 iron ore
custom module
-
- Manual Inserter
- Posts: 2
- Joined: Sun Jul 17, 2022 2:23 pm
- Contact:
Re: custom module
Code: Select all
local category = table.deepcopy(data.raw["recipe-category"]["basic-crafting"])
category.name = "sieve-crafting"
data:extend{category}
local machine = table.deepcopy(data.raw["assembling-machine"]["assembling-machine-2"])
machine.name = "sieve-machine"
machine.crafting_categories = {"sieve-crafting"}
data:extend{machine}
local recipe = table.deepcopy(data.raw["recipe"]["uranium-processing"])
recipe.name = "basic-sieve"
recipe.category = "sieve-crafting"
recipe.enabled = true
recipe.ingredients = { {"stone", 4} }
recipe.results = { {"copper-ore", 1}, {"iron-ore", 1} }
data:extend{recipe}
-
- Manual Inserter
- Posts: 2
- Joined: Sun Jul 17, 2022 2:23 pm
- Contact:
Re: custom module
Hello,
I already have the machine working and everything but thank you for the example. By custom module am trying to make something like the speed upgrade just it would be called a sieve. basic copper sieve 4 stone = 2 copper ore and 1 iron ore. Hopefully, this clears my help thread up.
Thanks for taking time to reply
I already have the machine working and everything but thank you for the example. By custom module am trying to make something like the speed upgrade just it would be called a sieve. basic copper sieve 4 stone = 2 copper ore and 1 iron ore. Hopefully, this clears my help thread up.
Thanks for taking time to reply
-
- Fast Inserter
- Posts: 153
- Joined: Sun Jul 26, 2020 4:05 pm
- Contact:
Re: custom module
Normally you'd put it in as part of the recipe - what do you plan on it doing?