A higher level wrapper that allows most D functions to be naturally interact with LUA.
This is your go-to wrapper as it's capable of exposing most functions to LUA.
Notes:
Any throwables will instead be converted into a lua_error.
The return value (if any) of Func will automatically be converted into a LUA value.
The parameters of Func will automatically be converted from the values passed by LUA.
Func may optionally ask for the lua state by specifying LuaState* as its first parameter.
Func may be made variadic by specifying LuaVariadic as its last parameter.
If Func is annotated with @LuaBasicFunction, then this function actually acts the same as
luaCWrapperBasic. The reason for this is so that we don't have to have a bunch of conditional
logic in the other parts of the code to select between the two wrappers, but instead we can just put the conditional logic
here to seamlessly support this usecase throughout the code.
A higher level wrapper that allows most D functions to be naturally interact with LUA.
This is your go-to wrapper as it's capable of exposing most functions to LUA.
Notes: Any throwables will instead be converted into a lua_error.
The return value (if any) of Func will automatically be converted into a LUA value.
The parameters of Func will automatically be converted from the values passed by LUA.
Func may optionally ask for the lua state by specifying LuaState* as its first parameter.
Func may be made variadic by specifying LuaVariadic as its last parameter.
If Func is annotated with @LuaBasicFunction, then this function actually acts the same as luaCWrapperBasic. The reason for this is so that we don't have to have a bunch of conditional logic in the other parts of the code to select between the two wrappers, but instead we can just put the conditional logic here to seamlessly support this usecase throughout the code.