Reputation: 789
Can someone give me any suggestions as to how to use this function from Lua:
HH_DISPLAY_TOPIC (MSDN)
I'm just a bit confused as to how to call the function as in is it from a dll or do I need to make a dll or is this a Luacom type of scenario.
Upvotes: 2
Views: 143
Reputation: 474256
Lua cannot go out into random DLLs and start calling random C functions1. If you want to call some code in a DLL, then you need to write a proper Lua module in C that will load this DLL and marshall the call from Lua to the DLL. Lua can read regular Lua modules and act accordingly.
1: If you're using LuaJIT, you can do this via their FFI stuff. To a degree, as you'll need to provide a string describing the interface for the functions you want to call.
Upvotes: 4