Jump to content

LUA Questions: Linking to DCS (commands)


Slazi
 Share

Recommended Posts

Hello again friendly mission makers!

 

I've finally had a little time to get some scripting done to work on my mission. I'm starting to get the hang of lua. Classes working, functions returning, all that jazz.

 

So I can interact with my script from DCS, but I'm now stuck because my script cannot interact with DCS yet.

 

What I'm looking for is a list of DCS commands that can be accessed via lua.

 

A few examples:

 

I want references to specific groups.

I want to get the names of all the active clients.

I want to add and remove radio commands for players.

I want to be able to change flags. - Done! (e.g trigger.action.setUserFlag(10, 1) - sets flag 10 to 1)

I want to be able to tell dcs to load another script file from a location.

I want to add weight to a player aircraft.

 

I'm guessing there must be a place where I can find this information. But I couldn't find it in any of the stickies.

 

MIST is available, but it does far more than I need from my scripts. I want to keep mine lightweight and modular.

 

Thanks for reading!

 

-- edit - sorry - I am aware of this (parts 1 and 2)

http://en.wiki.eagle.ru/wiki/Simulator_Scripting_Engine/DCS:_World_1.2.1/Part_1#Class_emulation

 

I had seen this in the past, but forgotten about it. Am reviewing again now.


Edited by Slazi
Link to comment
Share on other sites

Official documentation on the ED wiki:

http://en.wiki.eagle.ru/wiki/Part_1

http://en.wiki.eagle.ru/wiki/Part_2

 

Adding weight to an aircraft and getting information about MP players are not possible from a mission script as far as I know. SlMod might expose some info about connected players to mission scripts.

Link to comment
Share on other sites

Thanks, Ian.

 

I'll have to look at SiMod when I get some free time then.

 

Witchcraft is working nicely for me btw :) Great mod.

 

I'm surprised there is nothing to add weight by standard, it seems like something a lot of people would want to do.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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