ACE3/addons/spectator/UI/interface.hpp

212 lines
7.3 KiB
C++
Raw Normal View History

2015-07-16 22:58:58 +00:00
class RscButtonMenu;
2015-07-17 12:08:35 +00:00
class RscControlsGroupNoScrollbars;
2015-07-17 15:02:38 +00:00
class RscFrame;
2015-07-15 10:38:33 +00:00
class RscMapControl;
2015-07-16 14:51:32 +00:00
class RscPicture;
2015-07-15 10:38:33 +00:00
class RscStructuredText;
class RscText;
class RscTree;
2015-07-17 00:44:49 +00:00
class GVAR(interface) {
2015-07-15 10:38:33 +00:00
idd = 12249;
enableSimulation = 1;
movingEnable = 0;
2015-07-15 11:03:54 +00:00
onLoad = QUOTE([ARR_2('onLoad',_this)] call FUNC(handleInterface));
onUnload = QUOTE([ARR_2('onUnload',_this)] call FUNC(handleInterface));
onKeyDown = QUOTE([ARR_2('onKeyDown',_this)] call FUNC(handleInterface));
onKeyUp = QUOTE([ARR_2('onKeyUp',_this)] call FUNC(handleInterface));
2015-07-15 11:11:19 +00:00
class controlsBackground {
2015-07-17 12:08:35 +00:00
class mouseHandler: RscControlsGroupNoScrollbars {
2015-07-15 11:11:19 +00:00
x = safeZoneXAbs;
y = safeZoneY;
w = safeZoneWAbs;
h = safeZoneH;
onMouseButtonDown = QUOTE([ARR_2('onMouseButtonDown',_this)] call FUNC(handleInterface));
onMouseButtonUp = QUOTE([ARR_2('onMouseButtonUp',_this)] call FUNC(handleInterface));
onMouseZChanged = QUOTE([ARR_2('onMouseZChanged',_this)] call FUNC(handleInterface));
onMouseMoving = QUOTE([ARR_2('onMouseMoving',_this)] call FUNC(handleInterface));
};
};
class controls {
2015-07-17 12:08:35 +00:00
class compass: RscControlsGroupNoScrollbars {
2015-07-16 22:58:58 +00:00
idc = IDC_COMP;
2015-07-18 12:12:34 +00:00
x = COMPASS_X;
2015-07-15 10:38:33 +00:00
y = safeZoneY;
2015-07-18 12:12:34 +00:00
w = COMPASS_W;
2015-07-16 22:58:58 +00:00
h = TOOL_H;
2015-07-16 18:47:55 +00:00
class controls {
class compassBack: RscText {
2015-07-18 12:12:34 +00:00
x = 0;
2015-07-16 18:47:55 +00:00
y = 0;
w = COMPASS_W;
h = TOOL_H;
2015-07-18 12:12:34 +00:00
colorBackground[] = {COL_BACK};
2015-07-16 18:47:55 +00:00
};
class compass0_90: RscPicture {
idc = IDC_COMP_0;
2015-07-18 12:12:34 +00:00
x = COMPASS_W * 0.5;
2015-07-16 18:47:55 +00:00
y = 0;
w = COMPASS_W * 0.5;
h = TOOL_H;
text = "A3\ui_f_curator\data\cfgIngameUI\compass\texture180_ca.paa";
};
class compass90_180: compass0_90 {
idc = IDC_COMP_90;
2015-07-18 12:12:34 +00:00
x = COMPASS_W;
2015-07-16 18:47:55 +00:00
text = "A3\ui_f_curator\data\cfgIngameUI\compass\texture270_ca.paa";
};
class compass180_270: compass0_90 {
idc = IDC_COMP_180;
2015-07-18 12:12:34 +00:00
x = COMPASS_W * 1.5;
2015-07-16 18:47:55 +00:00
text = "A3\ui_f_curator\data\cfgIngameUI\compass\texture0_ca.paa";
};
class compass270_0: compass0_90 {
idc = IDC_COMP_270;
2015-07-18 12:12:34 +00:00
x = COMPASS_W * 2;
2015-07-16 18:47:55 +00:00
text = "A3\ui_f_curator\data\cfgIngameUI\compass\texture90_ca.paa";
};
2015-07-17 15:02:38 +00:00
class compassCaret: RscFrame {
2015-07-18 12:12:34 +00:00
x = COMPASS_W * 0.5;
2015-07-17 15:02:38 +00:00
y = 0;
w = 0;
h = TOOL_H;
2015-07-18 12:12:34 +00:00
colorText[] = {COL_FORE};
2015-07-16 18:47:55 +00:00
};
class compassFrame: compassBack {
style = 64;
shadow=2;
2015-07-18 12:12:34 +00:00
colorText[] = {COL_FORE};
2015-07-16 18:47:55 +00:00
};
};
2015-07-15 10:38:33 +00:00
};
class nameTool: RscText {
2015-07-16 22:58:58 +00:00
idc = IDC_TOOL_NAME;
2015-07-15 10:38:33 +00:00
x = safeZoneX;
y = safeZoneY;
w = TOOL_W * 2;
h = TOOL_H;
shadow = 2;
2015-07-18 12:12:34 +00:00
colorText[]={COL_FORE};
colorBackground[] = {COL_BACK};
2015-07-16 18:47:55 +00:00
sizeEx = H_PART(1);
2015-07-15 10:38:33 +00:00
};
class nameFrame: nameTool {
idc = -1;
style = 64;
};
class viewTool: nameTool {
2015-07-16 22:58:58 +00:00
idc = IDC_TOOL_VIEW;
2015-07-15 10:38:33 +00:00
x = safeZoneX + TOOL_W * 2 + MARGIN;
w = TOOL_W;
};
class viewFrame: viewTool {
idc = -1;
style = 64;
};
class clockTool: viewTool {
2015-07-16 22:58:58 +00:00
idc = IDC_TOOL_CLOCK;
2015-07-15 10:38:33 +00:00
x = safeZoneX + TOOL_W * 3 + MARGIN * 2;
};
class clockFrame: clockTool {
idc = -1;
style = 64;
};
class focusTool: viewTool {
2015-07-16 22:58:58 +00:00
idc = IDC_TOOL_FOCUS;
2015-07-15 10:38:33 +00:00
x = safeZoneX + safeZoneW - TOOL_W * 3 - MARGIN * 2;
};
class focusFrame: focusTool {
idc = -1;
style = 64;
};
class fovTool: viewTool {
2015-07-16 22:58:58 +00:00
idc = IDC_TOOL_FOV;
2015-07-16 18:47:55 +00:00
x = safeZoneX + safeZoneW - TOOL_W * 2 - MARGIN;
2015-07-15 10:38:33 +00:00
};
class fovFrame: fovTool {
idc = -1;
style = 64;
};
class speedTool: viewTool {
2015-07-16 22:58:58 +00:00
idc = IDC_TOOL_SPEED;
2015-07-15 10:38:33 +00:00
x = safeZoneX + safeZoneW - TOOL_W;
};
class speedFrame: speedTool {
idc = -1;
style = 64;
};
2015-07-17 12:08:35 +00:00
class unitTools: RscControlsGroupNoScrollbars {
2015-07-17 00:44:49 +00:00
idc = IDC_UNIT;
2015-07-15 10:38:33 +00:00
x = safeZoneX;
2015-07-17 01:55:48 +00:00
y = safeZoneY;
2015-07-15 10:38:33 +00:00
w = TOOL_W * 2;
2015-07-17 01:55:48 +00:00
h = safeZoneH;
2015-07-17 00:44:49 +00:00
class controls {
class unitTree: RscTree {
idc = IDC_UNIT_TREE;
x = 0;
2015-07-17 01:55:48 +00:00
y = TOOL_H * 2;
2015-07-17 00:44:49 +00:00
w = TOOL_W * 2;
h = safeZoneH - TOOL_H * 5;
2015-07-17 12:08:35 +00:00
sizeEx = H_PART(0.8);
2015-07-17 00:44:49 +00:00
borderSize = 1;
2015-07-18 12:12:34 +00:00
colorBorder[] = {COL_FORE};
colorBackground[] = {COL_BACK};
2015-07-17 00:44:49 +00:00
colorSelect[] = {
"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.3843])",
"(profilenamespace getvariable ['GUI_BCG_RGB_G',0.7019])",
"(profilenamespace getvariable ['GUI_BCG_RGB_B',0.8862])",
1
};
multiselectEnabled = 0;
onTreeDblClick = QUOTE([ARR_2('onTreeDblClick',_this)] call FUNC(handleInterface));
};
class unitRefresh: RscButtonMenu {
x = 0;
2015-07-17 01:55:48 +00:00
y = safeZoneH - TOOL_H * 3;
2015-07-17 00:44:49 +00:00
w = TOOL_W * 2;
h = TOOL_H;
sizeEx = TOOL_H;
text = CSTRING(RefreshList);
2015-07-17 15:02:38 +00:00
action = QUOTE([] call FUNC(updateUnits));
2015-07-17 00:44:49 +00:00
};
2015-07-15 10:38:33 +00:00
};
2015-07-16 22:58:58 +00:00
};
2015-07-15 10:38:33 +00:00
class spectatorMap: RscMapControl {
idc = IDC_MAP;
x = safeZoneX;
y = safeZoneY + TOOL_H;
w = safeZoneW;
h = safeZoneH;
};
2015-07-17 12:08:35 +00:00
class helpBox: RscControlsGroupNoScrollbars {
2015-07-16 18:47:55 +00:00
idc = IDC_HELP;
2015-07-15 10:38:33 +00:00
x = 0.5 - W_PART(12);
y = 0.5 - H_PART(12);
w = W_PART(24);
h = H_PART(24);
2015-07-16 18:47:55 +00:00
class controls {
class helpBack: RscText {
x = 0;
y = 0;
w = W_PART(24);
h = H_PART(24);
2015-07-18 12:12:34 +00:00
colorBackground[] = {COL_BACK};
2015-07-16 18:47:55 +00:00
};
class helpTitle: helpBack {
h = H_PART(1);
2015-07-18 12:12:34 +00:00
colorText[]={COL_FORE};
2015-07-16 18:47:55 +00:00
colorBackground[] = {
"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.3843])",
"(profilenamespace getvariable ['GUI_BCG_RGB_G',0.7019])",
"(profilenamespace getvariable ['GUI_BCG_RGB_B',0.8862])",
1
};
2015-07-16 22:58:58 +00:00
sizeEx = H_PART(1);
2015-07-16 18:47:55 +00:00
text = CSTRING(HelpTitle);
};
2015-07-15 10:38:33 +00:00
};
};
};
};