added some basic lua scripts that need to be part of the project
made some optimizations to sockets and accounts and freeing instances