Finnish porting agm_core. Replace all AGM prefixes by ACE, including stringtables and main variables like ACE_player

This commit is contained in:
Nicolás Badano 2015-01-12 01:02:33 -03:00
parent ee8faadc4b
commit 306dce2153
160 changed files with 795 additions and 695 deletions

View File

@ -1,147 +0,0 @@
class CfgFunctions {
class ADDON {
class ADDON {
file = PATHTOF(functions\);
class addActionEventHandler;
class addActionMenuEventHandler;
class addCameraEventHandler;
class addCustomEventHandler;
class addInfoDisplayEventHandler;
class addMapMarkerCreatedEventHandler;
class addInventoryDisplayLoadedEventHandler;
class addScrollWheelEventHandler;
class adminKick;
class ambientBrightness;
class applyForceWalkStatus;
class binarizeNumber;
class callCustomEventHandlers;
class callCustomEventHandlersGlobal;
class canGetInPosition;
class canInteractWith;
class canUseWeapon;
class changeProjectileDirection;
class checkPBOs;
class claim;
class closeDialogIfTargetMoves;
class codeToLetter;
class codeToString;
class convertKeyCode;
class currentChannel;
class disableUserInput;
class displayText;
class displayTextPicture;
class displayTextStructured;
class doAnimation;
class endRadioTransmission;
class execPersistentFnc;
class execRemoteFnc;
class executePersistent;
class filter;
class fixLoweredRifleAnimation;
class getCaptivityStatus;
class getConfigCommander;
class getConfigGunner;
class getDefaultAnim;
class getDoorTurrets;
class getForceWalkStatus;
class getHitPoints;
class getHitPointsWithSelections;
class getInPosition;
class getMarkerType;
class getName;
class getNumberFromMissionSQM;
class getPitchBankYaw;
class getStringFromMissionSQM;
class getTargetAzimuthAndInclination;
class getTargetDistance;
class getTargetObject;
class getTurretCommander;
class getTurretConfigPath;
class getTurretCopilot;
class getTurretGunner;
class getTurretIndex;
class getTurrets;
class getTurretsFFV;
class getTurretsOther;
class getUavControlPosition;
class getVehicleCargo;
class getVehicleCodriver;
class getVehicleCrew;
class getWeaponAzimuthAndInclination;
class getWeaponType;
class getWindDirection;
class goKneeling;
class hadamardProduct;
class interpolateFromArray;
class inTransitionAnim;
class isAutoWind;
class isEngineer;
class isEOD;
class isInBuilding;
class isMedic;
class isPlayer;
class isTurnedOut;
class letterToCode;
class map;
class moduleCheckPBOs;
class moduleLSDVehicles;
class muteUnit;
class numberToDigits;
class numberToDigitsString;
class onLoadRscDisplayChannel;
class owned;
class player;
class playerSide;
class progressBar;
class queueAnimation;
class readBooleanParameterFromModule;
class readNumericParameterFromModule;
class removeActionEventHandler;
class removeActionMenuEventHandler;
class removeCameraEventHandler;
class removeCustomEventHandler;
class removeInfoDisplayEventHandler;
class removeInventoryDisplayLoadedEventHandler;
class removeMapMarkerCreatedEventHandler;
class removeScrollWheelEventHandler;
class restoreVariablesJIP;
class revertKeyCodeLocalized;
class sanitizeString;
class serverLog;
class setCaptivityStatus;
class setForceWalkStatus;
class setKeyDefault;
class setName;
class setParameter;
class setPitchBankYaw;
class setVariableJIP;
class stringToColoredText;
class subString;
class toBin;
class toBitmask;
class toHex;
class toNumber;
class unmuteUnit;
};
};
class AGM_Debug {
class AGM_Debug {
file = PATHTOF(functions\Debug);
class exportConfig;
class getChildren;
class getDisplayConfigName;
class log;
class logControls;
class logDisplays;
class monitor;
class showUser;
};
};
class AGM_CuratorFix {
class AGM_CuratorFix {
file = PATHTOF(functions\CuratorFix);
class addUnloadEventhandler;
class fixCrateContent;
};
};
};

View File

@ -1,7 +1,7 @@
class CfgSounds {
class AGM_Sound_Click {
sound[] = {PATHTOF(sounds\AGM_click.wav), 1, 1, 200};
class ACE_Sound_Click {
sound[] = {PATHTOF(sounds\ACE_click.wav), 1, 1, 200};
titles[] = {};
};
};

View File

@ -3,7 +3,7 @@ class CfgVehicles {
class CAManBase: Man {
// @todo
class UserActions {
class AGM_Fire {
class ACE_Fire {
displayName = "";
priority = -99;
available = 1;
@ -14,8 +14,8 @@ class CfgVehicles {
showIn3D = 0;
onlyForPlayer = 1;
shortcut = "DefaultAction";
condition = "call AGM_Core_UserActionFireCondition";
statement = "call AGM_Core_UserActionFire";
condition = "call ACE_Core_UserActionFireCondition";
statement = "call ACE_Core_UserActionFire";
userActionID = 100;
};
};
@ -25,11 +25,11 @@ class CfgVehicles {
//#include <DefaultItems.hpp>
class Module_F;
class AGM_ModuleCheckPBOs: Module_F {
author = "$STR_AGM_Core_AGMTeam";
category = "AGM";
class ACE_ModuleCheckPBOs: Module_F {
author = "$STR_ACE_Core_ACETeam";
category = "ACE";
displayName = "Check PBOs";
function = "AGM_Core_fnc_moduleCheckPBOs";
function = "ACE_Core_fnc_moduleCheckPBOs";
scope = 2;
isGlobal = 1;
icon = PATHTOF(UI\IconCheckPBO_ca.paa);
@ -55,7 +55,7 @@ class CfgVehicles {
};
class CheckAll {
displayName = "Check all addons";
description = "Check all addons instead of only those of AGM?";
description = "Check all addons instead of only those of ACE?";
typeName = "BOOL";
class values {
class WarnOnce {
@ -80,11 +80,11 @@ class CfgVehicles {
};
};
class AGM_ModuleLSDVehicles: Module_F {
author = "$STR_AGM_Core_AGMTeam";
category = "AGM";
class ACE_ModuleLSDVehicles: Module_F {
author = "$STR_ACE_Core_ACETeam";
category = "ACE";
displayName = "LSD Vehicles";
function = "AGM_Core_fnc_moduleLSDVehicles";
function = "ACE_Core_fnc_moduleLSDVehicles";
scope = 2;
isGlobal = 1;
class Arguments {
@ -92,9 +92,9 @@ class CfgVehicles {
};
class Box_NATO_Support_F;
class AGM_Box_Misc: Box_NATO_Support_F {
author = "$STR_AGM_Core_AGMTeam";
displayName = "$STR_AGM_Core_MiscItems";
class ACE_Box_Misc: Box_NATO_Support_F {
author = "$STR_ACE_Core_ACETeam";
displayName = "$STR_ACE_Core_MiscItems";
transportMaxWeapons = 9001;
transportMaxMagazines = 9001;
transportMaxItems = 9001;

View File

@ -1,19 +1,19 @@
class CfgWeapons {
class ItemCore;
class AGM_ItemCore: ItemCore {
class ACE_ItemCore: ItemCore {
type = 4096;//4;
detectRange = -1;
simulation = "ItemMineDetector";
};
class Rifle_Base_F;
class AGM_FakePrimaryWeapon: Rifle_Base_F {
class ACE_FakePrimaryWeapon: Rifle_Base_F {
discreteDistance[] = {};
discreteDistanceInitIndex = 0;
displayName = "";
picture = "";
model = "";
magazines[] = {"AGM_FakeMagazine"};
magazines[] = {"ACE_FakeMagazine"};
scope = 2;
};
};
@ -21,7 +21,7 @@ class CfgWeapons {
class CfgMagazines {
class CA_Magazine;
class AGM_FakeMagazine: CA_Magazine {
class ACE_FakeMagazine: CA_Magazine {
descriptionShort = "";
displayName = "";
displayNameShort = "";

View File

@ -29,7 +29,7 @@ class CfgMovesMaleSdr: CfgMovesBasic {
};
class LadderCivilStatic: StandBase {
AGM_isLadder = 1;
ACE_isLadder = 1;
};
};
};

View File

@ -4,14 +4,14 @@ class RscStructuredText;
class RscMapControl;
class RscTitles {
class AGM_RscHint {
class ACE_RscHint {
idd = -1;
onLoad = "uiNamespace setVariable ['AGM_ctrlHint', (_this select 0) displayCtrl 1];";
onLoad = "uiNamespace setVariable ['ACE_ctrlHint', (_this select 0) displayCtrl 1];";
movingEnable = false;
duration = 4;
fadeIn = 0.2;
fadeOut = 0.2;
name = "AGM_RscHint";
name = "ACE_RscHint";
class controls {
class HintBox: RscStructuredText {
@ -28,14 +28,14 @@ class RscTitles {
};
};
};
class AGM_RscErrorHint {
class ACE_RscErrorHint {
idd = -1;
onLoad = "uiNamespace setVariable ['AGM_ctrlErrorHint', (_this select 0) displayCtrl 1];";
onLoad = "uiNamespace setVariable ['ACE_ctrlErrorHint', (_this select 0) displayCtrl 1];";
movingEnable = false;
duration = 999999;
fadeIn = 0.2;
fadeOut = 0.2;
name = "AGM_RscErrorHint";
name = "ACE_RscErrorHint";
class controls {
class HintBox: RscStructuredText {
@ -52,21 +52,21 @@ class RscTitles {
};
};
};
class AGM_EventHandlerHelper: AGM_Rsc_Display_Base {
class ACE_EventHandlerHelper: ACE_Rsc_Display_Base {
idd = -1;
class controls {
class CameraView: RscMapControl {
onDraw = "if (cameraView != uiNamespace getVariable 'AGM_EventHandler_CameraMode') then {uiNamespace setVariable ['AGM_EventHandler_CameraMode', cameraView]; {[uiNamespace getVariable 'AGM_EventHandler_CameraMode'] call _x; nil} count ((missionNamespace getVariable 'AGM_EventHandler_CameraMode') select 2);};";
onDraw = "if (cameraView != uiNamespace getVariable 'ACE_EventHandler_CameraMode') then {uiNamespace setVariable ['ACE_EventHandler_CameraMode', cameraView]; {[uiNamespace getVariable 'ACE_EventHandler_CameraMode'] call _x; nil} count ((missionNamespace getVariable 'ACE_EventHandler_CameraMode') select 2);};";
idc = -1;
w = 0;
h = 0;
};
};
};
class AGM_EventHandlerHelper2: AGM_Rsc_Display_Base {
class ACE_EventHandlerHelper2: ACE_Rsc_Display_Base {
class controls {
class MapMarkerCreated: RscMapControl {
onDraw = "if (count allMapMarkers != uiNamespace getVariable 'AGM_EventHandler_MapMarker') then {if (count allMapMarkers > uiNamespace getVariable 'AGM_EventHandler_MapMarker') then {{[allMapMarkers select count allMapMarkers - 1] call _x; nil} count ((missionNamespace getVariable 'AGM_EventHandler_MapMarker') select 2);}; uiNamespace setVariable ['AGM_EventHandler_MapMarker', count allMapMarkers];};";
onDraw = "if (count allMapMarkers != uiNamespace getVariable 'ACE_EventHandler_MapMarker') then {if (count allMapMarkers > uiNamespace getVariable 'ACE_EventHandler_MapMarker') then {{[allMapMarkers select count allMapMarkers - 1] call _x; nil} count ((missionNamespace getVariable 'ACE_EventHandler_MapMarker') select 2);}; uiNamespace setVariable ['ACE_EventHandler_MapMarker', count allMapMarkers];};";
idc = -1;
w = 0;
h = 0;

View File

@ -1,5 +1,5 @@
class AGM_Tile_Base {
class ACE_Tile_Base {
class Attributes {
font = "PuristaMedium";
color = "#E5E5E5";
@ -29,7 +29,7 @@ class AGM_Tile_Base {
right = 0;
bottom = 0;
};
action = "(findDisplay 49) closeDisplay 0; 0 spawn AGM_Core_openMenu;";
action = "(findDisplay 49) closeDisplay 0; 0 spawn ACE_Core_openMenu;";
animTextureDefault = "#(argb,8,8,3)color(1,1,1,1)";
animTextureDisabled = "#(argb,8,8,3)color(1,1,1,1)";
animTextureFocused = "#(argb,8,8,3)color(1,1,1,1)";
@ -61,7 +61,7 @@ class AGM_Tile_Base {
soundEscape[] = {"\A3\ui_f\data\sound\RscButtonMenu\soundEscape",0.09,1};
soundPush[] = {"\A3\ui_f\data\sound\RscButtonMenu\soundPush",0.09,1};
style = "0x02 + 0xC0";
text = "$STR_AGM_Core_Options";
text = "$STR_ACE_Core_Options";
textureNoShortcut = "#(argb,8,8,3)color(0,0,0,0)";
tooltip = "";
tooltipColorBox[] = {1,1,1,1};
@ -78,26 +78,26 @@ class RscStandardDisplay;
/*class RscDisplayMain: RscStandardDisplay {
class controls {
class AGM_Tile : AGM_Tile_Base {};
class ACE_Tile : ACE_Tile_Base {};
};
};*/
class RscDisplayMPInterrupt: RscStandardDisplay {
class controls {
class AGM_Tile : AGM_Tile_Base {};
class ACE_Tile : ACE_Tile_Base {};
};
};
class RscDisplayInterrupt: RscStandardDisplay {
class controls {
class AGM_Tile : AGM_Tile_Base {};
class ACE_Tile : ACE_Tile_Base {};
};
};
class RscDisplayInterruptEditor3D: RscStandardDisplay {
class controls {
class AGM_Tile : AGM_Tile_Base {};
class ACE_Tile : ACE_Tile_Base {};
};
};
class RscDisplayInterruptEditorPreview: RscStandardDisplay {
class controls {
class AGM_Tile : AGM_Tile_Base {};
class ACE_Tile : ACE_Tile_Base {};
};
};

View File

@ -3,7 +3,7 @@
#define VSPACE 0.3
#define BORDER 0.1
class AGM_Core_Interactive_Button_Base {
class ACE_Core_Interactive_Button_Base {
tooltip = "";
action = "";
@ -46,7 +46,7 @@ class AGM_Core_Interactive_Button_Base {
#define VSPACE2 0.05
#define BORDER 0.1
class AGM_Core_Text_Button_Base {
class ACE_Core_Text_Button_Base {
idc = 2;
moving = 0;
text = "";
@ -65,10 +65,10 @@ class AGM_Core_Text_Button_Base {
h = 0;
};
class AGM_Core_OptionsMenu_Dialog {
class ACE_Core_OptionsMenu_Dialog {
idd = -1;
movingEnable = true;
onLoad = "_dlgMenuDialog = _this select 0; for '_a' from 20 to 32 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 100 to 119 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 200 to 219 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 300 to 319 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 400 to 419 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 500 to 519 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; uiNamespace setVariable ['AGM_Core_MenuDialog', _dlgMenuDialog];";
onLoad = "_dlgMenuDialog = _this select 0; for '_a' from 20 to 32 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 100 to 119 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 200 to 219 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 300 to 319 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 400 to 419 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; for '_a' from 500 to 519 do {(_dlgMenuDialog displayCtrl _a) ctrlShow false}; uiNamespace setVariable ['ACE_Core_MenuDialog', _dlgMenuDialog];";
objects[] = {};
class controlsBackground {
@ -95,7 +95,7 @@ class AGM_Core_OptionsMenu_Dialog {
class Header {
idc = 2;
moving = 0;
text = "$STR_AGM_Core_Options";
text = "$STR_ACE_Core_Options";
font = "PuristaMedium";
sizeEx = "1 / 40 / (getResolution select 5)";// * safezoneX / safezoneXAbs";
lineSpacing = 0;
@ -112,13 +112,13 @@ class AGM_Core_OptionsMenu_Dialog {
h = 0.3 / 9 * safezoneH;
};
class AGM_Logo : AGM_Core_Interactive_Button_Base {
class ACE_Logo : ACE_Core_Interactive_Button_Base {
action = "closeDialog 0;";
type = 0;
style = 48;
onMouseEnter = "hint ('_' + str(_this))";
tooltip = "";
text = "";//"\AGM_common\rsc\bwlogo.paa";
text = "";//"\ACE_common\rsc\bwlogo.paa";
idc = 2;
x = ((1 - 2 * HSPACE2 / 2) - (HSPACE2 + 0.5 * 0.1)) * safezoneW + safezoneX;
y = (VSPACE2 + 2 * 0.04) * safezoneH + safezoneY;
@ -128,7 +128,7 @@ class AGM_Core_OptionsMenu_Dialog {
};
class controls {
class Text_Button0 : AGM_Core_Text_Button_Base {
class Text_Button0 : ACE_Core_Text_Button_Base {
idc = 100;
style = 0 + 0x800;
x = (HSPACE2 + 0 * 0.1) * safezoneW + safezoneX;
@ -234,8 +234,8 @@ class AGM_Core_OptionsMenu_Dialog {
//////////////////////////////////////////////////
class Interactive_Button0 : AGM_Core_Interactive_Button_Base {
action = "AGM_Core_keySet = -1; [0] spawn AGM_Core_editKey";
class Interactive_Button0 : ACE_Core_Interactive_Button_Base {
action = "ACE_Core_keySet = -1; [0] spawn ACE_Core_editKey";
sizeEx = "0.8 / 40 / (getResolution select 5)";// * safezoneX / safezoneXAbs";
idc = 200;
style = 2 + 0x800;
@ -246,115 +246,115 @@ class AGM_Core_OptionsMenu_Dialog {
};
class Interactive_Button1 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [1] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [1] spawn ACE_Core_editKey";
idc = 201;
y = (VSPACE2 + 3 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button2 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [2] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [2] spawn ACE_Core_editKey";
idc = 202;
y = (VSPACE2 + 4 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button3 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [3] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [3] spawn ACE_Core_editKey";
idc = 203;
y = (VSPACE2 + 5 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button4 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [4] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [4] spawn ACE_Core_editKey";
idc = 204;
y = (VSPACE2 + 6 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button5 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [5] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [5] spawn ACE_Core_editKey";
idc = 205;
y = (VSPACE2 + 7 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button6 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [6] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [6] spawn ACE_Core_editKey";
idc = 206;
y = (VSPACE2 + 8 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button7 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [7] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [7] spawn ACE_Core_editKey";
idc = 207;
y = (VSPACE2 + 9 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button8 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [8] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [8] spawn ACE_Core_editKey";
idc = 208;
y = (VSPACE2 + 10 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button9 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [9] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [9] spawn ACE_Core_editKey";
idc = 209;
y = (VSPACE2 + 11 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button10 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [10] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [10] spawn ACE_Core_editKey";
idc = 210;
y = (VSPACE2 + 12 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button11 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [11] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [11] spawn ACE_Core_editKey";
idc = 211;
y = (VSPACE2 + 13 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button12 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [12] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [12] spawn ACE_Core_editKey";
idc = 212;
y = (VSPACE2 + 14 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button13 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [13] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [13] spawn ACE_Core_editKey";
idc = 213;
y = (VSPACE2 + 15 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button14 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [14] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [14] spawn ACE_Core_editKey";
idc = 214;
y = (VSPACE2 + 16 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button15 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [15] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [15] spawn ACE_Core_editKey";
idc = 215;
y = (VSPACE2 + 17 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button16 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [16] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [16] spawn ACE_Core_editKey";
idc = 216;
y = (VSPACE2 + 18 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button17 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [17] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [17] spawn ACE_Core_editKey";
idc = 217;
y = (VSPACE2 + 19 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button18 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [18] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [18] spawn ACE_Core_editKey";
idc = 218;
y = (VSPACE2 + 20 * 0.04) * safezoneH + safezoneY;
};
class Interactive_Button19 : Interactive_Button0 {
action = "AGM_Core_keySet = -1; [19] spawn AGM_Core_editKey";
action = "ACE_Core_keySet = -1; [19] spawn ACE_Core_editKey";
idc = 219;
y = (VSPACE2 + 21 * 0.04) * safezoneH + safezoneY;
};
@ -596,8 +596,8 @@ class AGM_Core_OptionsMenu_Dialog {
//////////////////////////////////////////////////
class Interactive_CheckboxButton0 : AGM_Core_Interactive_Button_Base {
action = "[0] call AGM_Core_toggleState";
class Interactive_CheckboxButton0 : ACE_Core_Interactive_Button_Base {
action = "[0] call ACE_Core_toggleState";
idc = 500;
colorBackground[] = {0, 0, 0, 0};
colorBackgroundActive[] = {0, 0, 0, 0};
@ -609,115 +609,115 @@ class AGM_Core_OptionsMenu_Dialog {
};
class Interactive_CheckboxButton1 : Interactive_CheckboxButton0 {
action = "[1] call AGM_Core_toggleState";
action = "[1] call ACE_Core_toggleState";
idc = 501;
y = (VSPACE2 + 3 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton2 : Interactive_CheckboxButton0 {
action = "[2] call AGM_Core_toggleState";
action = "[2] call ACE_Core_toggleState";
idc = 502;
y = (VSPACE2 + 4 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton3 : Interactive_CheckboxButton0 {
action = "[3] call AGM_Core_toggleState";
action = "[3] call ACE_Core_toggleState";
idc = 503;
y = (VSPACE2 + 5 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton4 : Interactive_CheckboxButton0 {
action = "[4] call AGM_Core_toggleState";
action = "[4] call ACE_Core_toggleState";
idc = 504;
y = (VSPACE2 + 6 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton5 : Interactive_CheckboxButton0 {
action = "[5] call AGM_Core_toggleState";
action = "[5] call ACE_Core_toggleState";
idc = 505;
y = (VSPACE2 + 7 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton6 : Interactive_CheckboxButton0 {
action = "[6] call AGM_Core_toggleState";
action = "[6] call ACE_Core_toggleState";
idc = 506;
y = (VSPACE2 + 8 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton7 : Interactive_CheckboxButton0 {
action = "[7] call AGM_Core_toggleState";
action = "[7] call ACE_Core_toggleState";
idc = 507;
y = (VSPACE2 + 9 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton8 : Interactive_CheckboxButton0 {
action = "[8] call AGM_Core_toggleState";
action = "[8] call ACE_Core_toggleState";
idc = 508;
y = (VSPACE2 + 10 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton9 : Interactive_CheckboxButton0 {
action = "[9] call AGM_Core_toggleState";
action = "[9] call ACE_Core_toggleState";
idc = 509;
y = (VSPACE2 + 11 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton10 : Interactive_CheckboxButton0 {
action = "[10] call AGM_Core_toggleState";
action = "[10] call ACE_Core_toggleState";
idc = 510;
y = (VSPACE2 + 12 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton11 : Interactive_CheckboxButton0 {
action = "[11] call AGM_Core_toggleState";
action = "[11] call ACE_Core_toggleState";
idc = 511;
y = (VSPACE2 + 13 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton12 : Interactive_CheckboxButton0 {
action = "[12] call AGM_Core_toggleState";
action = "[12] call ACE_Core_toggleState";
idc = 512;
y = (VSPACE2 + 14 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton13 : Interactive_CheckboxButton0 {
action = "[13] call AGM_Core_toggleState";
action = "[13] call ACE_Core_toggleState";
idc = 513;
y = (VSPACE2 + 15 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton14 : Interactive_CheckboxButton0 {
action = "[14] call AGM_Core_toggleState";
action = "[14] call ACE_Core_toggleState";
idc = 514;
y = (VSPACE2 + 16 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton15 : Interactive_CheckboxButton0 {
action = "[15] call AGM_Core_toggleState";
action = "[15] call ACE_Core_toggleState";
idc = 515;
y = (VSPACE2 + 17 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton16 : Interactive_CheckboxButton0 {
action = "[16] call AGM_Core_toggleState";
action = "[16] call ACE_Core_toggleState";
idc = 516;
y = (VSPACE2 + 18 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton17 : Interactive_CheckboxButton0 {
action = "[17] call AGM_Core_toggleState";
action = "[17] call ACE_Core_toggleState";
idc = 517;
y = (VSPACE2 + 19 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton18 : Interactive_CheckboxButton0 {
action = "[18] call AGM_Core_toggleState";
action = "[18] call ACE_Core_toggleState";
idc = 518;
y = (VSPACE2 + 20 * 0.04) * safezoneH + safezoneY;
};
class Interactive_CheckboxButton19 : Interactive_CheckboxButton0 {
action = "[19] call AGM_Core_toggleState";
action = "[19] call ACE_Core_toggleState";
idc = 519;
y = (VSPACE2 + 21 * 0.04) * safezoneH + safezoneY;
};
@ -735,7 +735,7 @@ class AGM_Core_OptionsMenu_Dialog {
};
/*class TextBox_Key_Shift : TextBox_KeyChange {
text = "$STR_AGM_Core_Shift";
text = "$STR_ACE_Core_Shift";
idc = 21;
colorText[] = {0.25,0.25,0.25,1};
colorBackground[] = {0,0,0,0};
@ -746,22 +746,22 @@ class AGM_Core_OptionsMenu_Dialog {
};
class TextBox_Key_Control : TextBox_Key_Shift {
text = "$STR_AGM_Core_Ctrl";
text = "$STR_ACE_Core_Ctrl";
idc = 22;
x = (3 / 4 * HSPACE2 + 6.75 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 10 * 0.04) * safezoneH + safezoneY;
};
class TextBox_Key_Alt : TextBox_Key_Shift {
text = "$STR_AGM_Core_Alt";
text = "$STR_ACE_Core_Alt";
idc = 23;
x = (3 / 4 * HSPACE2 + 7.75 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 10 * 0.04) * safezoneH + safezoneY;
};*/
class TextBox_Key_Shift : Interactive_Button0 {
action = "AGM_Core_keyNewTemp = [42, [false, false, false], 42];";
text = "$STR_AGM_Core_Shift";
action = "ACE_Core_keyNewTemp = [42, [false, false, false], 42];";
text = "$STR_ACE_Core_Shift";
sizeEx = "0.7 / 40 / (getResolution select 5)";// * safezoneX / safezoneXAbs";
idc = 21;
colorText[] = {1,1,1,1};
@ -773,40 +773,40 @@ class AGM_Core_OptionsMenu_Dialog {
};
class TextBox_Key_Control : TextBox_Key_Shift {
action = "AGM_Core_keyNewTemp = [29, [false, false, false], 29];";
text = "$STR_AGM_Core_Ctrl";
action = "ACE_Core_keyNewTemp = [29, [false, false, false], 29];";
text = "$STR_ACE_Core_Ctrl";
idc = 22;
x = (3 / 4 * HSPACE2 + 6.75 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 10 * 0.04) * safezoneH + safezoneY;
};
class TextBox_Key_Alt : TextBox_Key_Shift {
action = "AGM_Core_keyNewTemp = [56, [false, false, false], 56];";
text = "$STR_AGM_Core_Alt";
action = "ACE_Core_keyNewTemp = [56, [false, false, false], 56];";
text = "$STR_ACE_Core_Alt";
idc = 23;
x = (3 / 4 * HSPACE2 + 7.5 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 10 * 0.04) * safezoneH + safezoneY;
};
class TextBox_Key_Shift_Right : TextBox_Key_Shift {
action = "AGM_Core_keyNewTemp = [54, [false, false, false], 54];";
text = "$STR_AGM_Core_Shift_Right";
action = "ACE_Core_keyNewTemp = [54, [false, false, false], 54];";
text = "$STR_ACE_Core_Shift_Right";
idc = 27;
x = (3 / 4 * HSPACE2 + 6 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 11 * 0.04) * safezoneH + safezoneY;
};
class TextBox_Key_Control_Right : TextBox_Key_Shift {
action = "AGM_Core_keyNewTemp = [157, [false, false, false], 157];";
text = "$STR_AGM_Core_Ctrl_Right";
action = "ACE_Core_keyNewTemp = [157, [false, false, false], 157];";
text = "$STR_ACE_Core_Ctrl_Right";
idc = 28;
x = (3 / 4 * HSPACE2 + 6.75 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 11 * 0.04) * safezoneH + safezoneY;
};
class TextBox_Key_Alt_Right : TextBox_Key_Shift {
action = "AGM_Core_keyNewTemp = [184, [false, false, false], 184];";
text = "$STR_AGM_Core_Alt_Right";
action = "ACE_Core_keyNewTemp = [184, [false, false, false], 184];";
text = "$STR_ACE_Core_Alt_Right";
idc = 29;
x = (3 / 4 * HSPACE2 + 7.5 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 11 * 0.04) * safezoneH + safezoneY;
@ -825,16 +825,16 @@ class AGM_Core_OptionsMenu_Dialog {
};
class TextBox_Key_Default : TextBox_Key_Shift {
action = "call AGM_Core_keysetDefault";
text = "$STR_AGM_Core_KeyDefault";
action = "call ACE_Core_keysetDefault";
text = "$STR_ACE_Core_KeyDefault";
idc = 31;
x = (3 / 4 * HSPACE2 + 8.25 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 10 * 0.04) * safezoneH + safezoneY;
};
class TextBox_Key_None : TextBox_Key_Shift {
action = "AGM_Core_keyNewTemp = [0, [false, false, false], 0];";
text = "$STR_AGM_Core_KeyNone";
action = "ACE_Core_keyNewTemp = [0, [false, false, false], 0];";
text = "$STR_ACE_Core_KeyNone";
idc = 32;
x = (3 / 4 * HSPACE2 + 8.25 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 11 * 0.04) * safezoneH + safezoneY;
@ -853,8 +853,8 @@ class AGM_Core_OptionsMenu_Dialog {
};
class Interactive_ButtonV : Interactive_Button0 {
action = "AGM_Core_keySet = 1";
text = "$STR_AGM_Core_Save";
action = "ACE_Core_keySet = 1";
text = "$STR_ACE_Core_Save";
sizeEx = "1 / 40 / (getResolution select 5)";// * safezoneX / safezoneXAbs";
idc = 25;
colorBackground[] = {0,0,0,0};
@ -865,8 +865,8 @@ class AGM_Core_OptionsMenu_Dialog {
};
class Interactive_ButtonW : Interactive_ButtonV {
action = "AGM_Core_keySet = -1";
text = "$STR_AGM_Core_Cancel";
action = "ACE_Core_keySet = -1";
text = "$STR_ACE_Core_Cancel";
idc = 26;
x = (HSPACE2 + 7.5 * 0.1) * safezoneW + safezoneX;
y = (VSPACE2 + 13 * 0.04) * safezoneH + safezoneY;
@ -875,8 +875,8 @@ class AGM_Core_OptionsMenu_Dialog {
};
class Interactive_ButtonX : Interactive_Button0 {
action = "AGM_Core_keySave = 1; closeDialog 0";
text = "$STR_AGM_Core_Save";
action = "ACE_Core_keySave = 1; closeDialog 0";
text = "$STR_ACE_Core_Save";
sizeEx = "1 / 40 / (getResolution select 5)";// * safezoneX / safezoneXAbs";
idc = 10;
x = ((1 - 2 * HSPACE2 / 2) - (HSPACE2 + 2.5 * 0.1)) * safezoneW + safezoneX;
@ -886,8 +886,8 @@ class AGM_Core_OptionsMenu_Dialog {
};
class Interactive_ButtonY : Interactive_Button0 {
action = "AGM_Core_keySave = -1; closeDialog 0";
text = "$STR_AGM_Core_Cancel";
action = "ACE_Core_keySave = -1; closeDialog 0";
text = "$STR_ACE_Core_Cancel";
sizeEx = "1 / 40 / (getResolution select 5)";// * safezoneX / safezoneXAbs";
idc = 11;
x = ((1 - 2 * HSPACE2 / 2) - (HSPACE2 + 1 * 0.1)) * safezoneW + safezoneX;
@ -896,9 +896,9 @@ class AGM_Core_OptionsMenu_Dialog {
h = 0.3 / 9 * safezoneH;
};
class Interactive_ButtonA : AGM_Core_Interactive_Button_Base {
action = "false call AGM_Core_nextKeys";
text = "$STR_AGM_Core_Prev";
class Interactive_ButtonA : ACE_Core_Interactive_Button_Base {
action = "false call ACE_Core_nextKeys";
text = "$STR_ACE_Core_Prev";
idc = 12;
style = 2 + 0x800;
x = (HSPACE2 + 3 * 0.1) * safezoneW + safezoneX;
@ -908,13 +908,13 @@ class AGM_Core_OptionsMenu_Dialog {
};
class Interactive_ButtonB : Interactive_ButtonA {
action = "true call AGM_Core_nextKeys";
text = "$STR_AGM_Core_Next";
action = "true call ACE_Core_nextKeys";
text = "$STR_ACE_Core_Next";
idc = 13;
x = (HSPACE2 + 3 * 0.1 + 2.0 / 16) * safezoneW + safezoneX;
};
class Interactive_ButtonC : AGM_Core_Text_Button_Base {
class Interactive_ButtonC : ACE_Core_Text_Button_Base {
text = "";
idc = 14;
style = 2 + 0x800;

View File

@ -2,7 +2,7 @@
class RadioProtocolBase {
class Words;
};
class AGM_RadioProtocolNoRadio: RadioProtocolBase {
class ACE_RadioProtocolNoRadio: RadioProtocolBase {
class CuratorWaypointPlaced;
class CuratorWaypointPlacedAttack;
class CuratorObjectPlaced;
@ -205,23 +205,23 @@ class AGM_RadioProtocolNoRadio: RadioProtocolBase {
};
class CfgVoice {
class AGM_NoVoice {
author = "$STR_AGM_Core_AGMTeam";
protocol = "AGM_RadioProtocolNoRadio";
class ACE_NoVoice {
author = "$STR_ACE_Core_ACETeam";
protocol = "ACE_RadioProtocolNoRadio";
variants[] = {1};
directories[] = {"",""};
identityTypes[] = {"Default"};
scope = 2;
voiceType = "";
icon = "\a3\Ui_f\data\Map\Markers\Flags\nato_ca.paa";
displayName = "$STR_AGM_Core_NoVoice";
displayName = "$STR_ACE_Core_NoVoice";
};
};
class CfgVoiceTypes {
class AGM_NoVoice {
name = "$STR_AGM_Core_NoVoice";
voices[] = {"AGM_NoVoice","AGM_NoVoice","AGM_NoVoice"};
preview = "AGM_NoVoice";
class ACE_NoVoice {
name = "$STR_ACE_Core_NoVoice";
voices[] = {"ACE_NoVoice","ACE_NoVoice","ACE_NoVoice"};
preview = "ACE_NoVoice";
alternative = "";
};
};

View File

@ -1,8 +1,8 @@
class AGM_Core_ProgressBar_Dialog {
class ACE_Core_ProgressBar_Dialog {
idd = -1;
movingEnable = false;
onLoad = "uiNamespace setVariable ['AGM_Core_ctrlProgressBar', (_this select 0) displayCtrl 1]; uiNamespace setVariable ['AGM_Core_ctrlProgressBarTitle', (_this select 0) displayCtrl 2];";
onLoad = "uiNamespace setVariable ['ACE_Core_ctrlProgressBar', (_this select 0) displayCtrl 1]; uiNamespace setVariable ['ACE_Core_ctrlProgressBarTitle', (_this select 0) displayCtrl 2];";
objects[] = {};
class controlsBackground {
@ -66,10 +66,10 @@ class AGM_Core_ProgressBar_Dialog {
};
};
class AGM_Core_DisableMouse_Dialog {
class ACE_Core_DisableMouse_Dialog {
idd = -1;
movingEnable = false;
onLoad = "uiNamespace setVariable ['AGM_Core_dlgDisableMouse', _this select 0];";
onLoad = "uiNamespace setVariable ['ACE_Core_dlgDisableMouse', _this select 0];";
objects[] = {};
class controlsBackground {
class Background {

View File

@ -2,26 +2,26 @@
class RscInGameUI {
class RscUnitInfo;
class RscUnitInfoSoldier: RscUnitInfo {
onLoad = "uiNamespace setVariable ['AGM_dlgSoldier', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoSoldier', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
onLoad = "uiNamespace setVariable ['ACE_dlgSoldier', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoSoldier', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
};
class RscUnitInfoTank: RscUnitInfo {
onLoad = "uiNamespace setVariable ['AGM_dlgVehicle', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoVehicle', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
onLoad = "uiNamespace setVariable ['ACE_dlgVehicle', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoVehicle', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
};
class RscUnitInfoAir: RscUnitInfo {
onLoad = "uiNamespace setVariable ['AGM_dlgAircraft', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoAircraft', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
onLoad = "uiNamespace setVariable ['ACE_dlgAircraft', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoAircraft', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
};
class RscUnitInfoShip: RscUnitInfo {
onLoad = "uiNamespace setVariable ['AGM_dlgShip', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoShip', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
onLoad = "uiNamespace setVariable ['ACE_dlgShip', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoShip', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
};
class RscUnitInfoParachute: RscUnitInfo {
onLoad = "uiNamespace setVariable ['AGM_dlgParachute', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoParachute', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
onLoad = "uiNamespace setVariable ['ACE_dlgParachute', _this select 0]; {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoParachute', [-1, [], []]]) select 2); {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInfoAny', [-1, [], []]]) select 2); [""onLoad"",_this,""RscUnitInfo"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""";
};
};
class RscDisplayInventory {
onLoad = "[""onLoad"",_this,""RscDisplayInventory"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""; {_this call _x} forEach ((missionNamespace getVariable ['AGM_onLoadInventory', [-1, [], []]]) select 2);";
onLoad = "[""onLoad"",_this,""RscDisplayInventory"",'IGUI'] call compile preprocessfilelinenumbers ""A3\ui_f\scripts\initDisplay.sqf""; {_this call _x} forEach ((missionNamespace getVariable ['ACE_onLoadInventory', [-1, [], []]]) select 2);";
};
class RscDisplayChannel {
onLoad = "_this call AGM_Core_fnc_onLoadRscDisplayChannel;";
onLoad = "_this call ACE_Core_fnc_onLoadRscDisplayChannel;";
};

View File

@ -1,5 +1,5 @@
// BWA3 Realism - Core
// (C) 2013 KoffeinFlummi. See LICENSE.
// ACE - Core
#include "script_component.hpp"
QGVAR(remoteFnc) addPublicVariableEventHandler {
(_this select 1) call FUNC(execRemoteFnc);
@ -8,13 +8,13 @@ QGVAR(remoteFnc) addPublicVariableEventHandler {
[missionNamespace] call FUNC(executePersistent);
// check previous version number from profile
_currentVersion = getText (configFile >> "CfgPatches" >> "AGM_Core" >> "version");
_previousVersion = profileNamespace getVariable ["AGM_VersionNumberString", ""];
_currentVersion = getText (configFile >> "CfgPatches" >> "ACE_Core" >> "version");
_previousVersion = profileNamespace getVariable ["ACE_VersionNumberString", ""];
if (_currentVersion != _previousVersion) then {
// do something
profileNamespace setVariable ["AGM_VersionNumberString", _currentVersion];
profileNamespace setVariable ["ACE_VersionNumberString", _currentVersion];
};
0 spawn compile preprocessFileLineNumbers PATHTOF(scripts\Version\checkVersionNumber.sqf);
@ -48,9 +48,9 @@ call compile preprocessFileLineNumbers PATHTOF(scripts\KeyInput\initScrollWheel.
0 spawn {
while {true} do {
waitUntil {!isNull (findDisplay 46)}; sleep 0.1;
findDisplay 46 displayAddEventHandler ["KeyDown", "_this call GVAR(onKeyDown)"];
findDisplay 46 displayAddEventHandler ["KeyUp", "_this call GVAR(onKeyUp)"];
findDisplay 46 displayAddEventHandler ["MouseZChanged", "_this call GVAR(onScrollWheel)"];
findDisplay 46 displayAddEventHandler ["KeyDown", QUOTE( _this call QUOTE(QGVAR(onKeyDown)) )];
findDisplay 46 displayAddEventHandler ["KeyUp", QUOTE( _this call QUOTE(QGVAR(onKeyUp)) )];
findDisplay 46 displayAddEventHandler ["MouseZChanged", QUOTE( _this call QUOTE(QGVAR(onScrollWheel)) )];
[false] call FUNC(disableUserInput);
waitUntil {isNull (findDisplay 46)};
};
@ -58,4 +58,12 @@ call compile preprocessFileLineNumbers PATHTOF(scripts\KeyInput\initScrollWheel.
enableCamShake true;
[missionNamespace, "playerChanged", "{if (alive (_this select 0)) then {[_this select 0] call FUNC(setName)}; if (alive (_this select 1)) then {[_this select 1] call FUNC(setName)};}"] call FUNC(addCustomEventhandler);
// Set the name for the current player
[missionNamespace, "playerChanged", {
if (alive (_this select 0)) then {
[_this select 0] call FUNC(setName)
};
if (alive (_this select 1)) then {
[_this select 1] call FUNC(setName)
};
}] call FUNC(addCustomEventhandler);

View File

@ -1,22 +1,153 @@
// by commy2
#include "script_component.hpp"
AGM_player = player;
// ACE Core Function
PREPF(addActionEventHandler);
PREPF(addActionMenuEventHandler);
PREPF(addCameraEventHandler);
PREPF(addCustomEventHandler);
PREPF(addInfoDisplayEventHandler);
PREPF(addMapMarkerCreatedEventHandler);
PREPF(addInventoryDisplayLoadedEventHandler);
PREPF(addScrollWheelEventHandler);
PREPF(adminKick);
PREPF(ambientBrightness);
PREPF(applyForceWalkStatus);
PREPF(binarizeNumber);
PREPF(callCustomEventHandlers);
PREPF(callCustomEventHandlersGlobal);
PREPF(canGetInPosition);
PREPF(canInteractWith);
PREPF(canUseWeapon);
PREPF(changeProjectileDirection);
PREPF(checkPBOs);
PREPF(claim);
PREPF(closeDialogIfTargetMoves);
PREPF(codeToLetter);
PREPF(codeToString);
PREPF(convertKeyCode);
PREPF(currentChannel);
PREPF(disableUserInput);
PREPF(displayText);
PREPF(displayTextPicture);
PREPF(displayTextStructured);
PREPF(doAnimation);
PREPF(endRadioTransmission);
PREPF(execPersistentFnc);
PREPF(execRemoteFnc);
PREPF(executePersistent);
PREPF(filter);
PREPF(fixLoweredRifleAnimation);
PREPF(getCaptivityStatus);
PREPF(getConfigCommander);
PREPF(getConfigGunner);
PREPF(getDefaultAnim);
PREPF(getDoorTurrets);
PREPF(getForceWalkStatus);
PREPF(getHitPoints);
PREPF(getHitPointsWithSelections);
PREPF(getInPosition);
PREPF(getMarkerType);
PREPF(getName);
PREPF(getNumberFromMissionSQM);
PREPF(getPitchBankYaw);
PREPF(getStringFromMissionSQM);
PREPF(getTargetAzimuthAndInclination);
PREPF(getTargetDistance);
PREPF(getTargetObject);
PREPF(getTurretCommander);
PREPF(getTurretConfigPath);
PREPF(getTurretCopilot);
PREPF(getTurretGunner);
PREPF(getTurretIndex);
PREPF(getTurrets);
PREPF(getTurretsFFV);
PREPF(getTurretsOther);
PREPF(getUavControlPosition);
PREPF(getVehicleCargo);
PREPF(getVehicleCodriver);
PREPF(getVehicleCrew);
PREPF(getWeaponAzimuthAndInclination);
PREPF(getWeaponType);
PREPF(getWindDirection);
PREPF(goKneeling);
PREPF(hadamardProduct);
PREPF(interpolateFromArray);
PREPF(inTransitionAnim);
PREPF(isAutoWind);
PREPF(isEngineer);
PREPF(isEOD);
PREPF(isInBuilding);
PREPF(isMedic);
PREPF(isPlayer);
PREPF(isTurnedOut);
PREPF(letterToCode);
PREPF(map);
PREPF(moduleCheckPBOs);
PREPF(moduleLSDVehicles);
PREPF(muteUnit);
PREPF(numberToDigits);
PREPF(numberToDigitsString);
PREPF(onLoadRscDisplayChannel);
PREPF(owned);
PREPF(player);
PREPF(playerSide);
PREPF(progressBar);
PREPF(queueAnimation);
PREPF(readBooleanParameterFromModule);
PREPF(readNumericParameterFromModule);
PREPF(removeActionEventHandler);
PREPF(removeActionMenuEventHandler);
PREPF(removeCameraEventHandler);
PREPF(removeCustomEventHandler);
PREPF(removeInfoDisplayEventHandler);
PREPF(removeInventoryDisplayLoadedEventHandler);
PREPF(removeMapMarkerCreatedEventHandler);
PREPF(removeScrollWheelEventHandler);
PREPF(restoreVariablesJIP);
PREPF(revertKeyCodeLocalized);
PREPF(sanitizeString);
PREPF(serverLog);
PREPF(setCaptivityStatus);
PREPF(setForceWalkStatus);
PREPF(setKeyDefault);
PREPF(setName);
PREPF(setParameter);
PREPF(setPitchBankYaw);
PREPF(setVariableJIP);
PREPF(stringToColoredText);
PREPF(subString);
PREPF(toBin);
PREPF(toBitmask);
PREPF(toHex);
PREPF(toNumber);
PREPF(unmuteUnit);
// ACE_Debug
PREPF(exportConfig);
PREPF(getChildren);
PREPF(getDisplayConfigName);
PREPF(log);
PREPF(logControls);
PREPF(logDisplays);
PREPF(monitor);
PREPF(showUser);
// ACE_CuratorFix
PREPF(addUnloadEventhandler);
PREPF(fixCrateContent);
// Loop to update the ACE_player variable
ACE_player = player;
if (hasInterface) then {
["AGM_CheckForPlayerChange", "onEachFrame", {
if !(AGM_player isEqualTo (missionNamespace getVariable ["BIS_fnc_moduleRemoteControl_unit", player])) then {
//if (AGM_player != missionNamespace getVariable ["BIS_fnc_moduleRemoteControl_unit", player]) then {
_this = AGM_player;
["ACE_CheckForPlayerChange", "onEachFrame", {
if !(ACE_player isEqualTo (missionNamespace getVariable ["BIS_fnc_moduleRemoteControl_unit", player])) then {
_this = ACE_player;
AGM_player = missionNamespace getVariable ["BIS_fnc_moduleRemoteControl_unit", player];
uiNamespace setVariable ["AGM_player", AGM_player];
ACE_player = missionNamespace getVariable ["BIS_fnc_moduleRemoteControl_unit", player];
uiNamespace setVariable ["ACE_player", ACE_player];
[missionNamespace, "playerChanged", [AGM_player, _this]] call FUNC(callCustomEventHandlers);
[missionNamespace, "playerChanged", [ACE_player, _this]] call FUNC(callCustomEventHandlers);
};
}] call BIS_fnc_addStackedEventHandler;
};
// remove this for the release
/*if (isNil "AGM_Debug") then {
AGM_Debug = ["remote"];
};*/

View File

@ -2,8 +2,8 @@
class CfgPatches {
class ADDON {
units[] = {"AGM_Box_Misc"};
weapons[] = {"AGM_ItemCore", "AGM_FakePrimaryWeapon"};
units[] = {"ACE_Box_Misc"};
weapons[] = {"ACE_ItemCore", "ACE_FakePrimaryWeapon"};
requiredVersion = 0.60;
requiredAddons[] = {
"ace_main"
@ -17,7 +17,6 @@ class CfgPatches {
};
#include "CfgEventHandlers.hpp"
#include "CfgFunctions.hpp"
#include "CfgSounds.hpp"
#include "CfgVehicles.hpp"
#include "CfgWeapons.hpp"
@ -30,7 +29,7 @@ class CfgFactionClasses {
};
};
class AGM_Rsc_Display_Base {
class ACE_Rsc_Display_Base {
idd = -1;
type = 0;
style = 48;
@ -44,7 +43,7 @@ class AGM_Rsc_Display_Base {
colorText[] = {1, 1, 1, 1};
};
class AGM_Rsc_Control_Base {
class ACE_Rsc_Control_Base {
idc = 1;
type = 0;
style = 48;
@ -71,7 +70,7 @@ class GVAR(canInteractConditions) {
class GVAR(Options) {
class enableNumberHotkeys {
displayName = "$STR_AGM_Core_EnableNumberHotkeys";
displayName = "$STR_ACE_Core_EnableNumberHotkeys";
default = 1;
};
};
@ -82,9 +81,9 @@ class GVAR(Options) {
#include <HintConfig.hpp>
/*
class RscControlsGroupNoScrollbars;
class RscControlsGroupNoScrollbars;
class RscAttributeInventory: RscControlsGroupNoScrollbars {
onSetFocus = "[_this,""RscAttributeInventory"",'CuratorCommon'] call (uinamespace getvariable ""BIS_fnc_initCuratorAttribute""); _this select 0 call AGM_CuratorFix_fnc_addUnloadEventhandler;";
onSetFocus = "[_this,""RscAttributeInventory"",'CuratorCommon'] call (uinamespace getvariable ""BIS_fnc_initCuratorAttribute""); _this select 0 call ACE_CuratorFix_fnc_addUnloadEventhandler;";
};
*/

View File

@ -0,0 +1,7 @@
// by commy2
private "_name";
_name = name (_this select 0);
[_name, "{if (serverCommandAvailable '#kick') then {serverCommand format['#kick %1', _this]}}"] call FUNC(execRemoteFnc);

View File

@ -12,6 +12,7 @@
* Return value:
* ID of the action (used to remove it later).
*/
#include "script_component.hpp"
private ["_unit", "_action", "_condition", "_statement", "_name", "_actionsVar", "_actionID", "_actions", "_id", "_actionIDs"];
@ -28,7 +29,7 @@ if (typeName _statement == "STRING") then {
_statement = compile _statement;
};
_name = format ["AGM_Action_%1", _action];
_name = format ["ACE_Action_%1", _action];
_actionsVar = _unit getVariable [_name, [-1, [-1, [], []]]];
@ -55,7 +56,7 @@ if (_actionID == -1) then {
false,
true,
'%1',
""if (_this != AGM_player || {vehicle _this != _target}) exitWith {false}; _actions = (_this getVariable '%2') select 1 select 2; _count = count _actions; _index = 0; _return = false; while {_index < _count && {!_return}} do {_return = [_target, _this] call ((_actions select _index) select 0); _index = _index + 1}; _return""
""if (_this != ACE_player || {vehicle _this != _target}) exitWith {false}; _actions = (_this getVariable '%2') select 1 select 2; _count = count _actions; _index = 0; _return = false; while {_index < _count && {!_return}} do {_return = [_target, _this] call ((_actions select _index) select 0); _index = _index + 1}; _return""
]",
_action,
_name

View File

@ -16,6 +16,7 @@
* Return value:
* ID of the action (used to remove it later).
*/
#include "script_component.hpp"
private ["_unit", "_displayName", "_action", "_condition", "_statement", "_condition2", "_statement2", "_priority", "_name", "_actionsVar", "_id", "_actionIDs", "_actions", "_nameVar", "_addAction", "_actionID"];
@ -46,7 +47,7 @@ if (typeName _statement2 == "STRING") then {
_statement2 = compile _statement2;
};
_name = format ["AGM_ActionMenu_%1", _action];
_name = format ["ACE_ActionMenu_%1", _action];
_actionsVar = _unit getVariable [_name, [-1, [], []]];
@ -68,7 +69,7 @@ _addAction = call compile format [
false,
true,
'%1',
""if (_this != AGM_player || {vehicle _this != _target}) exitWith {false}; [_target, _this] call (%3 select 0)""
""if (_this != ACE_player || {vehicle _this != _target}) exitWith {false}; [_target, _this] call (%3 select 0)""
]",
_action,
_displayName,

View File

@ -10,6 +10,7 @@
* Return value:
* ID of the event script (used to remove it later).
*/
#include "script_component.hpp"
private ["_statement", "_actionsVar", "_id", "_actionIDs", "_actions"];
@ -19,20 +20,20 @@ if (typeName _statement == "STRING") then {
_statement = compile _statement;
};
_actionsVar = missionNamespace getVariable ["AGM_EventHandler_CameraMode", [-1, [], []]];
_actionsVar = missionNamespace getVariable ["ACE_EventHandler_CameraMode", [-1, [], []]];
_id = (_actionsVar select 0) + 1;
_actionIDs = _actionsVar select 1;
_actions = _actionsVar select 2;
if (_id == 0) then {
uiNamespace setVariable ["AGM_EventHandler_CameraMode", cameraView];
("AGM_EventHandlerHelper" call BIS_fnc_rscLayer) cutRsc ["AGM_EventHandlerHelper", "PLAIN"];
uiNamespace setVariable ["ACE_EventHandler_CameraMode", cameraView];
(QGVAR(EventHandlerHelper) call BIS_fnc_rscLayer) cutRsc [QGVAR(EventHandlerHelper), "PLAIN"];
};
_actionIDs pushBack _id;
_actions pushBack _statement;
missionNamespace setVariable ["AGM_EventHandler_CameraMode", [_id, _actionIDs, _actions]];
missionNamespace setVariable ["ACE_EventHandler_CameraMode", [_id, _actionIDs, _actions]];
_id

View File

@ -11,6 +11,7 @@
* Return value:
* ID of the event script (used to remove it later).
*/
#include "script_component.hpp"
private ["_object", "_type", "_statement", "_name", "_actionsVar", "_id", "_actionIDs", "_actions"];
@ -22,7 +23,7 @@ if (typeName _statement == "STRING") then {
_statement = compile _statement;
};
_name = format ["AGM_CustomEventHandlers_%1", _type];
_name = format ["ACE_CustomEventHandlers_%1", _type];
_actionsVar = _object getVariable [_name, [-1, [], []]];

View File

@ -10,10 +10,11 @@
* Return value:
* ID of the event script (used to remove it later).
*/
#include "script_component.hpp"
private ["_type", "_statement", "_actionsVar", "_id", "_actionIDs", "_actions"];
_type = format ["AGM_onLoadInfo%1", _this select 0];
_type = format ["ACE_onLoadInfo%1", _this select 0];
_statement = _this select 1;
if (typeName _statement == "STRING") then {

View File

@ -9,6 +9,7 @@
* Return value:
* ID of the event script (used to remove it later).
*/
#include "script_component.hpp"
private ["_statement", "_actionsVar", "_id", "_actionIDs", "_actions"];
@ -18,7 +19,7 @@ if (typeName _statement == "STRING") then {
_statement = compile _statement;
};
_actionsVar = missionNamespace getVariable ["AGM_onLoadInventory", [-1, [], []]];
_actionsVar = missionNamespace getVariable ["ACE_onLoadInventory", [-1, [], []]];
_id = (_actionsVar select 0) + 1;
_actionIDs = _actionsVar select 1;
@ -27,6 +28,6 @@ _actions = _actionsVar select 2;
_actionIDs pushBack _id;
_actions pushBack _statement;
missionNamespace setVariable ["AGM_onLoadInventory", [_id, _actionIDs, _actions]];
missionNamespace setVariable ["ACE_onLoadInventory", [_id, _actionIDs, _actions]];
_id

View File

@ -9,6 +9,7 @@
* Return value:
* ID of the event script (used to remove it later).
*/
#include "script_component.hpp"
private ["_statement", "_actionsVar", "_id", "_actionIDs", "_actions"];
@ -18,20 +19,20 @@ if (typeName _statement == "STRING") then {
_statement = compile _statement;
};
_actionsVar = missionNamespace getVariable ["AGM_EventHandler_MapMarker", [-1, [], []]];
_actionsVar = missionNamespace getVariable ["ACE_EventHandler_MapMarker", [-1, [], []]];
_id = (_actionsVar select 0) + 1;
_actionIDs = _actionsVar select 1;
_actions = _actionsVar select 2;
if (_id == 0) then {
uiNamespace setVariable ["AGM_EventHandler_MapMarker", count allMapMarkers];
("AGM_EventHandlerHelper2" call BIS_fnc_rscLayer) cutRsc ["AGM_EventHandlerHelper2", "PLAIN"];
uiNamespace setVariable ["ACE_EventHandler_MapMarker", count allMapMarkers];
("ACE_EventHandlerHelper2" call BIS_fnc_rscLayer) cutRsc ["ACE_EventHandlerHelper2", "PLAIN"];
};
_actionIDs pushBack _id;
_actions pushBack _statement;
missionNamespace setVariable ["AGM_EventHandler_MapMarker", [_id, _actionIDs, _actions]];
missionNamespace setVariable ["ACE_EventHandler_MapMarker", [_id, _actionIDs, _actions]];
_id

View File

@ -9,6 +9,7 @@
* Return value:
* ID of the event script (used to remove it later).
*/
#include "script_component.hpp"
private ["_statement", "_actionsVar", "_id", "_actionIDs", "_actions"];
@ -18,7 +19,7 @@ if (typeName _statement == "STRING") then {
_statement = compile _statement;
};
_actionsVar = missionNamespace getVariable ["AGM_EventHandler_ScrollWheel", [-1, [], []]];
_actionsVar = missionNamespace getVariable ["ACE_EventHandler_ScrollWheel", [-1, [], []]];
_id = (_actionsVar select 0) + 1;
_actionIDs = _actionsVar select 1;
@ -27,6 +28,6 @@ _actions = _actionsVar select 2;
_actionIDs pushBack _id;
_actions pushBack _statement;
missionNamespace setVariable ["AGM_EventHandler_ScrollWheel", [_id, _actionIDs, _actions]];
missionNamespace setVariable ["ACE_EventHandler_ScrollWheel", [_id, _actionIDs, _actions]];
_id

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private "_dlg";
@ -7,6 +8,6 @@ _dlg = ctrlParent _this;
_dlg displayAddEventHandler ["unload", {
if (_this select 1 == 1) then {
[missionnamespace getvariable ["BIS_fnc_initCuratorAttributes_target", objNull]] call AGM_CuratorFix_fnc_fixCrateContent;
[missionnamespace getvariable ["BIS_fnc_initCuratorAttributes_target", objNull]] call FUNC(fixCrateContent);
};
}];

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private "_name";

View File

@ -9,5 +9,6 @@
* Return value:
* Ambient brightness (Number)
*/
#include "script_component.hpp"
sunOrMoon * sunOrMoon + moonIntensity/5 min 1

View File

@ -13,12 +13,13 @@ Returns:
None
Example:
[AGM_Player] call FUNC(applyForceWalkStatus)
[ACE_Player] call FUNC(applyForceWalkStatus)
*/
#include "script_component.hpp"
private ["_unit", "_forceWalkNumber"];
_unit = _this select 0;
_forceWalkNumber = _unit getVariable ["AGM_forceWalkStatusNumber", 0];
_forceWalkNumber = _unit getVariable ["ACE_forceWalkStatusNumber", 0];
_unit forceWalk (_forceWalkNumber > 0);

View File

@ -10,6 +10,7 @@
* Return value:
* Booleans (Array)
*/
#include "script_component.hpp"
private ["_number", "_minLength", "_array", "_index", "_rest"];

View File

@ -11,6 +11,7 @@
* Return value:
* None.
*/
#include "script_component.hpp"
private ["_object", "_type", "_argument", "_name", "_actions"];
@ -20,7 +21,7 @@ _argument = _this select 2;
if (isNil "_argument") then {_argument = [_object]};
_name = format ["AGM_CustomEventHandlers_%1", _type];
_name = format ["ACE_CustomEventHandlers_%1", _type];
_actions = (_object getVariable [_name, [-1, [], []]]) select 2;

View File

@ -11,5 +11,6 @@
* Return value:
* None.
*/
#include "script_component.hpp"
[_this, QUOTE(FUNC(callCustomEventHandlers)), 2] call FUNC(execRemoteFnc);

View File

@ -14,6 +14,7 @@
* Return Value:
* Nothing
*/
#include "script_component.hpp"
#define CANGETINDRIVER (isNull (driver _vehicle) || {!alive driver _vehicle}) && {!lockedDriver _vehicle} && {getNumber (_config >> "isUav") != 1}
#define CANGETINTURRETINDEX (isNull (_vehicle turretUnit _turret) || {!alive (_vehicle turretUnit _turret)}) && {!(_vehicle lockedTurret _turret)} && {getNumber (_config >> "isUav") != 1}

View File

@ -1,10 +1,11 @@
// by commy2
#include "script_component.hpp"
private ["_unit", "_target", "_owner"];
_unit = _this select 0;
_target = _this select 1;
_owner = _target getVariable ["AGM_isUsedBy", objNull];
_owner = _target getVariable ["ACE_isUsedBy", objNull];
isNull _owner || {_unit == _owner} || {!isPlayer _owner}

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
// returns true if the unit is on foot or in a ffv position

View File

@ -12,6 +12,7 @@
* Return value:
* None.
*/
#include "script_component.hpp"
private ["_projectile", "_adjustDir", "_adjustUp", "_adjustSpeed", "_vdir", "_dir", "_up", "_l", "_r", "_vup", "_vel"];
@ -24,7 +25,7 @@ if (isNil "_adjustSpeed") then {
_adjustSpeed = 0;
};
["CPD", [_fnc_scriptNameParent, _adjustDir, _adjustUp, _adjustSpeed], nil, false] call AGM_Debug_fnc_log;
["CPD", [_fnc_scriptNameParent, _adjustDir, _adjustUp, _adjustSpeed], nil, false] call FUNC(log);
// get old direction vector
_vdir = vectorDir _projectile;
@ -41,7 +42,7 @@ _vdir = [
];
// get best up vector
_l = sqrt ((_vdir select 0) ^ 2 + (_vdir select 1) ^ 2); if (_l == 0) then {diag_log text format ["[AGM] ERROR: %1, %2, %3, %4, %5, %6, %7", _projectile, _adjustDir, _adjustUp, vectorDir _projectile, _vdir, _dir, _up]};
_l = sqrt ((_vdir select 0) ^ 2 + (_vdir select 1) ^ 2); if (_l == 0) then {diag_log text format ["[ACE] ERROR: %1, %2, %3, %4, %5, %6, %7", _projectile, _adjustDir, _adjustUp, vectorDir _projectile, _vdir, _dir, _up]};
_r = -(_vdir select 2) / _l;
_vup = [

View File

@ -14,6 +14,7 @@
* Return value:
* None.
*/
#include "script_component.hpp"
private ["_mode", "_checkAll", "_whitelist", "_logic"];

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private ["_unit", "_target", "_lockTarget", "_owner"];
@ -8,20 +9,20 @@ _lockTarget = _this select 2;
if (isNil "_lockTarget") then {_lockTarget = false};
_owner = _target getVariable ["AGM_isUsedBy", objNull];
_owner = _target getVariable ["ACE_isUsedBy", objNull];
if (!isNull _owner && {!isNull _unit} && {_unit != _owner}) then {
diag_log text "[AGM] ERROR: Claiming already owned object.";
diag_log text "[ACE] ERROR: Claiming already owned object.";
};
_target setVariable ["AGM_isUsedBy", _unit, true];
_target setVariable ["ACE_isUsedBy", _unit, true];
if (_lockTarget) then {
if (!isNull _unit) then {
[_target, "{_locked = locked _this; _this setVariable ['AGM_lockStatus', _locked]; _this lock 2}", _target] call FUNC(execRemoteFnc);
[_target, "{_locked = locked _this; _this setVariable ['ACE_lockStatus', _locked]; _this lock 2}", _target] call FUNC(execRemoteFnc);
} else {
[_target, "{_this lock (_this getVariable ['AGM_lockStatus', locked _this])}", _target] call FUNC(execRemoteFnc);
[_target, "{_this lock (_this getVariable ['ACE_lockStatus', locked _this])}", _target] call FUNC(execRemoteFnc);
};
};
//systemChat str locked _target; systemChat str (_target getVariable ['AGM_lockStatus', locked _target]);
//systemChat str locked _target; systemChat str (_target getVariable ['ACE_lockStatus', locked _target]);

View File

@ -10,6 +10,7 @@
* Return Value:
* None
*/
#include "script_component.hpp"
_this spawn {
_target = _this select 0;
@ -17,21 +18,21 @@ _this spawn {
if (isNil "_ignoreDead") then {_ignoreDead = false};
_vehicleTarget = vehicle _target;
_vehiclePlayer = vehicle AGM_player;
_vehiclePlayer = vehicle ACE_player;
_inVehicle = _target != _vehicleTarget;
_position = getPosASL _target;
_fnc_check = {
// either unit changed vehicles
if (_vehiclePlayer != vehicle AGM_player) exitWith {True};
if (_vehiclePlayer != vehicle ACE_player) exitWith {True};
if (_vehicleTarget != vehicle _target) exitWith {True};
// target died
if (!alive _target && {!_ignoreDead}) exitWith {True};
// player fell unconscious
if (AGM_player getVariable ["AGM_isUnconscious", False]) exitWith {True};
if (ACE_player getVariable ["ACE_isUnconscious", False]) exitWith {True};
// target moved (outside of vehicle)
(!_inVehicle && {getPosASL _target distanceSqr _position > 1})
@ -40,8 +41,8 @@ _this spawn {
waitUntil {
if (call _fnc_check) then {
closeDialog 0;
call AGM_Interaction_fnc_hideMenu;
call ACE_Interaction_fnc_hideMenu;
};
(isNil "AGM_Interaction_MainButton" && !dialog) || {!isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull])} //Exit loop if DisableMouse dialog open
(isNil "ACE_Interaction_MainButton" && !dialog) || {!isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull])} //Exit loop if DisableMouse dialog open
};
};

View File

@ -1,3 +1,4 @@
// by commy2
#include "script_component.hpp"
["", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z"] select ([2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 30, 48, 46, 32, 18, 33, 34, 35, 23, 36, 37, 38, 50, 49, 24, 25, 16, 19, 31, 20, 22, 47, 17, 45, 44, 21] find (_this select 0)) + 1

View File

@ -2,13 +2,14 @@
* Author: commy2
*
* Removes the brackets around a code and returns the code as a string. It does nothing if the code is already a string.
*
*
* Argument:
* 0: Code (Code or String)
*
*
* Return value:
* Code (String)
*/
#include "script_component.hpp"
private "_function";

View File

@ -1,17 +1,18 @@
/*
* Author: commy2
*
* Get a key code used in AGM key input eh.
*
* Get a key code used in ACE key input eh.
*
* Argument:
* 0: Arma DIK code (Number)
* 1: Key state for shift left and shift right key (Bool)
* 2: Key state for ctrl left and ctrl right key (Bool)
* 3: Key state for alt and alt gr key (Bool)
*
*
* Return value:
* Key code (Number)
*/
#include "script_component.hpp"
#define KEY_MODIFIERS [42, 54, 29, 157, 56, 184]

View File

@ -2,15 +2,16 @@
* Author: commy2
*
* Returns the current radio / chat / marker channel.
*
*
* Argument:
* NONE.
*
*
* Return value:
* The current channel. Can be "group", "side", "global", "command", "vehicle" or "direct" (String)
*/
#include "script_component.hpp"
#define CHANNELS ["group", "side", "global", "command", "vehicle", "direct"]
#define CHANNELS_LOCALIZED [localize "str_channel_group", localize "str_channel_side", localize "str_channel_global", localize "str_channel_command", localize "str_channel_vehicle", localize "str_channel_direct"]
CHANNELS select (CHANNELS_LOCALIZED find (uiNamespace getVariable ["AGM_currentChannel", ""])) max 0
CHANNELS select (CHANNELS_LOCALIZED find (uiNamespace getVariable ["ACE_currentChannel", ""])) max 0

View File

@ -9,6 +9,7 @@
* Return value:
* Nothing
*/
#include "script_component.hpp"
private ["_state", "_dlg"];
@ -18,13 +19,13 @@ if (_state) then {
disableSerialization;
if (!isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull])) exitWith {};
if ("AGM_DisableUserInput" in ([BIS_stackedEventHandlers_onEachFrame, {_this select 0}] call FUNC(map))) exitWith {};
if ("ACE_DisableUserInput" in ([BIS_stackedEventHandlers_onEachFrame, {_this select 0}] call FUNC(map))) exitWith {};
// end TFAR and ACRE2 radio transmissions
0 spawn FUNC(endRadioTransmission);
// Close map
if (visibleMap && {!(player getVariable ["AGM_canSwitchUnits", false])}) then {openMap false};
if (visibleMap && {!(player getVariable ["ACE_canSwitchUnits", false])}) then {openMap false};
closeDialog 0;
createDialog QGVAR(DisableMouse_Dialog);
@ -63,9 +64,9 @@ if (_state) then {
if (_key in actionKeys "TeamSwitch" && {teamSwitchEnabled}) then {(uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; teamSwitch};//_acc = accTime; teamSwitch; setAccTime _acc};
if (_key in actionKeys "CuratorInterface" && {getAssignedCuratorLogic player in allCurators}) then {(uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; openCuratorInterface};
if (_key in actionKeys "ShowMap" && {player getVariable ["AGM_canSwitchUnits", false]}) then {(uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; openMap true};
if (_key in actionKeys "ShowMap" && {player getVariable ["ACE_canSwitchUnits", false]}) then {(uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; openMap true};
if (serverCommandAvailable "#missions" || {player getVariable ["AGM_isUnconscious", false] && {(call FUNC(player)) getVariable ["AGM_Medical_AllowChatWhileUnconscious", missionNamespace getVariable ["AGM_Medical_AllowChatWhileUnconscious", false]]}}) then {
if (serverCommandAvailable "#missions" || {player getVariable ["ACE_isUnconscious", false] && {(call FUNC(player)) getVariable [QEGVAR(medical,AllowChatWhileUnconscious), missionNamespace getVariable [QEGVAR(medical,AllowChatWhileUnconscious), false]]}}) then {
if (!(_key in (actionKeys "DefaultAction" + actionKeys "Throw")) && {_key in (actionKeys "Chat" + actionKeys "PrevChannel" + actionKeys "NextChannel")}) then {
_key = 0;
};
@ -75,15 +76,15 @@ if (_state) then {
}];
_dlg displayAddEventHandler ["KeyUp", {true}];
["AGM_DisableUserInput", "onEachFrame", {
["ACE_DisableUserInput", "onEachFrame", {
if (isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) && {!visibleMap && isNull findDisplay 49 && isNull findDisplay 312 && isNull findDisplay 632}) then {
["AGM_DisableUserInput", "onEachFrame"] call BIS_fnc_removeStackedEventHandler;
["ACE_DisableUserInput", "onEachFrame"] call BIS_fnc_removeStackedEventHandler;
[true] call FUNC(disableUserInput);
};
}] call BIS_fnc_addStackedEventHandler;
} else {
if ("AGM_DisableUserInput" in ([BIS_stackedEventHandlers_onEachFrame, {_this select 0}] call FUNC(map))) then {
["AGM_DisableUserInput", "onEachFrame"] call BIS_fnc_removeStackedEventHandler;
if ("ACE_DisableUserInput" in ([BIS_stackedEventHandlers_onEachFrame, {_this select 0}] call FUNC(map))) then {
["ACE_DisableUserInput", "onEachFrame"] call BIS_fnc_removeStackedEventHandler;
};
(uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0;

View File

@ -12,6 +12,7 @@
* Return value:
* Nothing
*/
#include "script_component.hpp"
#define DEFAULT_PLAY_SOUND false
#define DEFAULT_DELAY 2
@ -42,7 +43,7 @@ _this spawn {
_time = time;
if (_time > _lastHintTime + _delay || {_priority >= _lastHintPriority}) then {
hintSilent _text;
if (_sound) then {playSound "AGM_Sound_Click"};
if (_sound) then {playSound "ACE_Sound_Click"};
GVAR(lastHint) set [0, _time];
GVAR(lastHint) set [1, _priority];

View File

@ -10,6 +10,7 @@
* Return value:
* Nothing
*/
#include "script_component.hpp"
private ["_text", "_image"];

View File

@ -10,6 +10,7 @@
* Return value:
* Nothing
*/
#include "script_component.hpp"
private ["_text", "_size", "_isShown", "_ctrlHint"];
@ -22,12 +23,12 @@ if (typeName _text != "TEXT") then {
_text = composeText [lineBreak, parseText format ["<t align='center'>%1</t>", _text]];
};
_isShown = ctrlShown (uiNamespace getVariable ["AGM_ctrlHint", controlNull]);
_isShown = ctrlShown (uiNamespace getVariable ["ACE_ctrlHint", controlNull]);
("AGM_RscHint" call BIS_fnc_rscLayer) cutRsc ["AGM_RscHint", "PLAIN", 0, true];
("ACE_RscHint" call BIS_fnc_rscLayer) cutRsc ["ACE_RscHint", "PLAIN", 0, true];
disableSerialization;
_ctrlHint = uiNamespace getVariable "AGM_ctrlHint";
_ctrlHint = uiNamespace getVariable "ACE_ctrlHint";
_ctrlHint ctrlSetPosition [
safeZoneW + safeZoneX - 0 * safezoneW,

View File

@ -14,6 +14,7 @@
* Return value:
* Nothing
*/
#include "script_component.hpp"
private ["_unit", "_animation", "_priority", "_force"];
@ -24,7 +25,7 @@ _force = False;
// no animation given
if (isNil "_animation") exitWith {
diag_log format ["[AGM] ERROR: No animation specified in %1", _fnc_scriptNameParent];
diag_log format ["[ACE] ERROR: No animation specified in %1", _fnc_scriptNameParent];
};
if (isNil "_priority") then {
@ -35,14 +36,14 @@ if (count _this > 3) then {
};
// don't overwrite more important animations
if (_unit getVariable ["AGM_isUnconscious", false] && {!_force}) exitWith {
if (_unit getVariable ["ACE_isUnconscious", false] && {!_force}) exitWith {
if (_animation != "Unconscious") then {
[_unit, "Unconscious", 2] call FUNC(doAnimation);
};
};
// don't go unconscious if the unit isn't unconscious
if (_animation == "Unconscious" && {!(_unit getVariable ["AGM_isUnconscious", false])}) exitWith {};
if (_animation == "Unconscious" && {!(_unit getVariable ["ACE_isUnconscious", false])}) exitWith {};
// switchMove "" no longer works in dev 1.37
if (_animation == "") then {
@ -73,4 +74,4 @@ switch (_priority) do {
default {};
};
["Anim", [_priority, _animation]] call AGM_Debug_fnc_log;
["Anim", [_priority, _animation]] call FUNC(log);

View File

@ -10,6 +10,7 @@
* None.
*
*/
#include "script_component.hpp"
// ACRE
if (isClass (configFile >> "CfgPatches" >> "acre_main")) then {

View File

@ -12,6 +12,7 @@
* Return value:
* Nothing.
*/
#include "script_component.hpp"
private ["_arguments", "_function", "_unit", "_name"];
@ -22,7 +23,7 @@ _function = call compile (_this select 1);
_unit = _this select 2;
_name = _this select 3;
["Remote", [_arguments, _this select 1, _name], {format ["%1 call %2 id: %3", _this select 0, _this select 1, _this select 2]}, false] call AGM_Debug_fnc_log;
["Remote", [_arguments, _this select 1, _name], {format ["%1 call %2 id: %3", _this select 0, _this select 1, _this select 2]}, false] call FUNC(log);
// execute function on every currently connected machine
[[_arguments, _unit], _this select 1, 2] call FUNC(execRemoteFnc);
@ -30,7 +31,7 @@ _name = _this select 3;
// save persistent function for JIP
private ["_persistentFunctions", "_index"];
_persistentFunctions = _unit getVariable ["AGM_PersistentFunctions", []];
_persistentFunctions = _unit getVariable ["ACE_PersistentFunctions", []];
// find index to overwrite function with the same name, add to end otherwise
_index = count _persistentFunctions;
@ -45,8 +46,8 @@ _persistentFunctions set [_index, [_arguments, _function, _name]];
// broadcast variable
if (typeName _unit == "NAMESPACE") then {
AGM_PersistentFunctions = _persistentFunctions;
publicVariable "AGM_PersistentFunctions";
ACE_PersistentFunctions = _persistentFunctions;
publicVariable "ACE_PersistentFunctions";
} else {
_unit setVariable ["AGM_PersistentFunctions", _persistentFunctions, true];
_unit setVariable ["ACE_PersistentFunctions", _persistentFunctions, true];
};

View File

@ -15,6 +15,7 @@
* Return value:
* Nothing
*/
#include "script_component.hpp"
private ["_arguments", "_function", "_unit", "_id"];
@ -28,7 +29,7 @@ if (isNil "_unit") then {
_unit = 2;
};
["Remote", [_arguments, _this select 1, _unit], {format ["%1 call %2 to: %3", _this select 0, _this select 1, _this select 2]}, false] call AGM_Debug_fnc_log;
["Remote", [_arguments, _this select 1, _unit], {format ["%1 call %2 to: %3", _this select 0, _this select 1, _this select 2]}, false] call FUNC(log);
if (typeName _unit == "SCALAR") exitWith {
switch (_unit) do {

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private "_target";
@ -6,10 +7,10 @@ _target = _this select 0;
{
if (isNil "_x") then {
diag_log text format ["[AGM] ERROR: No argument and function for remote function. ID: %1", _forEachIndex];
diag_log text format ["[ACE] ERROR: No argument and function for remote function. ID: %1", _forEachIndex];
} else {
if (typeName _x == "ARRAY") then {
[_x select 0, _target] call (_x select 1);
};
};
} forEach (_target getVariable ["AGM_PersistentFunctions", []]);
} forEach (_target getVariable ["ACE_PersistentFunctions", []]);

View File

@ -1,10 +1,10 @@
// by commy2
/*
usage:
(configFile >> "CfgAmmo") call AGM_Debug_fnc_exportConfig;
(configFile >> "CfgAmmo") call FUNC(exportConfig);
*/
#include "script_component.hpp"
private "_fnc_logEntries";

View File

@ -13,6 +13,7 @@
* Usage:
* [[0,1,2,3,4], {_this > 2}] call FUNC(filter) ==> [3,4]
*/
#include "script_component.hpp"
private ["_array", "_code", "_newArray", "_index"];
@ -20,7 +21,7 @@ _array = _this select 0;
_code = _this select 1;
if (isNil "_array") exitWith {
diag_log text format ["[AGM] ERROR: No array for function filter in %1", _fnc_scriptNameParent];
diag_log text format ["[ACE] ERROR: No array for function filter in %1", _fnc_scriptNameParent];
[]
};

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private ["_crate", "_weapons", "_items"];

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private "_unit";

View File

@ -9,12 +9,13 @@
* Return value:
* Reasons, why the unit is a captive. An empty array is returned if the unit is not a captive (Array of Strings)
*/
#include "script_component.hpp"
private ["_unit", "_captivityReasons", "_unitCaptivityStatus", "_unitCaptivityReasons"];
_unit = _this select 0;
_captivityReasons = missionNamespace getVariable ["AGM_captivityReasons", []];
_captivityReasons = missionNamespace getVariable ["ACE_captivityReasons", []];
_unitCaptivityStatus = [captiveNum _unit, count _captivityReasons] call FUNC(binarizeNumber);

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private ["_name", "_cfgClass", "_classes"];

View File

@ -2,13 +2,14 @@
* Author: commy2
*
* Get the commander config of a vehicles turret.
*
*
* Argument:
* 0: vehicle type (String)
*
*
* Return value:
* Commander config (Config)
*/
#include "script_component.hpp"
private ["_vehicle", "_config", "_turret"];

View File

@ -2,13 +2,14 @@
* Author: commy2
*
* Get the gunner config of a vehicles turret.
*
*
* Argument:
* 0: vehicle type (String)
*
*
* Return value:
* Gunner config (Config)
*/
#include "script_component.hpp"
private ["_vehicle", "_config", "_turret"];

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private ["_unit", "_anim", "_stance"];

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private ["_configName", "_index"];

View File

@ -2,30 +2,15 @@
* Author: bux578
*
* Gets the turret index of door gunners
*
*
* Argument:
* 0: Vehicle type (String)
*
*
* Return value:
* Turret indexes of the door gunner. Empty array means no gunner position. (Array)
*/
#include "script_component.hpp"
/*
Name: FUNC(getDoorTurrets)
Author(s):
bux578
Description:
Returns the turret indices of door gunners
Parameters:
0: STRING - vehicle type
Returns:
ARRAY<NUMBER>
*/
private ["_vehicleType", "_turrets", "_doorTurrets", "_config"];
_vehicleType = _this select 0;

View File

@ -13,16 +13,17 @@ Returns:
ARRAY(of strings) - Reason why the unit is force walking
Example:
[AGM_Player] call FUNC(getForceWalkStatus)
[ACE_Player] call FUNC(getForceWalkStatus)
*/
#include "script_component.hpp"
private ["_unit", "_forceWalkReasons", "_unitForceWalkNumber", "_unitForceWalkStatus", "_unitForceWalkReasons"];
_unit = _this select 0;
_forceWalkReasons = missionNamespace getVariable ["AGM_forceWalkReasons", []];
_forceWalkReasons = missionNamespace getVariable ["ACE_forceWalkReasons", []];
_unitForceWalkNumber = _unit getVariable ["AGM_forceWalkStatusNumber", 0];
_unitForceWalkNumber = _unit getVariable ["ACE_forceWalkStatusNumber", 0];
_unitForceWalkStatus = [_unitForceWalkNumber, count _forceWalkReasons] call FUNC(binarizeNumber);

View File

@ -9,6 +9,7 @@
* Return Value:
* The hitpoints (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_config", "_hitpoints"];

View File

@ -9,6 +9,7 @@
* Return Value:
* The hitpoints with selections. Format: [hitpoints, selections]. They correspond by index. (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_config", "_hitpoints", "_selections"];

View File

@ -13,6 +13,7 @@
* Return Value:
* Nothing
*/
#include "script_component.hpp"
#define CANGETINDRIVER (isNull (driver _vehicle) || {!alive driver _vehicle}) && {!lockedDriver _vehicle} && {getNumber (_config >> "isUav") != 1}
#define CANGETINTURRETINDEX (isNull (_vehicle turretUnit _turret) || {!alive (_vehicle turretUnit _turret)}) && {!(_vehicle lockedTurret _turret)} && {getNumber (_config >> "isUav") != 1}

View File

@ -9,6 +9,7 @@
* Return Value:
* Marker Type (string)
*/
#include "script_component.hpp"
_group = _this select 0;
_leader = leader _group;
@ -34,8 +35,8 @@ if (
(getNumber (configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "transportRepair") > 0) or
(getNumber (configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "transportFuel") > 0) or
(getNumber (configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "transportAmmo") > 0) or
(getNumber (configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "AGM_canRepair") > 0) or
(getNumber (configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "AGM_fuelCapacityCargo") > 0)
(getNumber (configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "ACE_canRepair") > 0) or
(getNumber (configFile >> "CfgVehicles" >> (typeOf _vehicle) >> "ACE_fuelCapacityCargo") > 0)
) exitWith {
["n_maint", "b_maint", "o_maint"] select ((["GUER", "WEST", "EAST"] find (str _side)) max 0)
};

View File

@ -10,6 +10,7 @@
* Return value:
* The name.
*/
#include "script_component.hpp"
private ["_unit", "_showEffective", "_name"];
@ -23,7 +24,7 @@ if (isNil "_showEffective") then {
_name = "";
if (_unit isKindOf "CAManBase") then {
_name = _unit getVariable ["AGM_Name", localize QUOTE(DOUBLES(STR,GVAR(Unknown)))];
_name = _unit getVariable ["ACE_Name", localize QUOTE(DOUBLES(STR,GVAR(Unknown)))];
} else {
if (_showEffective) then {
_name = [effectiveCommander _unit] call FUNC(getName);

View File

@ -2,13 +2,14 @@
* Author: commy2
*
* Get a number from the mission.sqm file. Mission has to be saved in the Editor.
*
*
* Argument:
* 0: Path of the entry in the mission.sqm (Array)
*
*
* Return value:
* Value of the entry. Note: If the entry does not exist, it might return 0 or an entry with the same name of another class! (Number)
*/
#include "script_component.hpp"
private "_number";

View File

@ -9,5 +9,6 @@
* Return Value:
* [pitch, bank, yaw]
*/
#include "script_component.hpp"
((_this select 0) call BIS_fnc_getPitchBank) + [getDir (_this select 0)]

View File

@ -9,6 +9,7 @@
* Return value:
* Value of the entry. Note: If the entry does not exist, it might return an empty string or an entry with the same name of another class! (String)
*/
#include "script_component.hpp"
private ["_path", "_mission", "_a", "_class", "_index", "_array", "_b", "_entry"];

View File

@ -2,14 +2,15 @@
* Author: commy2
*
* Get players viewing direction and slope
*
*
* Argument:
* None.
*
*
* Return value:
* 0: Azimuth (Number)
* 1: Inclination or 'slope' (Number)
*/
#include "script_component.hpp"
private ["_position", "_direction", "_azimuth", "_inclination"];

View File

@ -11,6 +11,7 @@
* Return value:
* Measured distance in meters. Can return maximal or minimal distance (Number)
*/
#include "script_component.hpp"
private ["_interval", "_maxDistance", "_minDistance", "_position", "_laser", "_line", "_distance", "_iteration"];
@ -36,7 +37,7 @@ while {
_laser set [2, (_laser select 2) - (getTerrainHeightASL _laser min 0)];
_line set [1, _laser];
_distance = _distance + (([1, -1] select (lineIntersects (_line + [vehicle AGM_player]) || {terrainIntersectASL _line})) * _iteration);
_distance = _distance + (([1, -1] select (lineIntersects (_line + [vehicle ACE_player]) || {terrainIntersectASL _line})) * _iteration);
};
_distance = _interval * round (_distance / _interval);

View File

@ -2,13 +2,14 @@
* Author: commy2
*
* Get the nearest object the player is looking at. Used for laser designator instead of cursorTarget.
*
*
* Argument:
* 0: Maximal distance to search. (Number)
*
*
* Return value:
* Nearest object directly in line of sight, if none objNull (Object)
*/
#include "script_component.hpp"
private ["_maxDistance", "_position", "_laser", "_intersects"];

View File

@ -9,6 +9,7 @@
* Return value:
* Turret index of the vehicles commander. Empty array means no observer position. (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_turrets", "_turret", "_config"];

View File

@ -10,6 +10,7 @@
* Return value:
* Turret config (Config)
*/
#include "script_component.hpp"
private ["_config", "_turretIndex", "_index", "_offset", "_config2", "_foundClasses"];

View File

@ -9,6 +9,7 @@
* Return value:
* Turret index of the vehicles gunner. Empty array means no copilot position. (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_turrets", "_turret", "_config"];

View File

@ -9,6 +9,7 @@
* Return value:
* Turret index of the vehicles gunner. Empty array means no gunner position. (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_turrets", "_turret", "_config"];

View File

@ -9,6 +9,7 @@
* Return value:
* Turret index array or config path. E.g: [0] for gunner or [0,0] for commander. Returns empty array if unit is not in a turret. (Array)
*/
#include "script_component.hpp"
private ["_unit", "_vehicle", "_turrets", "_units", "_index"];

View File

@ -9,12 +9,13 @@
* Return value:
* All turret index arrays of the vehicle. E.g: [[0], [0,0]] (Array)
*/
#include "script_component.hpp"
private ["_type", "_config", "_turrets", "_fnc_addTurret"];
_type = _this select 0;
_varName = format ["AGM_CachedTurrets_%1", _type];
_varName = format ["ACE_CachedTurrets_%1", _type];
_turrets = + (uiNamespace getVariable _varName);
if (!isNil "_turrets") exitWith {_turrets};

View File

@ -9,6 +9,7 @@
* Return value:
* Turret index of the vehicles gunner. Empty array means no ffv turrets. (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_turrets", "_turret", "_config"];

View File

@ -9,6 +9,7 @@
* Return value:
* Turret index of the vehicles gunner. Empty array means no other turrets. (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_turrets", "_turret", "_config"];

View File

@ -16,8 +16,9 @@ Returns:
STRING - Position in the UAV that is currently being controled by the unit.
Example:
[AGM_Player] call FUNC(getUavControlPosition)
[ACE_Player] call FUNC(getUavControlPosition)
*/
#include "script_component.hpp"
private ["_unit", "_uav", "_positionArray", "_playerIndex"];

View File

@ -9,6 +9,7 @@
* Return value:
* Vehicle cargo positions. (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_config", "_cargo", "_codrivers"];

View File

@ -9,6 +9,7 @@
* Return value:
* Vehicle codriver positions. (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_config", "_cargo", "_codrivers"];

View File

@ -10,6 +10,7 @@
* Return value:
* Crew (Array)
*/
#include "script_component.hpp"
private ["_vehicle", "_types", "_crew"];

View File

@ -2,20 +2,21 @@
* Author: commy2
*
* Get players weapon direction and slope
*
*
* Argument:
* 0: Weapon name (String)
*
*
* Return value:
* 0: Azimuth (Number)
* 1: Inclination or 'slope' (Number)
*/
#include "script_component.hpp"
private ["_weapon", "_direction", "_azimuth", "_inclination"];
_weapon = _this select 0;
_direction = AGM_player weaponDirection _weapon;
_direction = ACE_player weaponDirection _weapon;
_azimuth = (_direction select 0) atan2 (_direction select 1);
_inclination = asin (_direction select 2);

View File

@ -9,6 +9,7 @@
* Return value:
* Slot index of the given class name, 1: primary, 2: secondary, 3: handgun, else: -1 (Number)
*/
#include "script_component.hpp"
private ["_weapon", "_type", "_index"];

View File

@ -9,6 +9,7 @@
* Return value:
* Wind direction. (String)
*/
#include "script_component.hpp"
switch (round (windDir / 360 * 16)) do {
case 1 : {localize QUOTE(DOUBLES(STR,GVAR(SSW)))};

View File

@ -9,6 +9,7 @@
* Return value:
* None.
*/
#include "script_component.hpp"
private "_unit";

View File

@ -11,6 +11,7 @@
* Return Value:
* Hadamard Product
*/
#include "script_component.hpp"
_vector1 = _this select 0;
_vector2 = _this select 1;

View File

@ -1,3 +1,4 @@
// by commy2
#include "script_component.hpp"
getNumber (configFile >> "CfgMovesMaleSdr" >> "States" >> animationState (_this select 0) >> "looped") == 0

View File

@ -1,4 +1,5 @@
// by commy2
#include "script_component.hpp"
private ["_array", "_value", "_min", "_max"];

View File

@ -2,12 +2,13 @@
* Author: commy2
*
* Check if wind is set on auto.
*
*
* Argument:
* None.
*
*
* Return value:
* This mission has automatic wind? (Bool)
*/
#include "script_component.hpp"
["Mission", "Intel", "windForced"] call FUNC(getNumberFromMissionSQM) != 1

View File

@ -1,26 +1,27 @@
/*
Name: FUNC(isEOD)
Author: Garth de Wet (LH)
Description:
Checks whether the passed unit is an explosive specialist.
Either through config entry: "canDeactivateMines"
or
unit setVariable ["AGM_isEOD", true]
Parameters:
or
unit setVariable ["ACE_isEOD", true]
Parameters:
0: OBJECT - Unit to check if is a specialist
Returns:
BOOLEAN
Example:
_isSpecialist = [player] call FUNC(isEOD);
*/
#include "script_component.hpp"
private "_unit";
_unit = _this select 0;
_unit getVariable ["AGM_isEOD", getNumber (configFile >> "CfgVehicles" >> typeOf _unit >> "canDeactivateMines") == 1]
_unit getVariable ["ACE_isEOD", getNumber (configFile >> "CfgVehicles" >> typeOf _unit >> "canDeactivateMines") == 1]

View File

@ -9,9 +9,10 @@
* Return Value:
* Bool: is the unit an engineer?
*/
#include "script_component.hpp"
private "_unit";
_unit = _this select 0;
_unit getVariable ["AGM_IsEngineer", getNumber (configFile >> "CfgVehicles" >> typeOf _unit >> "engineer") == 1]
_unit getVariable ["ACE_IsEngineer", getNumber (configFile >> "CfgVehicles" >> typeOf _unit >> "engineer") == 1]

View File

@ -9,6 +9,7 @@
* Return value:
* Is the unit in a building? (Bool)
*/
#include "script_component.hpp"
#define DISTANCE 10

View File

@ -9,9 +9,10 @@
* Return Value:
* Bool: is unit medic?
*/
#include "script_component.hpp"
private ["_unit"];
_unit = _this select 0;
_unit getVariable ["AGM_isMedic", (getNumber(configFile >> "CfgVehicles" >> typeOf _unit >> "attendant") == 1)]
_unit getVariable ["ACE_isMedic", (getNumber(configFile >> "CfgVehicles" >> typeOf _unit >> "attendant") == 1)]

View File

@ -10,5 +10,6 @@
* Return Value:
* Bool: is unit a player?
*/
#include "script_component.hpp"
isPlayer (_this select 0) || {_this select 0 == call FUNC(player)}

View File

@ -9,6 +9,7 @@
* Return value:
* Is the unit turned out or not? Will return false if there is no option to turn out in the first place. (Bool)
*/
#include "script_component.hpp"
private ["_unit", "_vehicle", "_config", "_animation", "_action", "_inAction", "_turretIndex"];

View File

@ -1,3 +1,4 @@
// by commy2
#include "script_component.hpp"
[-1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 30, 48, 46, 32, 18, 33, 34, 35, 23, 36, 37, 38, 50, 49, 24, 25, 16, 19, 31, 20, 22, 47, 17, 45, 44, 21] select (["1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z"] find toUpper (_this select 0)) + 1

Some files were not shown because too many files have changed in this diff Show More