lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

> Denis Andreev wrote:
> I think you must look at luna. Search for it on

after looking Luna, somethinf is still bothering me ... :)
function that are exported to Lua like "Account" or "deposit" are made of
lua expressions (lua_tonumber...), lua can evaluate these registerd
Is there a way to export "real" C++ (or C) function to lua ? How lua can
interpret it ?

For example : in lua's doc, there is a function "foo", which is registerd as
"average". Is it possible to register a C function  "int average(int a, int
b) { return (a+b)/2;}" to lua ?

I think it's possible because, it is done in the Flat Four Engine
(  ...

hope someone could help me ...