Page 1 of 1

Add export_record() or similar method to LuaRecord

Posted: Thu Jun 19, 2025 6:44 am
by PhaSelEza
Hello Factorio team,

I am developing a mod with the goal of exporting a player's blueprint library to
files, which would allow for easy backups and version control using tools like
Git.

I've found that this is not currently possible due to a limitation in the Lua
API. While a LuaItemStack for a blueprint item can be easily exported to a
string using export_stack(), there is no equivalent function for the LuaRecord
objects that represent blueprints in the library (accessed via
player.blueprints).

Could you please consider adding a function to LuaRecord, similar to
LuaItemStack::export_stack()? A method like LuaRecord::export_record() that
returns the blueprint string would be a perfect solution.

Thank you for your amazing work on the game and for considering this feature
request.