Rewrite Lua contexts
Comments & formatting