Jump to content

C++ Lua Native Extension starter template


Recommended Posts

So before I go and have to set this up myself (and no doubt again duplicating the work that many others have done already) I am wondering. Has anyone got a  minimal starter template  C++ native extension project for DCS ready to go? A DLL that can be loaded into, and called from, the lua mission scripting environment.

 

Basically something that does all this (from 2012):

including dependencies etc. etc. (the link above has a little example but it is incomplete and old)/

 

Ideally somthing that can be dropped into a folder, rename a few things, load it in Visual Studio and compile successfully so that I can start implemeting interfaces and application logic.


Edited by rurounijones
  • Like 1
Link to comment
Share on other sites

  • 10 months later...

Hi. I got it to work.

You can follow these steps:

One thing that was a little difficult was the lua library and dll. If you use the lua5.1.lib you will need the lua5.1.dll which is not included in DCS.

I used the same lua.lib that SRS uses (https://github.com/ciribob/DCS-SimpleRadioStandalone/blob/master/SRS-Lua-Wrapper/lua.lib) and it worked with DCS default lua.dll.

If you have any trouble, feel free to ask here.

Here is a non-functional project that compiles and loads. You can add your own code there. I'm trying to do a dll for having the radio working on SFM mods.

avSimplestRadio.rar

  • Thanks 2
Link to comment
Share on other sites

5 hours ago, Luiz Renault said:

Yesterday i was able to get the radio working on SFM usign this project. Will share it as soon as i can clean up the code.

I intend to reasearch other topics using same approach, like guided weapons, datalink, ILS, TACAN, etc.

 

That's great, if can be reached 🙂 will open new door to the community MOD

MOD Logo - 100.png

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...