hmm ok i been searching all day to try find the answer, first place to ask is here.......
int test(lua_State* L)
{
cout <<"test\n";
return 0;
}
ok calling this from my test app is fine....
matta of:
test()
but if i want
test("some text")
what now? =S
int test(lua_State* L, const char* str)
{
cout << str << "test\n";
return 0;
}
this returns
error C2664: 'lua_pushcclosure' : cannot convert parameter 2 from 'int (struct lua_State *,const char *)' to 'int (__cdecl *)(struct lua_State *)'
anyone? =S
while at it, anyone know the header to include for os.clock()
?? :s
nm got it
int printt(lua_State* L)
{
cout << lua_tostring(L, -1);
return 0;
}