I have Lua embeded in my C/C++ app. If I run script with
lua_pcall( luaState, 0, LUA_MULTRET, 0 );
for the first time, all is OK (return 0). But I need to run script again after some time. Calling same function again, script is not executed and retun value is 2. How can I run it again without reload everything again from file ?
Push it twice on the stack or store it as a global variable.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With