MIST Mapobjs dead zones

From DCS World Wiki - Hoggitworld.com


mist.flagFunc.mapobjs_dead_zones

Added with: Mist 1.0
Description
Sets a flag true when the a required number of world objects are dead within the specified zones.
Syntax
nothing mist.flagFunc.mapobjs_dead_zones(table vars )
Valid Input Values:

vars tables have the following recognized fields( required entries in blue, optional in green):

 vars = 
 {
 zones = table zones, 
 flag = number/string flag,
 stopFlag = number/string stopFlag, 
 req_num = number req_num,
 }

zones is a table of zone names (indexed numerically)

flag is the flag number that will be set true if the conditions are met

stopFlag is an optional variable that allows you to specify a flag number that, if set true, will stop the process.

req_num is an optional variable that allows you to specify the minimum number of units that must be in one (or more) of the zones before flag is set true. If req_num is not specified, it defaults to 1.

Return value:
nothing
Return example:
nothing
Usage Examples:

do

 mist.flagFunc.mapobjs_dead_zones{  
   zones = {'town1', 'town2', 'town3'},  
   flag = 1050, 
   req_num = 5 
 }  

end

Notes:
Once this function is run, it will start a continuously evaluated process that will set flag flag true

if map objects (such as bridges, buildings in town, etc.) die (or have died) in a mission editor zone (or set of zones). This will only happen once; once the flag flag is set true, the process ends

Mist 3.5 allows for strings to be used to define flags.

Related Functions
mapobjs_dead_polygon, Mapobjs_dead_zones, units_in_zones, units_in_moving_zones, units_in_polygon, units_LOS, group_alive, group_dead, group_alive_more_than, group_alive_less_than

Scripting Engine

MIST Root Page