tweaks to libs, added Invoke for lua functions