Okay, I know I'm showing my naivety here, having never used physics before, but when I do a require "box2d" I get a "module box2d not found" error. But only if I try and run in the player on a real device. If I use the desktop player it works okay.
What am I missing here? (either mentally or physically)
best regards
Comments
I don't think the distribution of Gideros includes that file (does it?). Hence I had to take the one that came with Wax. Do I need a specific one for Gideros?
best regards
Calling wax_setup() inside g_initializePlugin() seems to wipe the global table and hence knowledge of all previously loaded plugins. I've moved the wax_setup() to loader() with a guard variable to stop it happening more than once. This seems to fix the problem although I'm not quite sure why it's that different. Still, I've pushed the fixed version up to BhWax in GitHub.
Truth is, I don't totally understand the plugin setup mechanism and when the various functions are called and what they do/expect on the stack. So, if you (@atilim) could just take a quick look over what I've done and comment, I'd be most grateful.
best regards
The problem seems to be with the luaL_openLibs() call in wax_setup(). Commenting that out seems to wipe the plugins. For the time being I'll use the (usingExternalLuaState) variable I added to say whether this should be called or not.