eric963 Posted September 6, 2014 Posted September 6, 2014 I have been using some of the basic MIST functions and have not hsd to many problems with using usint them when it just needs like single id's like group name, unit nsme or a single trigger zone name. Now I am stuck on creating a table. I need to create a table that will contain lets say 30 trigger zones. Can someonr please give me an example of this. Thanks Eric
RagnarDa Posted September 6, 2014 Posted September 6, 2014 Tutorial about tables: http://lua-users.org/wiki/TablesTutorial Arrays: http://www.lua.org/pil/11.1.html DCS AJS37 HACKERMAN There will always be bugs. If everything is a priority nothing is.
eric963 Posted September 9, 2014 Author Posted September 9, 2014 Ok, I gave it all I could over the weekend but I'm still stuck. I have a mission where I clone a group into a random zone using this command mist.cloneInZone ('clonegroup', {'zone1', 'zone2', 'zone3'}) This is working fine, but say I have a large number of zones. It would not be practical to type in all the zone names. The MIST doc says this mist.cloneInZone (string groupName, string zoneName, Boolean disperse, number distance) zoneName also accepts a table of zone names which it will pick from at random to spawn the group. MIST has the table called mist.DBs.zonesByName This is where I am stumped. I a missing something important when I try to use that table in my mist.cloneInZone ('clonegroup', {'zone1', 'zone2', 'zone3'}) and replacing the {'zone1', 'zone2', 'zone3'} part with a table. Could someone please show me what I'm missing. Thanks Eric "Trying to learn some LAU" Cabral
RagnarDa Posted September 9, 2014 Posted September 9, 2014 I don't have the MiST-documentation in front of me, but I think there is a function to create a table given a string variable, something like mist.getZones("[all]") DCS AJS37 HACKERMAN There will always be bugs. If everything is a priority nothing is.
Recommended Posts