new building

Place to get help with not working mods / modding interface.
Post Reply
Egorka
Manual Inserter
Manual Inserter
Posts: 4
Joined: Sun Feb 24, 2013 1:30 pm
Contact:

new building

Post by Egorka »

please tell me what to do to the material prepared from nothing only spending energy?

sorry for my english!

kovarex
Factorio Staff
Factorio Staff
Posts: 8078
Joined: Wed Feb 06, 2013 12:00 am
Contact:

Re: new building

Post by kovarex »

Hello,
it is an interesting idea.
This is not possible in this version as if you specify empty ingredients in recipe it crashes.
But we might fix it for 0.5.0.

User avatar
FreeER
Smart Inserter
Smart Inserter
Posts: 1266
Joined: Mon Feb 18, 2013 4:26 am
Contact:

Re: new building

Post by FreeER »

kovarex wrote:Hello,
it is an interesting idea.
This is not possible in this version as if you specify empty ingredients in recipe it crashes.
Actually I noticed that drs9999 did this quite a while ago :)
simply use

Code: Select all

ingredients = {},
in an assembling machine recipe. True Factorio crashes if you leave it as a player-craftable recipe (probably do to factorio trying to detect the raw resources or just an inability to display nil as the ingredients) but you asked about a building anyways so :D

If you are not sure how to make it an assembling machine recipe it's something like this

Code: Select all

    {
      type = "recipe-category",
      name = "your-crafting-category" --whatever name you want to give your crafting category
    },
    {
        type = "recipe",
        name = "material", --recipe name, typically the same name of material the building will be producing
        category = "your-crafting-category", --the name you gave the crafting category above
        energy_required = 10,
        ingredients = {},
        result = "material", --name of the material produced
        result_count = 10 --number of 'material' that will be produced in one 'turn'
    },
Then just create an assembling machine entity and add your-crafting-category to the crafting_categories list (I didn't want to spam the post with the code for an assembling machine), don't forget to add a recipe for the assembling machine though.
<I'm really not active any more so these may not be up to date>
~FreeER=Factorio Modding
- Factorio Wiki
- My Factorio Modding Guide
- Wiki Modding Guide
Feel free to pm me :)
Or drop into #factorio on irc.esper.net

Post Reply

Return to “Modding help”