> lua.call(1, 1); > if (lua.isnumber(1)) ret = (int)lua.tonumber(1); You must remove this result from the stack: `tonumber' doesn't do that. So, you need a lua.pop(1); after that code. -- Roberto