Code: Select all
io.output("thing.txt")
io.write("some text")
If I put the same code into a gadget, I get this in the infolog:
Code: Select all
[f=0000000] Loading LuaRules
[f=0000000] Failed to load: build_block.lua ([string "LuaRules/Gadgets/build_block.lua"]:32: attempt to index global 'io' (a nil value))