Page 1 of 1

Crafting Machines

Posted: Sun Nov 13, 2016 8:21 pm
by DutchJer
Hi,

I've been looking for a way to find all the machines that can craft items together with their properties. I have been searching through the api, but I couldnt find a way to read that. So I would like this, with this it would make it a lot easier to create a ratio website for each mod, just by doing 2 commands and uploading 2 files. (recipes & machines). So what I hope that can be done is adding this to the api. I would like to know the recipe-types it can craft, craft speed, moduleslots, amount of components it can craft.

that would make me a lot happier, and probably a lot of other players too :D

Re: Crafting Machines

Posted: Sun Nov 13, 2016 8:29 pm
by aubergine18
Why don't you just scan through data.raw via a data-final-fixes.lua? This way you have full access to all prototypes (although some mods might still change them if their data-final-fixes.lua runs after yours) and can still use the `log()` and `serpent()` global functions to output the data you need to the log file.

Re: Crafting Machines

Posted: Sun Nov 13, 2016 8:53 pm
by DutchJer
can you access the data.raw through the console?

Re: Crafting Machines

Posted: Sun Nov 13, 2016 11:22 pm
by aubergine18
Why do you need to access via console? Just make a small mod that has a data-final-fixes and do what you want in there - eg. scanning the data.raw for info you need, then using log() and serpent() to output that infos to the log file from where you can copy/paste it or parse with external scripts.