Closed iThorgrim closed 6 months ago
I am thinking that this might be better to introduce as a config variable in the world config. The following PR introduces the use of the cpath, and it populates it dynamically with paths scanned from lua_scripts. We could expand this logic to take in a configured path string as well as the scanned paths. This would probably be more transparent for the end users.
This commit introduces a script that updates the package.path and package.cpath variables in Lua. These updates allow Lua to know where it should look when requiring modules. The script is designed to work with both LuaJit and standard Lua interpreters and adds several commonly used directories to the paths.