Page 1 of 1

Add LuaEntityPrototype.crafting_speed read

Posted: Mon Mar 27, 2017 3:13 pm
by theRustyKnife
This feels like a thing that just should be available. Actually, I was thinking why not just expose the entire prototype definition table as in data.raw when loading? Would it take too much memory or something?
Also a nice thing to have would be some way to get the current crafting speed of an assembler (after accounting for modules and stuff like that).

Thanks TRK

Re: Add LuaEntityPrototype.crafting_speed read

Posted: Sun Apr 02, 2017 3:12 pm
by Rseding91
Added entity prototype crafting_speed read for 0.15.

The reason the entire prototype table isn't exposed is because we dump it after loading and during/after loading we do additional processing making the input data wrong or lacking in most cases.

Re: Add LuaEntityPrototype.crafting_speed read

Posted: Sun Apr 02, 2017 3:24 pm
by theRustyKnife
Ok, that makes sense.
What about the other suggestion? I know it would be possible to calculate that with crafting_speed being exposed, but since the game probably already does that (likely much faster than any mod would), it would be nice to have that too.
Anyway, thanks for listening to the modders' needs, I just hope I'm not too annoying with all the requests I've made recently :P