TitaniumTrout
Posts: 374
Joined: 10/20/2014 From: Michigan Status: offline
|
You need to dig into the table of sensor data. As below you can print the contents of u.sensors which gives you a ton of data. print(u.sensors) { [1] = { sensor_isactive = 'No', sensor_name = 'KH 1007 [Type 1007]', sensor_maxrange = 96, sensor_status = 'Operational', sensor_role = 2028, sensor_guid = 'T5Z37W-0HMCI67HH16DU', sensor_dbid = 2179, sensor_type = 2001 }, [2] = { sensor_isactive = 'No', sensor_name = 'LW.08', sensor_maxrange = 180, sensor_status = 'Operational', sensor_role = 2001, sensor_guid = 'T5Z37W-0HMCI67HH16DV', sensor_dbid = 1191, sensor_type = 2001 }, [3] = { sensor_isactive = 'No', sensor_name = 'SMART-S', sensor_maxrange = 80, sensor_status = 'Operational', sensor_role = 2014, sensor_guid = 'T5Z37W-0HMCI67HH16E0', sensor_dbid = 655, sensor_type = 2001 }, [4] = { sensor_isactive = 'No', sensor_name = 'Scout Mk.2', sensor_maxrange = 24, sensor_status = 'Operational', sensor_role = 2028, sensor_guid = 'T5Z37W-0HMCI67HH16E1', sensor_dbid = 2637, sensor_type = 2001 }, [5] = { sensor_isactive = 'No', sensor_name = 'Sea Watcher 100 [Seastar]', sensor_maxrange = 40, sensor_status = 'Operational', sensor_role = 2028, sensor_guid = 'T5Z37W-0HMCI67HH16E2', sensor_dbid = 5140, sensor_type = 2001 }, [6] = { sensor_isactive = 'No', sensor_name = 'IRSCAN', sensor_maxrange = 0, sensor_status = 'Operational', sensor_role = 2879, sensor_guid = 'T5Z37W-0HMCI67HH16E3', sensor_dbid = 331, sensor_type = 2004 }, [7] = { sensor_isactive = 'No', sensor_name = 'AR-700A(V)1', sensor_maxrange = 500, sensor_status = 'Operational', sensor_role = 3011, sensor_guid = 'T5Z37W-0HMCI67HH16E4', sensor_dbid = 1792, sensor_type = 3001 }, [8] = { sensor_isactive = 'No', sensor_name = 'Telegon 4', sensor_maxrange = 500, sensor_status = 'Operational', sensor_role = 3101, sensor_guid = 'T5Z37W-0HMCI67HH16E5', sensor_dbid = 165, sensor_type = 3001 }, [9] = { sensor_isactive = 'No', sensor_name = 'AR-700A(V)1 APECS II', sensor_maxrange = 0, sensor_status = 'Operational', sensor_role = 4021, sensor_guid = 'T5Z37W-0HMCI67HH16E6', sensor_dbid = 676, sensor_type = 3002 }, [10] = { sensor_isactive = 'No', sensor_name = 'AR-700A(V)1 APECS II', sensor_maxrange = 0, sensor_status = 'Operational', sensor_role = 4021, sensor_guid = 'T5Z37W-0HMCI67HH16E7', sensor_dbid = 676, sensor_type = 3002 }, [11] = { sensor_isactive = 'No', sensor_name = 'PHS-36', sensor_maxrange = 4, sensor_status = 'Operational', sensor_role = 5032, sensor_guid = 'T5Z37W-0HMCI67HH16E8', sensor_dbid = 1271, sensor_type = 5002 }, [12] = { sensor_isactive = 'No', sensor_name = 'DSBV 62C', sensor_maxrange = 40, sensor_status = 'Operational', sensor_role = 5101, sensor_guid = 'T5Z37W-0HMCI67HH16E9', sensor_dbid = 1900, sensor_type = 5011 }, [13] = { sensor_isactive = 'No', sensor_name = 'Gatekeeper [CCD]', sensor_maxrange = 25, sensor_status = 'Operational', sensor_role = 2701, sensor_guid = 'T5Z37W-0HMCI67HH16EB', sensor_dbid = 5144, sensor_type = 2003 }, [14] = { sensor_isactive = 'No', sensor_name = 'Gatekeeper [FLIR]', sensor_maxrange = 25, sensor_status = 'Operational', sensor_role = 2801, sensor_guid = 'T5Z37W-0HMCI67HH16EC', sensor_dbid = 5143, sensor_type = 2004 }, [15] = { sensor_isactive = 'No', sensor_name = 'STIR 180 [Radar]', sensor_maxrange = 32, sensor_status = 'Operational', sensor_role = 2143, sensor_guid = 'T5Z37W-0HMCI67HH16EE', sensor_dbid = 3146, sensor_type = 2001 }, [16] = { sensor_isactive = 'No', sensor_name = 'STIR 180 [IR Camera]', sensor_maxrange = 100, sensor_status = 'Operational', sensor_role = 2871, sensor_guid = 'T5Z37W-0HMCI67HH16EF', sensor_dbid = 3695, sensor_type = 2004 }, [17] = { sensor_isactive = 'No', sensor_name = 'STIR 180 [TV Camera]', sensor_maxrange = 100, sensor_status = 'Operational', sensor_role = 2671, sensor_guid = 'T5Z37W-0HMCI67HH16EG', sensor_dbid = 3696, sensor_type = 2003 }, [18] = { sensor_isactive = 'No', sensor_name = 'STIR 180 [Radar]', sensor_maxrange = 32, sensor_status = 'Operational', sensor_role = 2143, sensor_guid = 'T5Z37W-0HMCI67HH16EI', sensor_dbid = 3146, sensor_type = 2001 }, [19] = { sensor_isactive = 'No', sensor_name = 'STIR 180 [IR Camera]', sensor_maxrange = 100, sensor_status = 'Operational', sensor_role = 2871, sensor_guid = 'T5Z37W-0HMCI67HH16EJ', sensor_dbid = 3695, sensor_type = 2004 }, [20] = { sensor_isactive = 'No', sensor_name = 'STIR 180 [TV Camera]', sensor_maxrange = 100, sensor_status = 'Operational', sensor_role = 2671, sensor_guid = 'T5Z37W-0HMCI67HH16EK', sensor_dbid = 3696, sensor_type = 2003 }, [21] = { sensor_isactive = 'No', sensor_name = 'Mk1 Eyeball', sensor_maxrange = 50, sensor_status = 'Operational', sensor_role = 2016, sensor_guid = 'T5Z37W-0HMCI67HH16EL', sensor_dbid = 0, sensor_type = 2003 }, [22] = { sensor_isactive = 'No', sensor_name = 'Goalkeeper Tracker [Radar]', sensor_maxrange = 6, sensor_status = 'Operational', sensor_role = 2191, sensor_guid = 'T5Z37W-0HMCI67HH16F7', sensor_dbid = 1153, sensor_type = 2001 }, [23] = { sensor_isactive = 'No', sensor_name = 'Goalkeeper Acquisition [Radar]', sensor_maxrange = 12, sensor_status = 'Operational', sensor_role = 2103, sensor_guid = 'T5Z37W-0HMCI67HH16F8', sensor_dbid = 4252, sensor_type = 2001 }, [24] = { sensor_isactive = 'No', sensor_name = 'Generic Gun Director [TV Camera]', sensor_maxrange = 80, sensor_status = 'Operational', sensor_role = 2681, sensor_guid = 'T5Z37W-0HMCI67HH16F9', sensor_dbid = 4230, sensor_type = 2003 } } >> local u = ScenEdit_GetUnit({name='boat',side='player'}) Then you can query from there. local u = ScenEdit_GetUnit({name='boat',side='player'}) print(u.sensors[1].sensor_isactive) 'No'
_____________________________
|