Lua: Various improvements

Some stuff requested by R00Kie.
This comment doesn't seem correct