I did have a quick look at LuaGlobal.lua and I must say that there is a lot of space for improvements. This is good thing, because we can easily make it much better (Yes, I am will to do some work if someone will kick in right direction – you know I am not a programmer.)
Mudlet is currently loading 2 files on session start up: db.lua and LuaGlobal.lua. If you look at LuaGlobal.lua you will see that is containing mix of various unsorted helper functions in pretty “random” order. Problems that I have with this are that is very hard to find there anything (same for lua documentation).
I would like to suggest following that will drastically improve situation (if we make it right).
- split LuaGlobal.lua into few separate files that will hold functions just for specific area (something like StringUtils.lua, TableUtils.lua, GUIUtils.lua, DebugUtils.lua, Others.lua)
- enforce Geyser style comments/documentation and generate all LUA documentation from it (see example bellow)