Lua function issues

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • RE: Lua function issues

      These actually look like luabind errors. My guess is that you modified the LuaStateManager class to use luabind types instead of the LuaPlus ones. Did you remember to link in the correct luabind libs?

      -Rez
    • RE: Lua function issues

      Not sure what to say. This definitely looks like an issue linking to luabind but I've never used it so I can't say for sure. I also don't know how you modified the various GCC Lua classes. If you can't figure it out, you might want to post on the luabind forums.

      One thing that tends to help with 3rd party linker issues to try to set up a blank project so you can play around with it before trying to integrate into a bigger project. That's typically how I do 3rd party lib integrations.

      -Rez
    • LUAplus reinforcement

      Hi!

      Here goes some suggestions from my experience/headaches with Luaplus. As I restarted my project at the same time that the GCC 3rd edition, my dev environment is windows vista 32 bits, visual studio EXPRESS 2008 and so on, my plan is to reach some results before moving to 64 bits and vs2010 as i wasnt still comfortable with the new devs environemnts and i fear what might happen while trying to rebuild all the libs ...
      From the luaplus documentation, if i recall correctly, the author worked in luaplus because of the "hevyweight-build" that luabind implied due to lots of dependencies with boost, while luaplus restricted some of the luabind functionalities and omitted all dependencies to boost...

      1) First, i cant recall now if im using the latest LuaPlus SVN you can currently find on the web or the build that was in an "old" luaplus site some years ago. I tried to follow the guidelines to build the libs using JAM and always finished with strange build output, but adding the LuaPlus vcproj (found at ..\LuaPlus1100lua51\LuaPlus\Src\LuaPlus) to a vs 2008 workspace and building should work... As i said i dont know waht might happen in vs2010

      2) I modified the LUAFUNCTION_POSTCALL macro found in luafunction.h this way

      Source Code

      1. #define LUAFUNCTION_POSTCALL(numArgs) \
      2. if (lua_pcall(L, numArgs, 1, 0)) \
      3. { \
      4. const char* errorString = lua_tostring(L, -1); OutputDebugStringA(errorString); (void)errorString; \
      5. luaplus_assert(0); \
      6. } \
      7. return LPCD::Get(LPCD::TypeWrapper<RT>(), L, -1);

      which allowed me to output the lua error message result from a failed function execution to the VS debug console during the execution...

      2) I managed to integrate the network luaplus debugger to the GCC and i am able to debug all lua scripting. I made the necessary modifications to the luastate manager to become a lua debug server, i made the modifications based on the sources from the LuaRemoteDebuggingServer folder. I failed on building the RemoteLuaDebugger exe network client even using vs2005 due to MFC issues. But on the luaplus google code SVN it was available a build exe which worked :). As fas as i know i AM ABLE TO DEBUG .lua scripts files, not strings!

      Hope the info is useful and good luck!

      @B^)>