2023-09-12 18:58:10 +00:00
|
|
|
#include "..\script_component.hpp"
|
2015-04-17 22:11:53 +00:00
|
|
|
/*
|
|
|
|
* Author: Ruthberg
|
|
|
|
* Updates all target column input fields
|
|
|
|
*
|
|
|
|
* Arguments:
|
2017-06-08 13:31:51 +00:00
|
|
|
* None
|
2015-04-17 22:11:53 +00:00
|
|
|
*
|
|
|
|
* Return Value:
|
2017-06-08 13:31:51 +00:00
|
|
|
* None
|
2015-04-17 22:11:53 +00:00
|
|
|
*
|
|
|
|
* Example:
|
2020-04-25 06:41:45 +00:00
|
|
|
* call ace_atragmx_fnc_update_target_data
|
2015-04-17 22:11:53 +00:00
|
|
|
*
|
|
|
|
* Public: No
|
|
|
|
*/
|
|
|
|
|
|
|
|
ctrlSetText [140000, Str(Round((GVAR(latitude) select GVAR(currentTarget)) * 100) / 100)];
|
|
|
|
ctrlSetText [140010, Str(Round((GVAR(directionOfFire) select GVAR(currentTarget)) * 100) / 100)];
|
2015-04-18 10:12:19 +00:00
|
|
|
if (GVAR(currentUnit) != 2) then {
|
|
|
|
ctrlSetText [140020, Str(Round((GVAR(windSpeed1) select GVAR(currentTarget)) * 2.23693629 * 100) / 100)];
|
|
|
|
ctrlSetText [140021, Str(Round((GVAR(windSpeed2) select GVAR(currentTarget)) * 2.23693629 * 100) / 100)];
|
|
|
|
} else {
|
|
|
|
ctrlSetText [140020, Str(Round((GVAR(windSpeed1) select GVAR(currentTarget)) * 100) / 100)];
|
|
|
|
ctrlSetText [140021, Str(Round((GVAR(windSpeed2) select GVAR(currentTarget)) * 100) / 100)];
|
|
|
|
};
|
2015-04-17 22:11:53 +00:00
|
|
|
ctrlSetText [140030, Str(Round((GVAR(windDirection) select GVAR(currentTarget))))];
|
|
|
|
ctrlSetText [140040, Str(Round((GVAR(inclinationAngle) select GVAR(currentTarget))))];
|
2015-04-18 15:45:32 +00:00
|
|
|
ctrlSetText [140041, Str(Round(cos(GVAR(inclinationAngle) select GVAR(currentTarget)) * 100) / 100)];
|
2015-04-18 10:12:19 +00:00
|
|
|
if (GVAR(currentUnit) != 2) then {
|
|
|
|
ctrlSetText [140050, Str(Round((GVAR(targetSpeed) select GVAR(currentTarget)) * 2.23693629 * 100) / 100)];
|
|
|
|
} else {
|
|
|
|
ctrlSetText [140050, Str(Round((GVAR(targetSpeed) select GVAR(currentTarget)) * 100) / 100)];
|
|
|
|
};
|
2015-04-21 13:46:53 +00:00
|
|
|
if ((GVAR(targetSpeedDirection) select GVAR(currentTarget)) == 1) then {
|
|
|
|
ctrlSetText [140051, ">"];
|
|
|
|
} else {
|
|
|
|
ctrlSetText [140051, "<"];
|
|
|
|
};
|
2015-04-18 10:12:19 +00:00
|
|
|
if (GVAR(currentUnit) == 1) then {
|
|
|
|
ctrlSetText [140060, Str(Round((GVAR(targetRange) select GVAR(currentTarget)) * 1.0936133))];
|
|
|
|
} else {
|
|
|
|
ctrlSetText [140060, Str(Round((GVAR(targetRange) select GVAR(currentTarget))))];
|
|
|
|
};
|
2015-04-20 08:36:20 +00:00
|
|
|
if (GVAR(currentUnit) == 0) then {
|
|
|
|
ctrlSetText [140061, "*"];
|
|
|
|
} else {
|
|
|
|
ctrlSetText [140061, ""];
|
|
|
|
};
|
2015-04-17 22:11:53 +00:00
|
|
|
|
|
|
|
if (GVAR(currentUnit) == 2) then {
|
|
|
|
ctrlSetText [14002, "Wind Speed (m/s)"];
|
|
|
|
ctrlSetText [14005, "Target Speed (m/s)"];
|
|
|
|
} else {
|
|
|
|
ctrlSetText [14002, "Wind Speed (mph)"];
|
|
|
|
ctrlSetText [14005, "Target Speed (mph)"];
|
|
|
|
};
|
|
|
|
|
|
|
|
if (GVAR(currentUnit) == 1) then {
|
|
|
|
ctrlSetText [14006, "Target Range (yards)"];
|
|
|
|
} else {
|
|
|
|
ctrlSetText [14006, "Target Range (meters)"];
|
|
|
|
};
|