Page 1 of 1
Call external executable or shell command from Lua?
Posted: Sun Aug 12, 2018 3:08 am
by zangman
It seems that calls to io and os are
disabled by default. If I want to interface with an external program from factorio (both send and receive data), whats the best way to do it through a mod? Can I have my application running as a local webserver and send requests to it?
Re: Call external executable or shell command from Lua?
Posted: Sun Aug 12, 2018 7:31 am
by DaveMcW
RCON for input. It requires a headless server to work.
game.write_file() for output.
Re: Call external executable or shell command from Lua?
Posted: Sun Aug 12, 2018 10:58 pm
by zangman
Thanks. Rcon seems pretty complex, since I'm just sending data out, write_file works for now.