From dd7e7463686ed731af9468726fbe7cc8716be089 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sat, 11 Apr 2015 19:52:30 +0200 Subject: [PATCH 01/59] formatting --- .../common/functions/fnc_disableUserInput.sqf | 132 ++++++++++-------- 1 file changed, 73 insertions(+), 59 deletions(-) diff --git a/addons/common/functions/fnc_disableUserInput.sqf b/addons/common/functions/fnc_disableUserInput.sqf index 57be44fe43..a1486438b6 100644 --- a/addons/common/functions/fnc_disableUserInput.sqf +++ b/addons/common/functions/fnc_disableUserInput.sqf @@ -1,14 +1,16 @@ /* * Author: commy2 - * * Disables key input. ESC can still be pressed to open the menu. * - * Argument: - * 0: True to disable key inputs, false to re-enable them (Bool) + * Arguments: + * 0: True to disable key inputs, false to re-enable them * * Return value: * Nothing + * + * Public: Yes */ + #include "script_component.hpp" private ["_state", "_dlg"]; @@ -16,76 +18,88 @@ private ["_state", "_dlg"]; _state = _this select 0; if (_state) then { - disableSerialization; + disableSerialization; - if (!isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull])) exitWith {}; - if ("ACE_DisableUserInput" in ([BIS_stackedEventHandlers_onEachFrame, {_this select 0}] call FUNC(map))) exitWith {}; + if (!isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull])) 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); + // end TFAR and ACRE2 radio transmissions + call FUNC(endRadioTransmission); - // Close map - if (visibleMap && {!(player getVariable ["ACE_canSwitchUnits", false])}) then {openMap false}; + // Close map + if (visibleMap && {!(player getVariable ["ACE_canSwitchUnits", false])}) then { + openMap false; + }; - closeDialog 0; - createDialog QGVAR(DisableMouse_Dialog); + closeDialog 0; + createDialog QGVAR(DisableMouse_Dialog); - _dlg = uiNamespace getVariable QGVAR(dlgDisableMouse); + _dlg = uiNamespace getVariable QGVAR(dlgDisableMouse); - _dlg displayAddEventHandler ["KeyDown", { - _key = _this select 1; - - if (_key == 1 && {alive player}) then { - createDialog (["RscDisplayInterrupt", "RscDisplayMPInterrupt"] select isMultiplayer); - - disableSerialization; - _dlg = finddisplay 49; - _dlg displayAddEventHandler ["KeyDown", { + _dlg displayAddEventHandler ["KeyDown", { _key = _this select 1; - !(_key == 1) - }]; - for "_index" from 100 to 2000 do { - (_dlg displayCtrl _index) ctrlEnable false; - }; + if (_key == 1 && {alive player}) then { + createDialog (["RscDisplayInterrupt", "RscDisplayMPInterrupt"] select isMultiplayer); - _ctrl = _dlg displayctrl 103; - _ctrl ctrlSetEventHandler ["buttonClick", QUOTE(while {!isNull (uiNamespace getVariable [ARR_2(QUOTE(QGVAR(dlgDisableMouse)),displayNull)])} do {closeDialog 0}; failMission 'LOSER'; [false] call DFUNC(disableUserInput);)]; - _ctrl ctrlEnable true; - _ctrl ctrlSetText "ABORT"; - _ctrl ctrlSetTooltip "Abort."; + disableSerialization; + _dlg = finddisplay 49; + _dlg displayAddEventHandler ["KeyDown", { + _key = _this select 1; + !(_key == 1) + }]; - _ctrl = _dlg displayctrl ([104, 1010] select isMultiplayer); - _ctrl ctrlSetEventHandler ["buttonClick", QUOTE(closeDialog 0; player setDamage 1; [false] call DFUNC(disableUserInput);)]; - _ctrl ctrlEnable (call {_config = missionConfigFile >> "respawnButton"; !isNumber _config || {getNumber _config == 1}}); - _ctrl ctrlSetText "RESPAWN"; - _ctrl ctrlSetTooltip "Respawn."; - }; + for "_index" from 100 to 2000 do { + (_dlg displayCtrl _index) ctrlEnable false; + }; - 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 ["ACE_canSwitchUnits", false]}) then {(uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; openMap true}; + _ctrl = _dlg displayctrl 103; + _ctrl ctrlSetEventHandler ["buttonClick", QUOTE(while {!isNull (uiNamespace getVariable [ARR_2(QUOTE(QGVAR(dlgDisableMouse)),displayNull)])} do {closeDialog 0}; failMission 'LOSER'; [false] call DFUNC(disableUserInput);)]; + _ctrl ctrlEnable true; + _ctrl ctrlSetText "ABORT"; + _ctrl ctrlSetTooltip "Abort."; - 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; - }; - }; + _ctrl = _dlg displayctrl ([104, 1010] select isMultiplayer); + _ctrl ctrlSetEventHandler ["buttonClick", QUOTE(closeDialog 0; player setDamage 1; [false] call DFUNC(disableUserInput);)]; + _ctrl ctrlEnable (call {_config = missionConfigFile >> "respawnButton"; !isNumber _config || {getNumber _config == 1}}); + _ctrl ctrlSetText "RESPAWN"; + _ctrl ctrlSetTooltip "Respawn."; + }; - _key > 0 - }]; - _dlg displayAddEventHandler ["KeyUp", {true}]; + 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 ["ACE_canSwitchUnits", false]}) then { + (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; openMap true + }; + + 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; + }; + }; + + _key > 0 + }]; + + _dlg displayAddEventHandler ["KeyUp", {true}]; + + ["ACE_DisableUserInput", "onEachFrame", { + if (isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) && {!visibleMap && isNull findDisplay 49 && isNull findDisplay 312 && isNull findDisplay 632}) then { + ["ACE_DisableUserInput", "onEachFrame"] call BIS_fnc_removeStackedEventHandler; + [true] call FUNC(disableUserInput); + }; + }] call BIS_fnc_addStackedEventHandler; - ["ACE_DisableUserInput", "onEachFrame", { - if (isNull (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) && {!visibleMap && isNull findDisplay 49 && isNull findDisplay 312 && isNull findDisplay 632}) then { - ["ACE_DisableUserInput", "onEachFrame"] call BIS_fnc_removeStackedEventHandler; - [true] call FUNC(disableUserInput); - }; - }] call BIS_fnc_addStackedEventHandler; } else { - if ("ACE_DisableUserInput" in ([BIS_stackedEventHandlers_onEachFrame, {_this select 0}] call FUNC(map))) then { - ["ACE_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; + (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; }; From 24765741ab3c9cacb0ad3e0aec9e6af4030311a8 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sat, 11 Apr 2015 20:05:22 +0200 Subject: [PATCH 02/59] Enabled setAccTime fix from commy --- addons/common/functions/fnc_disableUserInput.sqf | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/addons/common/functions/fnc_disableUserInput.sqf b/addons/common/functions/fnc_disableUserInput.sqf index a1486438b6..0b1275e9cf 100644 --- a/addons/common/functions/fnc_disableUserInput.sqf +++ b/addons/common/functions/fnc_disableUserInput.sqf @@ -67,15 +67,20 @@ if (_state) then { }; if (_key in actionKeys "TeamSwitch" && {teamSwitchEnabled}) then { - (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; teamSwitch - };//_acc = accTime; teamSwitch; setAccTime _acc}; + (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; + _acc = accTime; + teamSwitch; + setAccTime _acc; + }; if (_key in actionKeys "CuratorInterface" && {getAssignedCuratorLogic player in allCurators}) then { - (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; openCuratorInterface; + (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; + openCuratorInterface; }; if (_key in actionKeys "ShowMap" && {player getVariable ["ACE_canSwitchUnits", false]}) then { - (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; openMap true + (uiNamespace getVariable [QGVAR(dlgDisableMouse), displayNull]) closeDisplay 0; + openMap true; }; if (serverCommandAvailable "#missions" || {player getVariable ["ACE_isUnconscious", false] && {(call FUNC(player)) getVariable [QEGVAR(medical,AllowChatWhileUnconscious), missionNamespace getVariable [QEGVAR(medical,AllowChatWhileUnconscious), false]]}}) then { From f57f7186c203f0e2f7faf4f30dc40aeea6e2a149 Mon Sep 17 00:00:00 2001 From: OnkelDisMaster Date: Sat, 11 Apr 2015 21:08:00 +0200 Subject: [PATCH 03/59] Config for compatiblity to ASDG Joint Rails Added the scopes and railitems to the according ASDG rails. --- optionals/asdg_comp/config.cpp | 42 ++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 optionals/asdg_comp/config.cpp diff --git a/optionals/asdg_comp/config.cpp b/optionals/asdg_comp/config.cpp new file mode 100644 index 0000000000..c82d5e0624 --- /dev/null +++ b/optionals/asdg_comp/config.cpp @@ -0,0 +1,42 @@ +#include "script_component.hpp" + +class CfgPatches +{ + class ADDON + { + units[] = {}; + weapons[] = {}; + requiredVersion = REQUIRED_VERSION; + requiredAddons[] = {"asdg_jointrails","ace_laserpointer","ace_optics"}; + author[]={"OnkelDisMaster"}; + authorUrl = "http://2.xn--gebirgsjgerkompanie-nwb.de/"; + VERSION_CONFIG; + }; +}; + +class asdg_SlotInfo; +class asdg_FrontSideRail: asdg_SlotInfo +{ + class compatibleItems + { + ACE_acc_pointer_red = 1; + ACE_acc_pointer_green = 1; + }; +}; + +class asdg_OpticRail; +class asdg_OpticRail1913: asdg_OpticRail +{ + class compatibleItems + { + ACE_optic_Hamr_2D = 1; + ACE_optic_Hamr_PIP = 1; + ACE_optic_Arco_2D = 1; + ACE_optic_Arco_PIP = 1; + ACE_optic_MRCO_2D = 1; + ACE_optic_SOS_2D = 1; + ACE_optic_SOS_PIP = 1; + ACE_optic_LRPS_2D = 1; + ACE_optic_LRPS_PIP = 1; + }; +}; From a18171547e231ad7f01bf5b2aa6ed4916203e7a7 Mon Sep 17 00:00:00 2001 From: OnkelDisMaster Date: Sat, 11 Apr 2015 21:11:06 +0200 Subject: [PATCH 04/59] script_component.hpp for asdg_comp Included in config.cpp of #485 --- optionals/asdg_comp/script_component.hpp | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 optionals/asdg_comp/script_component.hpp diff --git a/optionals/asdg_comp/script_component.hpp b/optionals/asdg_comp/script_component.hpp new file mode 100644 index 0000000000..e67bf3b9e4 --- /dev/null +++ b/optionals/asdg_comp/script_component.hpp @@ -0,0 +1,5 @@ +#define COMPONENT asdg_comp + +#include "\z\ace\addons\main\script_mod.hpp" + +#include "\z\ace\addons\main\script_macros.hpp" From 6899659f1c9fe5f055dd6207a852edd32a6d2952 Mon Sep 17 00:00:00 2001 From: OnkelDisMaster Date: Sat, 11 Apr 2015 21:19:37 +0200 Subject: [PATCH 05/59] Update config.cpp --- optionals/asdg_comp/config.cpp | 54 +++++++++++++++++----------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/optionals/asdg_comp/config.cpp b/optionals/asdg_comp/config.cpp index c82d5e0624..1a51ba0432 100644 --- a/optionals/asdg_comp/config.cpp +++ b/optionals/asdg_comp/config.cpp @@ -2,41 +2,41 @@ class CfgPatches { - class ADDON - { - units[] = {}; - weapons[] = {}; - requiredVersion = REQUIRED_VERSION; - requiredAddons[] = {"asdg_jointrails","ace_laserpointer","ace_optics"}; - author[]={"OnkelDisMaster"}; - authorUrl = "http://2.xn--gebirgsjgerkompanie-nwb.de/"; - VERSION_CONFIG; - }; + class ADDON + { + units[] = {}; + weapons[] = {}; + requiredVersion = REQUIRED_VERSION; + requiredAddons[] = {"asdg_jointrails","ace_laserpointer","ace_optics"}; + author[]={"OnkelDisMaster"}; + authorUrl = "http://2.xn--gebirgsjgerkompanie-nwb.de/"; + VERSION_CONFIG; + }; }; class asdg_SlotInfo; class asdg_FrontSideRail: asdg_SlotInfo { - class compatibleItems - { - ACE_acc_pointer_red = 1; - ACE_acc_pointer_green = 1; - }; + class compatibleItems + { + ACE_acc_pointer_red = 1; + ACE_acc_pointer_green = 1; + }; }; class asdg_OpticRail; class asdg_OpticRail1913: asdg_OpticRail { - class compatibleItems - { - ACE_optic_Hamr_2D = 1; - ACE_optic_Hamr_PIP = 1; - ACE_optic_Arco_2D = 1; - ACE_optic_Arco_PIP = 1; - ACE_optic_MRCO_2D = 1; - ACE_optic_SOS_2D = 1; - ACE_optic_SOS_PIP = 1; - ACE_optic_LRPS_2D = 1; - ACE_optic_LRPS_PIP = 1; - }; + class compatibleItems + { + ACE_optic_Hamr_2D = 1; + ACE_optic_Hamr_PIP = 1; + ACE_optic_Arco_2D = 1; + ACE_optic_Arco_PIP = 1; + ACE_optic_MRCO_2D = 1; + ACE_optic_SOS_2D = 1; + ACE_optic_SOS_PIP = 1; + ACE_optic_LRPS_2D = 1; + ACE_optic_LRPS_PIP = 1; + }; }; From 876cec35df5b2f0a0859f4a460f2ffbc1ef09a9c Mon Sep 17 00:00:00 2001 From: OnkelDisMaster Date: Sat, 11 Apr 2015 21:20:59 +0200 Subject: [PATCH 06/59] Update config.cpp --- optionals/asdg_comp/config.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/optionals/asdg_comp/config.cpp b/optionals/asdg_comp/config.cpp index 1a51ba0432..d76a4da654 100644 --- a/optionals/asdg_comp/config.cpp +++ b/optionals/asdg_comp/config.cpp @@ -31,7 +31,7 @@ class asdg_OpticRail1913: asdg_OpticRail { ACE_optic_Hamr_2D = 1; ACE_optic_Hamr_PIP = 1; - ACE_optic_Arco_2D = 1; + ACE_optic_Arco_2D = 1; ACE_optic_Arco_PIP = 1; ACE_optic_MRCO_2D = 1; ACE_optic_SOS_2D = 1; From 57bcb555e940730359c2c12fd5c79ffc1eaf5b29 Mon Sep 17 00:00:00 2001 From: OnkelDisMaster Date: Sat, 11 Apr 2015 21:22:07 +0200 Subject: [PATCH 07/59] Update config.cpp --- optionals/asdg_comp/config.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/optionals/asdg_comp/config.cpp b/optionals/asdg_comp/config.cpp index d76a4da654..81115fc96f 100644 --- a/optionals/asdg_comp/config.cpp +++ b/optionals/asdg_comp/config.cpp @@ -19,8 +19,8 @@ class asdg_FrontSideRail: asdg_SlotInfo { class compatibleItems { - ACE_acc_pointer_red = 1; - ACE_acc_pointer_green = 1; + ACE_acc_pointer_red = 1; + ACE_acc_pointer_green = 1; }; }; From 85acaa3ab8d4f31edd3cdfe0e7ef0bba2c472349 Mon Sep 17 00:00:00 2001 From: OnkelDisMaster Date: Sat, 11 Apr 2015 21:22:20 +0200 Subject: [PATCH 08/59] Update config.cpp --- optionals/asdg_comp/config.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/optionals/asdg_comp/config.cpp b/optionals/asdg_comp/config.cpp index 81115fc96f..18ef70cb1c 100644 --- a/optionals/asdg_comp/config.cpp +++ b/optionals/asdg_comp/config.cpp @@ -4,7 +4,7 @@ class CfgPatches { class ADDON { - units[] = {}; + units[] = {}; weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"asdg_jointrails","ace_laserpointer","ace_optics"}; From af255604ac098030613ab983a313e790dac2a02e Mon Sep 17 00:00:00 2001 From: Glowbal Date: Tue, 14 Apr 2015 21:17:36 +0200 Subject: [PATCH 09/59] Switched to event based sync system for open wounds --- addons/medical/XEH_postInit.sqf | 2 +- addons/medical/functions/fnc_handleDamage_wounds.sqf | 1 - .../medical/functions/fnc_onWoundUpdateRequest.sqf | 12 +++++------- addons/medical/functions/fnc_requestWoundSync.sqf | 4 ++-- addons/medical/script_component.hpp | 2 +- 5 files changed, 9 insertions(+), 12 deletions(-) diff --git a/addons/medical/XEH_postInit.sqf b/addons/medical/XEH_postInit.sqf index 1b0a38f1af..3743511790 100644 --- a/addons/medical/XEH_postInit.sqf +++ b/addons/medical/XEH_postInit.sqf @@ -247,7 +247,7 @@ if (USE_WOUND_EVENT_SYNC) then { // We are only pulling the wounds for the units in the player group. Anything else will come when the unit interacts with them. { [_x, _newPlayer] call FUNC(requestWoundSync); - }foreach units group player; + }foreach units group _newPlayer; }; }] call EFUNC(common,addEventhandler); }; diff --git a/addons/medical/functions/fnc_handleDamage_wounds.sqf b/addons/medical/functions/fnc_handleDamage_wounds.sqf index 5933651e57..b45a974166 100644 --- a/addons/medical/functions/fnc_handleDamage_wounds.sqf +++ b/addons/medical/functions/fnc_handleDamage_wounds.sqf @@ -133,7 +133,6 @@ if (count _woundsCreated > 0) then { }; if (USE_WOUND_EVENT_SYNC) then { - // TODO Should this be done in a single broadcast? // Broadcast the new injuries across the net in parts. One broadcast per injury. Prevents having to broadcast one massive array of injuries. { ["medical_propagateWound", [_unit, _x]] call EFUNC(common,globalEvent); diff --git a/addons/medical/functions/fnc_onWoundUpdateRequest.sqf b/addons/medical/functions/fnc_onWoundUpdateRequest.sqf index c160e47ea0..ccbb373648 100644 --- a/addons/medical/functions/fnc_onWoundUpdateRequest.sqf +++ b/addons/medical/functions/fnc_onWoundUpdateRequest.sqf @@ -1,11 +1,10 @@ /* * Author: Glowbal - * Enabled the vitals loop for a unit. + * Handles an wound update request. * * Arguments: * 0: The Unit - * 1: the last known ID - * 2: Origin object + * 1: Origin object * * ReturnValue: * @@ -14,12 +13,11 @@ */ #include "script_component.hpp" -private ["_unit", "_lastId", "_openWounds"]; +private ["_unit", "_openWounds"]; _unit = _this select 0; -_lastId = _this select 1; -_originOfrequest = _this select 2; +_originOfrequest = _this select 1; -if (local _unit) then { +if (local _unit && !(local _originOfrequest)) then { _openWounds = _unit getvariable [QGVAR(openWounds), []]; { ["medical_propagateWound", [_originOfrequest], [_unit, _x]] call EFUNC(common,targetEvent); diff --git a/addons/medical/functions/fnc_requestWoundSync.sqf b/addons/medical/functions/fnc_requestWoundSync.sqf index bf6f881930..7144c49684 100644 --- a/addons/medical/functions/fnc_requestWoundSync.sqf +++ b/addons/medical/functions/fnc_requestWoundSync.sqf @@ -14,11 +14,11 @@ #include "script_component.hpp" -private [ "_target", "_caller", "_openWounds","_lastId"]; +private [ "_target", "_caller", "_openWounds"]; _target = _this select 0; _caller = _this select 1; if (local _target || GVAR(level) < 2) exitwith {}; // if the target is local, we already got the most update to date information if (_target getvariable [QGVAR(isWoundSynced), false]) exitwith {}; _target setvariable [QGVAR(isWoundSynced), true]; -["medical_woundUpdateRequest", [_target], [_target, _lastId, _caller]] call EFUNC(common,targetEvent); +["medical_woundUpdateRequest", [_target], [_target, _caller]] call EFUNC(common,targetEvent); diff --git a/addons/medical/script_component.hpp b/addons/medical/script_component.hpp index 939a811a41..bac6744bc1 100644 --- a/addons/medical/script_component.hpp +++ b/addons/medical/script_component.hpp @@ -11,4 +11,4 @@ #include "\z\ace\addons\main\script_macros.hpp" -#define USE_WOUND_EVENT_SYNC false +#define USE_WOUND_EVENT_SYNC true From 5eededd3e1a9808418cd3ca73797bfe47513bcba Mon Sep 17 00:00:00 2001 From: commy2 Date: Wed, 15 Apr 2015 15:01:07 +0200 Subject: [PATCH 10/59] Recoil overhaul initial commmit --- addons/recoil/$PBOPREFIX$ | 1 + addons/recoil/CfgRecoils.hpp | 240 +++++++++++++++++++++++++++++ addons/recoil/config.cpp | 15 ++ addons/recoil/script_component.hpp | 12 ++ 4 files changed, 268 insertions(+) create mode 100644 addons/recoil/$PBOPREFIX$ create mode 100644 addons/recoil/CfgRecoils.hpp create mode 100644 addons/recoil/config.cpp create mode 100644 addons/recoil/script_component.hpp diff --git a/addons/recoil/$PBOPREFIX$ b/addons/recoil/$PBOPREFIX$ new file mode 100644 index 0000000000..1ab9ffa5e1 --- /dev/null +++ b/addons/recoil/$PBOPREFIX$ @@ -0,0 +1 @@ +z\ace\addons\recoil \ No newline at end of file diff --git a/addons/recoil/CfgRecoils.hpp b/addons/recoil/CfgRecoils.hpp new file mode 100644 index 0000000000..27283e71f1 --- /dev/null +++ b/addons/recoil/CfgRecoils.hpp @@ -0,0 +1,240 @@ + +class CfgRecoils { + class Default { + muzzleOuter[] = {0,"0.4f","0.5f","0.6f"}; + muzzleInner[] = {0,"0.05f","0.2f","0.2f"}; + kickBack[] = {"0.05f",0.1}; + permanent = 0.1; + temporary = 0.01; + }; + + class recoil_default: Default { + muzzleOuter[] = {0.3,1,0.3,0.2}; + muzzleInner[] = {0,0,0.1,0.1}; + kickBack[] = {0.03,0.06}; + permanent = 0.1; + temporary = 0.01; + }; + + class recoil_mk20: recoil_default { + muzzleOuter[] = {0.2,0.6,0.2,0.2}; + kickBack[] = {0.01,0.03}; + temporary = 0.01; + }; + + class recoil_mk20c: recoil_default { + muzzleOuter[] = {0.2,0.8,0.3,0.2}; + kickBack[] = {0.02,0.04}; + temporary = 0.015; + }; + + class recoil_trg20: recoil_default { + muzzleOuter[] = {0.2,1,0.3,0.3}; + kickBack[] = {0.02,0.04}; + temporary = 0.015; + }; + + class recoil_trg21: recoil_default { + muzzleOuter[] = {0.2,0.8,0.3,0.2}; + kickBack[] = {0.01,0.03}; + temporary = 0.01; + }; + + class recoil_mx: recoil_default { + muzzleOuter[] = {0.3,1,0.4,0.3}; + kickBack[] = {0.02,0.04}; + temporary = 0.01; + }; + + class recoil_mxc: recoil_default { + muzzleOuter[] = {0.3,1.2,0.4,0.3}; + kickBack[] = {0.03,0.06}; + temporary = 0.015; + }; + + class recoil_sw: recoil_default { + muzzleOuter[] = {0.3,0.8,0.5,0.2}; + kickBack[] = {0.02,0.04}; + temporary = 0.005; + }; + + class recoil_mxm: recoil_default { + muzzleOuter[] = {0.3,0.8,0.4,0.3}; + kickBack[] = {0.02,0.04}; + temporary = 0.01; + }; + + class recoil_ktb: recoil_default { + muzzleOuter[] = {0.3,1,0.3,0.3}; + kickBack[] = {0.02,0.04}; + temporary = 0.01; + }; + + class recoil_ktbc: recoil_default { + muzzleOuter[] = {0.3,1.2,0.3,0.3}; + kickBack[] = {0.03,0.06}; + temporary = 0.015; + }; + + class recoil_smg_01: recoil_default { + muzzleOuter[] = {0.1,0.8,0.3,0.2}; + kickBack[] = {0.01,0.03}; + temporary = 0.015; + }; + + class recoil_smg_02: recoil_default { + muzzleOuter[] = {0.1,0.6,0.2,0.2}; + kickBack[] = {0.01,0.02}; + temporary = 0.01; + }; + + class recoil_pdw: recoil_default { + muzzleOuter[] = {0.2,1,0.3,0.3}; + kickBack[] = {0.02,0.04}; + temporary = 0.02; + }; + + class recoil_sdar: recoil_default { + muzzleOuter[] = {0.2,1,0.3,0.3}; + kickBack[] = {0.02,0.04}; + temporary = 0.01; + }; + + class recoil_pistol_p07: recoil_default { + muzzleOuter[] = {0.2,1,0.2,0.3}; + kickBack[] = {0.03,0.06}; + temporary = 0.03; + }; + + class recoil_pistol_rook40: recoil_default { + muzzleOuter[] = {0.2,1,0.2,0.3}; + kickBack[] = {0.03,0.06}; + temporary = 0.02; + }; + + class recoil_pistol_acpc2: recoil_default { + muzzleOuter[] = {0.2,1.5,0.2,0.3}; + kickBack[] = {0.04,0.08}; + temporary = 0.04; + }; + + class recoil_pistol_4five: recoil_default { + muzzleOuter[] = {0.2,1.5,0.2,0.3}; + kickBack[] = {0.04,0.08}; + temporary = 0.06; + }; + + class recoil_pistol_zubr: recoil_default { + muzzleOuter[] = {0.2,1.5,0.2,0.3}; + kickBack[] = {0.04,0.08}; + temporary = 0.08; + }; + + class recoil_pistol_signal: recoil_default { + muzzleOuter[] = {0.2,1.5,0.2,0.3}; + kickBack[] = {0.02,0.04}; + temporary = 0.02; + }; + + class recoil_rpg: recoil_default { + muzzleOuter[] = {2,3,1,0.5}; + kickBack[] = {0.08,0.1}; + temporary = 0.1; + }; + + class recoil_nlaw: recoil_default { + muzzleOuter[] = {2,3,1,0.5}; + kickBack[] = {0.06,0.08}; + temporary = 0.08; + }; + + class recoil_titan_long: recoil_default { + muzzleOuter[] = {2,3,1,0.5}; + kickBack[] = {0.1,0.12}; + temporary = 0.15; + }; + + class recoil_titan_short: recoil_default { + muzzleOuter[] = {2,3,1,0.5}; + kickBack[] = {0.1,0.12}; + temporary = 0.12; + }; + + class recoil_mk200: recoil_default { + muzzleOuter[] = {0.4,0.6,0.6,0.2}; + kickBack[] = {0.03,0.06}; + temporary = 0.005; + }; + + class recoil_zafir: recoil_default { + muzzleOuter[] = {0.5,1,0.7,0.3}; + kickBack[] = {0.02,0.08}; + temporary = 0.005; + }; + + class recoil_m320: recoil_default { + muzzleOuter[] = {1,3,0.5,0.6}; + kickBack[] = {0.08,0.1}; + temporary = 0.02; + }; + + class recoil_gm6: recoil_default { + muzzleOuter[] = {1.4,3.5,0.7,0.8}; + kickBack[] = {0.1,0.12}; + temporary = 0.025; + }; + + class recoil_ebr: recoil_default { + muzzleOuter[] = {0.4,1.5,0.6,0.4}; + kickBack[] = {0.04,0.07}; + temporary = 0.01; + }; + + class recoil_dmr_01: recoil_default { + muzzleOuter[] = {0.5,2,0.5,0.5}; + kickBack[] = {0.03,0.08}; + temporary = 0.015; + }; + + class recoil_dmr_02: recoil_default { + muzzleOuter[] = {0.5,2.5,0.6,0.5}; + kickBack[] = {0.06,0.08}; + temporary = 0.01; + }; + + class recoil_dmr_03: recoil_default { + muzzleOuter[] = {0.3,1.5,0.5,0.4}; + kickBack[] = {0.03,0.06}; + temporary = 0.005; + }; + + class recoil_dmr_04: recoil_default { + muzzleOuter[] = {0.4,1.5,0.5,0.4}; + kickBack[] = {0.02,0.04}; + temporary = 0.015; + }; + + class recoil_dmr_05: recoil_default { + muzzleOuter[] = {0.5,2.5,0.8,0.6}; + kickBack[] = {0.08,0.1}; + temporary = 0.01; + }; + + class recoil_dmr_06: recoil_default { + muzzleOuter[] = {0.5,2,0.7,0.5}; + kickBack[] = {0.05,0.1}; + temporary = 0.01; + }; + + class recoil_mmg_01: recoil_default { + muzzleOuter[] = {0.6,1.5,0.8,0.3}; + kickBack[] = {0.02,0.08}; + temporary = 0.005; + }; + + class recoil_mmg_02: recoil_default { + muzzleOuter[] = {0.5,1.5,0.6,0.4}; + kickBack[] = {0.04,0.08}; + temporary = 0.005; + }; +}; diff --git a/addons/recoil/config.cpp b/addons/recoil/config.cpp new file mode 100644 index 0000000000..1e2ce69fae --- /dev/null +++ b/addons/recoil/config.cpp @@ -0,0 +1,15 @@ +#include "script_component.hpp" + +class CfgPatches { + class ADDON { + units[] = {}; + weapons[] = {}; + requiredVersion = REQUIRED_VERSION; + requiredAddons[] = {"ace_common"}; + author[] = {"commy2"}; + authorUrl = ""; + VERSION_CONFIG; + }; +}; + +#include "CfgRecoils.hpp" diff --git a/addons/recoil/script_component.hpp b/addons/recoil/script_component.hpp new file mode 100644 index 0000000000..b5a74ec8dd --- /dev/null +++ b/addons/recoil/script_component.hpp @@ -0,0 +1,12 @@ +#define COMPONENT recoil +#include "\z\ace\addons\main\script_mod.hpp" + +#ifdef DEBUG_ENABLED_RECOIL + #define DEBUG_MODE_FULL +#endif + +#ifdef DEBUG_ENABLED_RECOIL + #define DEBUG_SETTINGS DEBUG_ENABLED_RECOIL +#endif + +#include "\z\ace\addons\main\script_macros.hpp" \ No newline at end of file From c88479d54d49e169a0eaab2fb6f48b966b6ac833 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Wed, 15 Apr 2015 19:45:42 +0200 Subject: [PATCH 11/59] staged work --- .../functions/fnc_handleBandageOpening.sqf | 16 +++++++++++++--- addons/medical/functions/fnc_init.sqf | 1 + .../fnc_treatmentAdvanced_bandageLocal.sqf | 3 ++- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/addons/medical/functions/fnc_handleBandageOpening.sqf b/addons/medical/functions/fnc_handleBandageOpening.sqf index b4e40984ae..21211c9c1b 100644 --- a/addons/medical/functions/fnc_handleBandageOpening.sqf +++ b/addons/medical/functions/fnc_handleBandageOpening.sqf @@ -59,20 +59,30 @@ if (isClass (_config >> _className)) then { _bandagedWounds = _target getvariable [QGVAR(bandagedWounds), []]; _exist = false; _injuryId = _injury select 0; +_bandagedInjury = []; { if ((_x select 0) == _injuryId) exitwith { _exist = true; _existingInjury = _x; _existingInjury set [3, (_existingInjury select 3) + _impact]; _bandagedWounds set [_foreachIndex, _existingInjury]; + + _bandagedInjury = _existingInjury; }; }foreach _bandagedWounds; if !(_exist) then { // [ID, classID, bodypart, percentage treated, bloodloss rate] - _bandagedWounds pushback [_injuryId, _injury select 1, _injury select 2, _impact, _injury select 4]; + _bandagedInjury = [_injuryId, _injury select 1, _injury select 2, _impact, _injury select 4]; + _bandagedWounds pushback _bandagedInjury; +}; + +_target setvariable [QGVAR(bandagedWounds), _bandagedWounds, !USE_WOUND_EVENT_SYNC]; + +if (USE_WOUND_EVENT_SYNC) then { + // sync _bandagedInjury + }; -_target setvariable [QGVAR(bandagedWounds), _bandagedWounds, true]; // Check if we are ever going to reopen this if (random(1) <= _reopeningChance) then { @@ -109,7 +119,7 @@ if (random(1) <= _reopeningChance) then { }foreach _bandagedWounds; if (_exist) then { - _target setvariable [QGVAR(bandagedWounds), _bandagedWounds, true]; + _target setvariable [QGVAR(bandagedWounds), _bandagedWounds, !USE_WOUND_EVENT_SYNC]; }; }; // Otherwise something went wrong, we we don't reopen them.. diff --git a/addons/medical/functions/fnc_init.sqf b/addons/medical/functions/fnc_init.sqf index ed8301b6b2..fa6aa357c2 100644 --- a/addons/medical/functions/fnc_init.sqf +++ b/addons/medical/functions/fnc_init.sqf @@ -28,6 +28,7 @@ _unit setvariable [QGVAR(tourniquets), [0,0,0,0,0,0], true]; _unit setvariable [QGVAR(openWounds), [], true]; _unit setvariable [QGVAR(bandagedWounds), [], true]; _unit setVariable [QGVAR(internalWounds), [], true]; +_unit setvariable [QGVAR(lastUniqueWoundID), 1]; // vitals _unit setVariable [QGVAR(heartRate), 80]; diff --git a/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf b/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf index 217a69cd4d..02626ff1fe 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf @@ -92,7 +92,8 @@ if (USE_WOUND_EVENT_SYNC) then { }; // Handle the reopening of bandaged wounds if (_impact > 0 && {GVAR(enableAdvancedWounds)}) then { - [_target, _impact, _part, _mostEffectiveSpot, _mostEffectiveInjury, _bandage] call FUNC(handleBandageOpening); +// TODO temp disabled until bandaged wounds are supported by event sync. +// [_target, _impact, _part, _mostEffectiveSpot, _mostEffectiveInjury, _bandage] call FUNC(handleBandageOpening); }; // If all wounds have been bandaged, we will reset all damage to 0, so the unit is not showing any blood on the model anymore. From c86be1266800b7683d0dcbb4dbfcf5a598d3111a Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 20:24:05 +0200 Subject: [PATCH 12/59] fixes #599 --- addons/medical/functions/fnc_determineIfFatal.sqf | 6 +++--- addons/medical/functions/fnc_handleDamage.sqf | 6 ++++++ addons/medical/functions/fnc_setUnconscious.sqf | 7 ++++++- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/addons/medical/functions/fnc_determineIfFatal.sqf b/addons/medical/functions/fnc_determineIfFatal.sqf index 6c90e54da3..aedcf161ee 100644 --- a/addons/medical/functions/fnc_determineIfFatal.sqf +++ b/addons/medical/functions/fnc_determineIfFatal.sqf @@ -21,10 +21,10 @@ if ((vehicle _unit != _unit) && {!alive (vehicle _unit)}) exitwith { true }; // Find the correct Damage threshold for unit. _damageThreshold = [1,1,1]; -if (isPlayer _unit) then { - //_damageThreshold =_unit getvariable[QGVAR(unitDamageThreshold), [GVAR(damageThreshold_Players), GVAR(damageThreshold_Players), GVAR(damageThreshold_Players) * 1.7]]; +if ([_unit] call EFUNC(common,IsPlayer)) then { + _damageThreshold =_unit getvariable[QGVAR(unitDamageThreshold), [GVAR(playerDamageThreshold), GVAR(playerDamageThreshold), GVAR(playerDamageThreshold) * 1.7]]; } else { - //_damageThreshold =_unit getvariable[QGVAR(unitDamageThreshold), [GVAR(damageThreshold_AI), GVAR(damageThreshold_AI), GVAR(damageThreshold_AI) * 1.7]]; + _damageThreshold =_unit getvariable[QGVAR(unitDamageThreshold), [GVAR(AIDamageThreshold), GVAR(AIDamageThreshold), GVAR(AIDamageThreshold) * 1.7]]; }; _damageBodyPart = ((_unit getvariable [QGVAR(bodyPartStatus),[0, 0, 0, 0, 0, 0]]) select _part) + _withDamage; diff --git a/addons/medical/functions/fnc_handleDamage.sqf b/addons/medical/functions/fnc_handleDamage.sqf index 1632a8f55b..c80f0c63e8 100644 --- a/addons/medical/functions/fnc_handleDamage.sqf +++ b/addons/medical/functions/fnc_handleDamage.sqf @@ -36,6 +36,12 @@ if !(_selection in (GVAR(SELECTIONS) + [""])) exitWith {0}; _damageReturn = _damage; if (GVAR(level) < 2) then { + if ([_unit] call EFUNC(isPlayer)) then { + _this set [2, _damage / (GVAR(playerDamageThreshold) max 0.01)]; + } else { + _this set [2, _damage / (GVAR(AIDamageThreshold) max 0.01)]; + }; + _damageReturn = _this call FUNC(handleDamage_basic); }; diff --git a/addons/medical/functions/fnc_setUnconscious.sqf b/addons/medical/functions/fnc_setUnconscious.sqf index 89ab5ee3b3..7fcfa0d24b 100644 --- a/addons/medical/functions/fnc_setUnconscious.sqf +++ b/addons/medical/functions/fnc_setUnconscious.sqf @@ -23,7 +23,7 @@ _set = if (count _this > 1) then {_this select 1} else {true}; _minWaitingTime = if (count _this > 2) then {_this select 2} else {DEFAULT_DELAY}; if !(_set) exitwith { - _unit setvariable ["ACE_isUnconscious", false,true]; + _unit setvariable ["ACE_isUnconscious", false, true]; }; if !(!(isNull _unit) && {(_unit isKindOf "CaManBase") && ([_unit] call EFUNC(common,isAwake))}) exitwith{}; @@ -40,6 +40,11 @@ if (_unit == ACE_player) then { closeDialog 0; }; +// if we have unconsciousness for AI disabled, we will kill the unit instead +if (!([_unit] call EFUNC(common,IsPlayer)) && (GVAR(enableUnsconsiousnessAI) == 0 || (GVAR(enableUnsconsiousnessAI) == 2 && random(1) <= 0.5))) exitwith { + [_unit, true] call FUNC(setDead); // force, to avoid getting into a loop in case revive is enabled. +}; + // If a unit has the launcher out, it will sometimes start selecting the primairy weapon while unconscious, // therefor we force it to select the primairy weapon before going unconscious if ((vehicle _unit) isKindOf "StaticWeapon") then { From 8b7e46c45f9421d2d87fefa19becf65e2c73aec0 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 20:26:28 +0200 Subject: [PATCH 13/59] fixes #656 --- addons/medical/functions/fnc_setUnconscious.sqf | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/addons/medical/functions/fnc_setUnconscious.sqf b/addons/medical/functions/fnc_setUnconscious.sqf index 7fcfa0d24b..c6a0e80c9b 100644 --- a/addons/medical/functions/fnc_setUnconscious.sqf +++ b/addons/medical/functions/fnc_setUnconscious.sqf @@ -91,6 +91,12 @@ _startingTime = time; _hasMovedOut = _args select 5; if (!alive _unit) exitwith { + [_unit, QGVAR(unconscious), false] call EFUNC(common,setCaptivityStatus); + [_unit, false] call EFUNC(common,disableAI); + _unit setUnitPos _originalPos; + _unit setUnconscious false; + ["medical_onUnconscious", [_unit, false]] call EFUNC(common,globalEvent); + [(_this select 1)] call cba_fnc_removePerFrameHandler; }; From 0234eedd54ac6d87203c1db89b85bbf3e4d8211f Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 20:33:13 +0200 Subject: [PATCH 14/59] Changed, only drop unit is player goes unconscious, otherwise keep carrying/dragging unit --- .../dragging/functions/fnc_handleUnconscious.sqf | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/addons/dragging/functions/fnc_handleUnconscious.sqf b/addons/dragging/functions/fnc_handleUnconscious.sqf index 41562756a2..31c703f37b 100644 --- a/addons/dragging/functions/fnc_handleUnconscious.sqf +++ b/addons/dragging/functions/fnc_handleUnconscious.sqf @@ -9,8 +9,6 @@ _isUnconscious = _this select 1; private "_player"; _player = ACE_player; -if ((_unit getHitPointDamage "HitLeftLeg") + (_unit getHitPointDamage "HitRightLeg") > 0.4) exitwith {}; - if (_player getVariable [QGVAR(isDragging), false]) then { private "_draggedObject"; @@ -22,9 +20,9 @@ if (_player getVariable [QGVAR(isDragging), false]) then { }; // handle waking up dragged unit - if (_unit == _draggedObject) then { - [_player, _draggedObject] call FUNC(dropObject); - }; + //if (_unit == _draggedObject) then { + // [_player, _draggedObject] call FUNC(dropObject); + //}; }; @@ -39,8 +37,8 @@ if (_player getVariable [QGVAR(isCarrying), false]) then { }; // handle waking up dragged unit - if (_unit == _carriedObject) then { - [_player, _carriedObject] call FUNC(dropObject_carry); - }; + //if (_unit == _carriedObject) then { + // [_player, _carriedObject] call FUNC(dropObject_carry); + //}; }; From 847ee7e2294312c1c48da0b0585388062241e642 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 20:38:02 +0200 Subject: [PATCH 15/59] Moved unconscious event, so it won't conflict in case the unit is still being carried --- addons/medical/functions/fnc_setUnconscious.sqf | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/addons/medical/functions/fnc_setUnconscious.sqf b/addons/medical/functions/fnc_setUnconscious.sqf index c6a0e80c9b..63be3fe5a0 100644 --- a/addons/medical/functions/fnc_setUnconscious.sqf +++ b/addons/medical/functions/fnc_setUnconscious.sqf @@ -118,6 +118,7 @@ _startingTime = time; // TODO: what if the unit switched vehicle? [_unit, _oldAnimation, 2] call EFUNC(common,doAnimation); }; + ["medical_onUnconscious", [_unit, false]] call EFUNC(common,globalEvent); // EXIT PFH [(_this select 1)] call cba_fnc_removePerFrameHandler; }; @@ -133,7 +134,7 @@ _startingTime = time; _unit setUnitPos _originalPos; // This is not position but stance (DOWN, MIDDLE, UP) _unit setUnconscious false; - ["medical_onUnconscious", [_unit, false]] call EFUNC(common,globalEvent); + // ensure this statement runs only once _args set [5, true]; }; From b333e6e662c7e1e8389a1fe3fa169c5dc449d23b Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 20:40:24 +0200 Subject: [PATCH 16/59] Keep units longer unconscious, instead of quickly fading in/out --- addons/medical/functions/fnc_handleUnitVitals.sqf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/medical/functions/fnc_handleUnitVitals.sqf b/addons/medical/functions/fnc_handleUnitVitals.sqf index 2b175d7ca2..411f64b49e 100644 --- a/addons/medical/functions/fnc_handleUnitVitals.sqf +++ b/addons/medical/functions/fnc_handleUnitVitals.sqf @@ -94,7 +94,7 @@ if (GVAR(level) >= 2) then { if ([_unit] call EFUNC(common,isAwake)) then { if (_bloodVolume < 60) then { if (random(1) > 0.9) then { - [_unit] call FUNC(setUnconscious); + [_unit, true, 15 + random(20)] call FUNC(setUnconscious); }; }; }; @@ -136,7 +136,7 @@ if (GVAR(level) >= 2) then { if (!(_unit getvariable [QGVAR(inCardiacArrest),false])) then { if (_heartRate < 10 || _bloodPressureH < 30 || _bloodVolume < 20) then { - [_unit] call FUNC(setUnconscious); // safety check to ensure unconsciousness for units if they are not dead already. + [_unit, true, 10+ random(20)] call FUNC(setUnconscious); // safety check to ensure unconsciousness for units if they are not dead already. }; if (_bloodPressureH > 260) then { From 80139521bcc030eb21e8eda97edebe0d80d93249 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 20:49:24 +0200 Subject: [PATCH 17/59] fixes #691 --- addons/medical/functions/fnc_handleDamage.sqf | 2 +- addons/medical/functions/fnc_setUnconscious.sqf | 12 ++++++++++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/addons/medical/functions/fnc_handleDamage.sqf b/addons/medical/functions/fnc_handleDamage.sqf index c80f0c63e8..876feae637 100644 --- a/addons/medical/functions/fnc_handleDamage.sqf +++ b/addons/medical/functions/fnc_handleDamage.sqf @@ -36,7 +36,7 @@ if !(_selection in (GVAR(SELECTIONS) + [""])) exitWith {0}; _damageReturn = _damage; if (GVAR(level) < 2) then { - if ([_unit] call EFUNC(isPlayer)) then { + if ([_unit] call EFUNC(common,isPlayer)) then { _this set [2, _damage / (GVAR(playerDamageThreshold) max 0.01)]; } else { _this set [2, _damage / (GVAR(AIDamageThreshold) max 0.01)]; diff --git a/addons/medical/functions/fnc_setUnconscious.sqf b/addons/medical/functions/fnc_setUnconscious.sqf index 63be3fe5a0..99651fc085 100644 --- a/addons/medical/functions/fnc_setUnconscious.sqf +++ b/addons/medical/functions/fnc_setUnconscious.sqf @@ -81,7 +81,7 @@ _unit setUnitPos "DOWN"; _startingTime = time; [{ - private ["_unit", "_vehicleOfUnit","_minWaitingTime", "_oldAnimation", "_captiveSwitch", "_hasMovedOut"]; + private ["_unit", "_vehicleOfUnit","_minWaitingTime", "_oldAnimation", "_captiveSwitch", "_hasMovedOut", "_parachuteCheck"]; _args = _this select 0; _unit = _args select 0; _oldAnimation = _args select 1; @@ -89,6 +89,7 @@ _startingTime = time; _startingTime = _args select 3; _minWaitingTime = _args select 4; _hasMovedOut = _args select 5; + _parachuteCheck = _args select 6; if (!alive _unit) exitwith { [_unit, QGVAR(unconscious), false] call EFUNC(common,setCaptivityStatus); @@ -140,6 +141,13 @@ _startingTime = time; }; }; + if (_parachuteCheck) then { + if !(vehicle _unit isKindOf "ParachuteBase") then { + [_unit, [_unit] call EFUNC(common,getDeathAnim), 1, true] call EFUNC(common,doAnimation); + _args set [6, false]; + }; + }; + // Ensure we are waiting at least a minimum period before checking if we can wake up the unit again, allows for temp knock outs if ((time - _startingTime) >= _minWaitingTime) exitwith { @@ -147,6 +155,6 @@ _startingTime = time; _unit setvariable ["ACE_isUnconscious", false, true]; }; }; -}, 0.1, [_unit,_animState, _originalPos, _startingTime, _minWaitingTime, false] ] call CBA_fnc_addPerFrameHandler; +}, 0.1, [_unit,_animState, _originalPos, _startingTime, _minWaitingTime, false, vehicle _unit isKindOf "ParachuteBase"] ] call CBA_fnc_addPerFrameHandler; ["medical_onUnconscious", [_unit, true]] call EFUNC(common,globalEvent); From 9b4435827ecfe5c29ac27ed1432880f784aaddfe Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 20:51:57 +0200 Subject: [PATCH 18/59] Added setting for unconscious animations on treatment --- addons/medical/ACE_Settings.hpp | 4 ++++ addons/medical/functions/fnc_treatment.sqf | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/addons/medical/ACE_Settings.hpp b/addons/medical/ACE_Settings.hpp index 56e5a531ec..0007352dda 100644 --- a/addons/medical/ACE_Settings.hpp +++ b/addons/medical/ACE_Settings.hpp @@ -124,4 +124,8 @@ class ACE_Settings { values[] = {"$STR_ACE_Medical_painEffect_Flash", "$STR_ACE_Medical_painEffect_Chroma"}; isClientSettable = 1; }; + class GVAR(allowUnconsciousAnimationOnTreatment) { + typeName = "BOOL"; + value = 0; + }; }; diff --git a/addons/medical/functions/fnc_treatment.sqf b/addons/medical/functions/fnc_treatment.sqf index e010279be1..bb291d6c98 100644 --- a/addons/medical/functions/fnc_treatment.sqf +++ b/addons/medical/functions/fnc_treatment.sqf @@ -129,7 +129,7 @@ if (isNil _callbackProgress) then { // Patient Animation _patientAnim = getText (_config >> "animationPatient"); -if (_target getvariable ["ACE_isUnconscious", false]) then { +if (_target getvariable ["ACE_isUnconscious", false] && GVAR(allowUnconsciousAnimationOnTreatment)) then { if !(animationState _target in (getArray (_config >> "animationPatientUnconsciousExcludeOn"))) then { _patientAnim = getText (_config >> "animationPatientUnconscious"); }; From 8bfb76c9651cc4e34fea01cdaaaa8a9996691540 Mon Sep 17 00:00:00 2001 From: ViperMaul Date: Fri, 17 Apr 2015 12:05:49 -0700 Subject: [PATCH 19/59] #552 - Default: don't check external files --- tools/make.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/tools/make.py b/tools/make.py index 29cf3f1956..4af9341b6b 100644 --- a/tools/make.py +++ b/tools/make.py @@ -321,6 +321,7 @@ make.py [help] [test] [force] [key ] [target ] [release ] test -- Copy result to Arma 3. release -- Make archive with . force -- Ignore cache and build all. +checkexternal -- Check External Files target -- Use rules in make.cfg under heading [] rather than default [Make] key -- Use key in working directory with to sign. If it does not @@ -378,6 +379,12 @@ See the make.cfg file for additional build options. quiet = True argv.remove("quiet") + if "checkexternal" in argv: + argv.remove("checkexternal") + check_external = True + else: + check_external = False + # Get the directory the make script is in. make_root = os.path.dirname(os.path.realpath(__file__)) make_root_parent = os.path.abspath(os.path.join(os.getcwd(), os.pardir)) @@ -658,8 +665,12 @@ See the make.cfg file for additional build options. cmd = [makepboTool, "-P","-A","-L","-N","-G", os.path.join(work_drive, prefix, module),os.path.join(module_root, release_dir, project,"Addons")] else: - cmd = [pboproject, "-P", os.path.join(work_drive, prefix, module), "+Engine=Arma3", "-S","+Noisy", "+X", "+Clean", "+Mod="+os.path.join(module_root, release_dir, project), "-Key"] + if check_external: + cmd = [pboproject, "-P", os.path.join(work_drive, prefix, module), "+Engine=Arma3", "-S","+Noisy", "+X", "+Clean", "+Mod="+os.path.join(module_root, release_dir, project), "-Key"] + else: + cmd = [pboproject, "-P", os.path.join(work_drive, prefix, module), "+Engine=Arma3", "-S","+Noisy", "-X", "+Clean", "+Mod="+os.path.join(module_root, release_dir, project), "-Key"] + print_yellow(cmd) color("grey") if quiet: devnull = open(os.devnull, 'w') From 31bc09a9a32d0135144cd029cb83a04d8ae75fba Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 21:06:30 +0200 Subject: [PATCH 20/59] fixed AI standing up before being killed Doesn't matter if we enable AI again on dead units --- addons/common/functions/fnc_disableAI.sqf | 2 +- addons/medical/functions/fnc_setUnconscious.sqf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/common/functions/fnc_disableAI.sqf b/addons/common/functions/fnc_disableAI.sqf index 92ad35c0f9..0e1985eced 100644 --- a/addons/common/functions/fnc_disableAI.sqf +++ b/addons/common/functions/fnc_disableAI.sqf @@ -27,7 +27,7 @@ if ((local _unit) && {!([_unit] call EFUNC(common,isPlayer))}) then { _unit disableConversation true; } else { //Sanity check to make sure we don't enable unconsious AI - if (_unit getVariable ["ace_isunconscious", false]) exitWith {ERROR("Enabling AI for unconsious unit");}; + if (_unit getVariable ["ace_isunconscious", false] && alive _unit) exitWith {ERROR("Enabling AI for unconsious unit");}; _unit enableAI "MOVE"; _unit enableAI "TARGET"; _unit enableAI "AUTOTARGET"; diff --git a/addons/medical/functions/fnc_setUnconscious.sqf b/addons/medical/functions/fnc_setUnconscious.sqf index 99651fc085..3ef4df4d3f 100644 --- a/addons/medical/functions/fnc_setUnconscious.sqf +++ b/addons/medical/functions/fnc_setUnconscious.sqf @@ -94,7 +94,7 @@ _startingTime = time; if (!alive _unit) exitwith { [_unit, QGVAR(unconscious), false] call EFUNC(common,setCaptivityStatus); [_unit, false] call EFUNC(common,disableAI); - _unit setUnitPos _originalPos; + //_unit setUnitPos _originalPos; _unit setUnconscious false; ["medical_onUnconscious", [_unit, false]] call EFUNC(common,globalEvent); From eb731b116939cf81289dcff585ad87ea77119e62 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 21:07:09 +0200 Subject: [PATCH 21/59] fixes #653 --- addons/medical/functions/fnc_treatment.sqf | 2 ++ addons/medical/functions/fnc_treatment_failure.sqf | 9 ++++++++- addons/medical/functions/fnc_treatment_success.sqf | 9 ++++++++- 3 files changed, 18 insertions(+), 2 deletions(-) diff --git a/addons/medical/functions/fnc_treatment.sqf b/addons/medical/functions/fnc_treatment.sqf index bb291d6c98..df6cc173d0 100644 --- a/addons/medical/functions/fnc_treatment.sqf +++ b/addons/medical/functions/fnc_treatment.sqf @@ -149,6 +149,8 @@ if (_caller == _target) then { _callerAnim = [getText (_config >> "animationCallerSelf"), getText (_config >> "animationCallerSelfProne")] select (stance _caller == "PRONE"); }; +_caller setvariable [QGVAR(selectedWeaponOnTreatment), currentWeapon _caller]; + // Cannot use secondairy weapon for animation if (currentWeapon _caller == secondaryWeapon _caller) then { _caller selectWeapon (primaryWeapon _caller); diff --git a/addons/medical/functions/fnc_treatment_failure.sqf b/addons/medical/functions/fnc_treatment_failure.sqf index d4f853374c..fe8bafb0c7 100644 --- a/addons/medical/functions/fnc_treatment_failure.sqf +++ b/addons/medical/functions/fnc_treatment_failure.sqf @@ -17,7 +17,7 @@ #include "script_component.hpp" -private ["_caller", "_target","_selectionName","_className","_config","_callback", "_usersOfItems"]; +private ["_caller", "_target","_selectionName","_className","_config","_callback", "_usersOfItems", "_weaponSelect"]; _args = _this select 0; _caller = _args select 0; @@ -34,6 +34,13 @@ if (vehicle _caller == _caller) then { }; _caller setvariable [QGVAR(treatmentPrevAnimCaller), nil]; +_weaponSelect = (_caller getvariable [QGVAR(selectedWeaponOnTreatment), ""]); +if (_weaponSelect != "") then { + _caller selectWeapon _weaponSelect; +} else { + _caller action ["SwitchWeapon", _caller, _caller, 99]; +}; + { (_x select 0) addItem (_x select 1); }foreach _usersOfItems; diff --git a/addons/medical/functions/fnc_treatment_success.sqf b/addons/medical/functions/fnc_treatment_success.sqf index 5910a4be86..6822f674c7 100644 --- a/addons/medical/functions/fnc_treatment_success.sqf +++ b/addons/medical/functions/fnc_treatment_success.sqf @@ -17,7 +17,7 @@ #include "script_component.hpp" -private ["_caller", "_target","_selectionName","_className","_config","_callback"]; +private ["_caller", "_target","_selectionName","_className","_config","_callback", "_weaponSelect"]; _args = _this select 0; _caller = _args select 0; _target = _args select 1; @@ -32,6 +32,13 @@ if (vehicle _caller == _caller) then { }; _caller setvariable [QGVAR(treatmentPrevAnimCaller), nil]; +_weaponSelect = (_caller getvariable [QGVAR(selectedWeaponOnTreatment), ""]); +if (_weaponSelect != "") then { + _caller selectWeapon _weaponSelect; +} else { + _caller action ["SwitchWeapon", _caller, _caller, 99]; +}; + // Record specific callback _config = (configFile >> "ACE_Medical_Actions" >> "Basic" >> _className); if (GVAR(level) >= 2) then { From e816907c503c88cedce17a26946cafb4901a458b Mon Sep 17 00:00:00 2001 From: ViperMaul Date: Fri, 17 Apr 2015 12:21:32 -0700 Subject: [PATCH 22/59] #552 - Tab clean up --- tools/make.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/make.py b/tools/make.py index 4af9341b6b..166d21c49d 100644 --- a/tools/make.py +++ b/tools/make.py @@ -665,10 +665,10 @@ See the make.cfg file for additional build options. cmd = [makepboTool, "-P","-A","-L","-N","-G", os.path.join(work_drive, prefix, module),os.path.join(module_root, release_dir, project,"Addons")] else: - if check_external: - cmd = [pboproject, "-P", os.path.join(work_drive, prefix, module), "+Engine=Arma3", "-S","+Noisy", "+X", "+Clean", "+Mod="+os.path.join(module_root, release_dir, project), "-Key"] - else: - cmd = [pboproject, "-P", os.path.join(work_drive, prefix, module), "+Engine=Arma3", "-S","+Noisy", "-X", "+Clean", "+Mod="+os.path.join(module_root, release_dir, project), "-Key"] + if check_external: + cmd = [pboproject, "-P", os.path.join(work_drive, prefix, module), "+Engine=Arma3", "-S","+Noisy", "+X", "+Clean", "+Mod="+os.path.join(module_root, release_dir, project), "-Key"] + else: + cmd = [pboproject, "-P", os.path.join(work_drive, prefix, module), "+Engine=Arma3", "-S","+Noisy", "-X", "+Clean", "+Mod="+os.path.join(module_root, release_dir, project), "-Key"] print_yellow(cmd) color("grey") From 008c36ac763de4036389469d9edf405b81099d4c Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 21:27:57 +0200 Subject: [PATCH 23/59] fixes #699 --- addons/medical/XEH_preInit.sqf | 1 + addons/medical/functions/fnc_handleLocal.sqf | 10 ++ .../medical/functions/fnc_setUnconscious.sqf | 77 +-------------- .../medical/functions/fnc_unconsciousPFH.sqf | 93 +++++++++++++++++++ 4 files changed, 105 insertions(+), 76 deletions(-) create mode 100644 addons/medical/functions/fnc_unconsciousPFH.sqf diff --git a/addons/medical/XEH_preInit.sqf b/addons/medical/XEH_preInit.sqf index f15b4ec109..a54b6d0d8f 100644 --- a/addons/medical/XEH_preInit.sqf +++ b/addons/medical/XEH_preInit.sqf @@ -97,6 +97,7 @@ PREP(moduleAssignMedicalFacility); PREP(moduleTreatmentConfiguration); PREP(copyDeadBody); PREP(requestWoundSync); +PREP(unconsciousPFH); GVAR(injuredUnitCollection) = []; GVAR(IVBags) = []; diff --git a/addons/medical/functions/fnc_handleLocal.sqf b/addons/medical/functions/fnc_handleLocal.sqf index 5d9c5865a4..5a6123d9f7 100644 --- a/addons/medical/functions/fnc_handleLocal.sqf +++ b/addons/medical/functions/fnc_handleLocal.sqf @@ -22,4 +22,14 @@ if (_local) then { if (_unit getvariable[QGVAR(addedToUnitLoop),false]) then { [_unit, true] call FUNC(addToInjuredCollection); }; + + if (count (_unit getvariable [QGVAR(unconsciousArguments), []]) >= 7) then { + private "_arguments"; + _arguments = (_unit getvariable [QGVAR(unconsciousArguments), []]); + _arguments set [ 3, time]; + + [DFUNC(unconsciousPFH), 0.1, _arguments ] call CBA_fnc_addPerFrameHandler; + + _unit setvariable [QGVAR(unconsciousArguments), nil, true]; + }; }; diff --git a/addons/medical/functions/fnc_setUnconscious.sqf b/addons/medical/functions/fnc_setUnconscious.sqf index 3ef4df4d3f..ef9ccb246d 100644 --- a/addons/medical/functions/fnc_setUnconscious.sqf +++ b/addons/medical/functions/fnc_setUnconscious.sqf @@ -80,81 +80,6 @@ _unit setUnitPos "DOWN"; _startingTime = time; -[{ - private ["_unit", "_vehicleOfUnit","_minWaitingTime", "_oldAnimation", "_captiveSwitch", "_hasMovedOut", "_parachuteCheck"]; - _args = _this select 0; - _unit = _args select 0; - _oldAnimation = _args select 1; - _originalPos = _args select 2; - _startingTime = _args select 3; - _minWaitingTime = _args select 4; - _hasMovedOut = _args select 5; - _parachuteCheck = _args select 6; - - if (!alive _unit) exitwith { - [_unit, QGVAR(unconscious), false] call EFUNC(common,setCaptivityStatus); - [_unit, false] call EFUNC(common,disableAI); - //_unit setUnitPos _originalPos; - _unit setUnconscious false; - ["medical_onUnconscious", [_unit, false]] call EFUNC(common,globalEvent); - - [(_this select 1)] call cba_fnc_removePerFrameHandler; - }; - - // In case the unit is no longer in an unconscious state, we are going to check if we can already reset the animation - if !(_unit getvariable ["ACE_isUnconscious",false]) exitwith { - - // TODO, handle this with carry instead, so we can remove the PFH here. - // Wait until the unit isn't being carried anymore, so we won't end up with wierd animations - if !(([_unit] call FUNC(isBeingCarried)) || ([_unit] call FUNC(isBeingDragged))) then { - if (vehicle _unit == _unit) then { - if (animationState _unit == "AinjPpneMstpSnonWrflDnon") then { - [_unit,"AinjPpneMstpSnonWrflDnon_rolltofront", 2] call EFUNC(common,doAnimation); - [_unit,"amovppnemstpsnonwnondnon", 1] call EFUNC(common,doAnimation); - } else { - [_unit,"amovppnemstpsnonwnondnon", 2] call EFUNC(common,doAnimation); - }; - } else { - // Switch to the units original animation, assuming - // TODO: what if the unit switched vehicle? - [_unit, _oldAnimation, 2] call EFUNC(common,doAnimation); - }; - ["medical_onUnconscious", [_unit, false]] call EFUNC(common,globalEvent); - // EXIT PFH - [(_this select 1)] call cba_fnc_removePerFrameHandler; - }; - if (!_hasMovedOut) then { - // Reset the unit back to the previous captive state. - [_unit, QGVAR(unconscious), false] call EFUNC(common,setCaptivityStatus); - - // Swhich the unit back to its original group - //Unconscious units shouldn't be put in another group #527: - // [_unit, false, "ACE_isUnconscious", side group _unit] call EFUNC(common,switchToGroupSide); - - [_unit, false] call EFUNC(common,disableAI); - _unit setUnitPos _originalPos; // This is not position but stance (DOWN, MIDDLE, UP) - - _unit setUnconscious false; - - // ensure this statement runs only once - _args set [5, true]; - }; - }; - - if (_parachuteCheck) then { - if !(vehicle _unit isKindOf "ParachuteBase") then { - [_unit, [_unit] call EFUNC(common,getDeathAnim), 1, true] call EFUNC(common,doAnimation); - _args set [6, false]; - }; - }; - - // Ensure we are waiting at least a minimum period before checking if we can wake up the unit again, allows for temp knock outs - if ((time - _startingTime) >= _minWaitingTime) exitwith { - - if (!([_unit] call FUNC(getUnconsciousCondition))) then { - _unit setvariable ["ACE_isUnconscious", false, true]; - }; - }; -}, 0.1, [_unit,_animState, _originalPos, _startingTime, _minWaitingTime, false, vehicle _unit isKindOf "ParachuteBase"] ] call CBA_fnc_addPerFrameHandler; +[DFUNC(unconsciousPFH), 0.1, [_unit,_animState, _originalPos, _startingTime, _minWaitingTime, false, vehicle _unit isKindOf "ParachuteBase"] ] call CBA_fnc_addPerFrameHandler; ["medical_onUnconscious", [_unit, true]] call EFUNC(common,globalEvent); diff --git a/addons/medical/functions/fnc_unconsciousPFH.sqf b/addons/medical/functions/fnc_unconsciousPFH.sqf new file mode 100644 index 0000000000..406d0278c1 --- /dev/null +++ b/addons/medical/functions/fnc_unconsciousPFH.sqf @@ -0,0 +1,93 @@ +/* + * Author: Glowbal + * PFH logic for unconscious state + * + * Arguments: + * 0: The unit that will be put in an unconscious state + * + * ReturnValue: + * nil + * + * Public: yes + */ + +#include "script_component.hpp" + +private ["_unit", "_vehicleOfUnit","_minWaitingTime", "_oldAnimation", "_captiveSwitch", "_hasMovedOut", "_parachuteCheck"]; +_args = _this select 0; +_unit = _args select 0; +_oldAnimation = _args select 1; +_originalPos = _args select 2; +_startingTime = _args select 3; +_minWaitingTime = _args select 4; +_hasMovedOut = _args select 5; +_parachuteCheck = _args select 6; + +if (!alive _unit) exitwith { + [_unit, QGVAR(unconscious), false] call EFUNC(common,setCaptivityStatus); + [_unit, false] call EFUNC(common,disableAI); + //_unit setUnitPos _originalPos; + _unit setUnconscious false; + ["medical_onUnconscious", [_unit, false]] call EFUNC(common,globalEvent); + + [(_this select 1)] call cba_fnc_removePerFrameHandler; +}; + +// In case the unit is no longer in an unconscious state, we are going to check if we can already reset the animation +if !(_unit getvariable ["ACE_isUnconscious",false]) exitwith { + // TODO, handle this with carry instead, so we can remove the PFH here. + // Wait until the unit isn't being carried anymore, so we won't end up with wierd animations + if !(([_unit] call FUNC(isBeingCarried)) || ([_unit] call FUNC(isBeingDragged))) then { + if (vehicle _unit == _unit) then { + if (animationState _unit == "AinjPpneMstpSnonWrflDnon") then { + [_unit,"AinjPpneMstpSnonWrflDnon_rolltofront", 2] call EFUNC(common,doAnimation); + [_unit,"amovppnemstpsnonwnondnon", 1] call EFUNC(common,doAnimation); + } else { + [_unit,"amovppnemstpsnonwnondnon", 2] call EFUNC(common,doAnimation); + }; + } else { + // Switch to the units original animation, assuming + // TODO: what if the unit switched vehicle? + [_unit, _oldAnimation, 2] call EFUNC(common,doAnimation); + }; + ["medical_onUnconscious", [_unit, false]] call EFUNC(common,globalEvent); + // EXIT PFH + [(_this select 1)] call cba_fnc_removePerFrameHandler; + }; + if (!_hasMovedOut) then { + // Reset the unit back to the previous captive state. + [_unit, QGVAR(unconscious), false] call EFUNC(common,setCaptivityStatus); + + // Swhich the unit back to its original group + //Unconscious units shouldn't be put in another group #527: + // [_unit, false, "ACE_isUnconscious", side group _unit] call EFUNC(common,switchToGroupSide); + + [_unit, false] call EFUNC(common,disableAI); + _unit setUnitPos _originalPos; // This is not position but stance (DOWN, MIDDLE, UP) + + _unit setUnconscious false; + + // ensure this statement runs only once + _args set [5, true]; + }; +}; + +if (_parachuteCheck) then { + if !(vehicle _unit isKindOf "ParachuteBase") then { + [_unit, [_unit] call EFUNC(common,getDeathAnim), 1, true] call EFUNC(common,doAnimation); + _args set [6, false]; + }; +}; + +if (!local _unit) exitwith { + _args set [ 4, _minWaitingTime - (time - _startingTime)]; + _unit setvariable [QGVAR(unconsciousArguments), _args, true]; + [(_this select 1)] call cba_fnc_removePerFrameHandler; +}; + +// Ensure we are waiting at least a minimum period before checking if we can wake up the unit again, allows for temp knock outs +if ((time - _startingTime) >= _minWaitingTime) exitwith { + if (!([_unit] call FUNC(getUnconsciousCondition))) then { + _unit setvariable ["ACE_isUnconscious", false, true]; + }; +}; From fa7bb5f9c64b51e2c5eb9e0a0598c2ea20334e07 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 21:28:47 +0200 Subject: [PATCH 24/59] Added unconscious state check --- addons/medical/functions/fnc_handleLocal.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/functions/fnc_handleLocal.sqf b/addons/medical/functions/fnc_handleLocal.sqf index 5a6123d9f7..98b390b51a 100644 --- a/addons/medical/functions/fnc_handleLocal.sqf +++ b/addons/medical/functions/fnc_handleLocal.sqf @@ -23,7 +23,7 @@ if (_local) then { [_unit, true] call FUNC(addToInjuredCollection); }; - if (count (_unit getvariable [QGVAR(unconsciousArguments), []]) >= 7) then { + if ((_unit getvariable ["ACE_isUnconscious",false]) && {count (_unit getvariable [QGVAR(unconsciousArguments), []]) >= 7}) then { private "_arguments"; _arguments = (_unit getvariable [QGVAR(unconsciousArguments), []]); _arguments set [ 3, time]; From 0e858be1b17cdbe1a749887afe567f81bd441c63 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 22:00:07 +0200 Subject: [PATCH 25/59] Changed conditions for body parts are now always true. This way the medical information is always available, and should help a bit with performance as well. --- addons/medical/ACE_Medical_Actions.hpp | 6 ++++++ addons/medical/ACE_Medical_SelfActions.hpp | 7 +++++++ 2 files changed, 13 insertions(+) diff --git a/addons/medical/ACE_Medical_Actions.hpp b/addons/medical/ACE_Medical_Actions.hpp index 036dd5e9d9..3acc53cf05 100644 --- a/addons/medical/ACE_Medical_Actions.hpp +++ b/addons/medical/ACE_Medical_Actions.hpp @@ -3,6 +3,7 @@ class ACE_Head { displayName = "$STR_ACE_Interaction_Head"; runOnHover = 1; statement = QUOTE([ARR_3(_target, true, 0)] call DFUNC(displayPatientInformation)); + condition = "true"; EXCEPTIONS icon = PATHTOF(UI\icons\medical_cross.paa); distance = MEDICAL_ACTION_DISTANCE; @@ -74,6 +75,7 @@ class ACE_Torso { displayName = "$STR_ACE_Interaction_Torso"; runOnHover = 1; statement = QUOTE([ARR_3(_target, true, 1)] call DFUNC(displayPatientInformation)); + condition = "true"; EXCEPTIONS icon = PATHTOF(UI\icons\medical_cross.paa); distance = MEDICAL_ACTION_DISTANCE; @@ -173,6 +175,7 @@ class ACE_ArmLeft { displayName = "$STR_ACE_Interaction_ArmLeft"; runOnHover = 1; statement = QUOTE([ARR_3(_target, true, 2)] call DFUNC(displayPatientInformation)); + condition = "true"; EXCEPTIONS icon = PATHTOF(UI\icons\medical_cross.paa); distance = MEDICAL_ACTION_DISTANCE; @@ -329,6 +332,7 @@ class ACE_ArmRight { displayName = "$STR_ACE_Interaction_ArmRight"; runOnHover = 1; statement = QUOTE([ARR_3(_target, true, 3)] call DFUNC(displayPatientInformation)); + condition = "true"; EXCEPTIONS icon = PATHTOF(UI\icons\medical_cross.paa); distance = MEDICAL_ACTION_DISTANCE; @@ -482,6 +486,7 @@ class ACE_LegLeft { displayName = "$STR_ACE_Interaction_LegLeft"; runOnHover = 1; statement = QUOTE([ARR_3(_target, true, 4)] call DFUNC(displayPatientInformation)); + condition = "true"; EXCEPTIONS icon = PATHTOF(UI\icons\medical_cross.paa); distance = MEDICAL_ACTION_DISTANCE; @@ -623,6 +628,7 @@ class ACE_LegRight { displayName = "$STR_ACE_Interaction_LegRight"; runOnHover = 1; statement = QUOTE([ARR_3(_target, true, 5)] call DFUNC(displayPatientInformation)); + condition = "true"; EXCEPTIONS icon = PATHTOF(UI\icons\medical_cross.paa); distance = MEDICAL_ACTION_DISTANCE; diff --git a/addons/medical/ACE_Medical_SelfActions.hpp b/addons/medical/ACE_Medical_SelfActions.hpp index c2a60898f4..e31e99ad01 100644 --- a/addons/medical/ACE_Medical_SelfActions.hpp +++ b/addons/medical/ACE_Medical_SelfActions.hpp @@ -4,6 +4,7 @@ class Medical { hotkey = "M"; exceptions[] = {"isNotInside"}; statement = QUOTE([ARR_3(_target, true, 0)] call DFUNC(displayPatientInformation)); + condition = "true"; icon = PATHTOF(UI\icons\medical_cross.paa); class ACE_Head { @@ -11,6 +12,7 @@ class Medical { icon = PATHTOF(UI\icons\medical_cross.paa); exceptions[] = {"isNotInside"}; statement = QUOTE([ARR_3(_target, true, 0)] call DFUNC(displayPatientInformation)); + condition = "true"; runOnHover = 1; class Bandage { @@ -78,6 +80,7 @@ class Medical { runOnHover = 1; exceptions[] = {"isNotInside"}; statement = QUOTE([ARR_3(_target, true, 1)] call DFUNC(displayPatientInformation)); + condition = "true"; showDisabled = 1; priority = 2; hotkey = ""; @@ -146,6 +149,7 @@ class Medical { runOnHover = 1; exceptions[] = {"isNotInside"}; statement = QUOTE([ARR_3(_target, true, 2)] call DFUNC(displayPatientInformation)); + condition = "true"; icon = PATHTOF(UI\icons\medical_cross.paa); class Bandage { @@ -246,6 +250,7 @@ class Medical { runOnHover = 1; exceptions[] = {"isNotInside"}; statement = QUOTE([ARR_3(_target, true, 3)] call DFUNC(displayPatientInformation)); + condition = "true"; icon = PATHTOF(UI\icons\medical_cross.paa); class Bandage { @@ -342,6 +347,7 @@ class Medical { runOnHover = 1; exceptions[] = {"isNotInside"}; statement = QUOTE([ARR_3(_target, true, 4)] call DFUNC(displayPatientInformation)); + condition = "true"; icon = PATHTOF(UI\icons\medical_cross.paa); class Bandage { @@ -427,6 +433,7 @@ class Medical { runOnHover = 1; exceptions[] = {"isNotInside"}; statement = QUOTE([ARR_3(_target, true, 5)] call DFUNC(displayPatientInformation)); + condition = "true"; icon = PATHTOF(UI\icons\medical_cross.paa); class Bandage { From 6d18e484c148aa3e4e783e8ec6b2066e81b98b81 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 22:02:43 +0200 Subject: [PATCH 26/59] Cache condition for target instead of caller --- addons/medical/functions/fnc_canTreatCached.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/functions/fnc_canTreatCached.sqf b/addons/medical/functions/fnc_canTreatCached.sqf index 34d753b119..b1dfaf7d12 100644 --- a/addons/medical/functions/fnc_canTreatCached.sqf +++ b/addons/medical/functions/fnc_canTreatCached.sqf @@ -19,4 +19,4 @@ #define MAX_DURATION_CACHE 2 // parameters, function, namespace, uid -[_this, DFUNC(canTreat), _this select 0, format[QGVAR(canTreat_%1_%2), _this select 2, _this select 3], MAX_DURATION_CACHE, "clearConditionCaches"] call EFUNC(common,cachedCall); +[_this, DFUNC(canTreat), _this select 1, format[QGVAR(canTreat_%1_%2), _this select 2, _this select 3], MAX_DURATION_CACHE, "clearConditionCaches"] call EFUNC(common,cachedCall); From f5effca21636f18ebbcaef1f48bbb5eac9d7f6b1 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 22:21:15 +0200 Subject: [PATCH 27/59] fixed handleDamage basic --- addons/medical/functions/fnc_handleDamage.sqf | 6 ------ addons/medical/functions/fnc_handleDamage_basic.sqf | 6 ++++++ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/addons/medical/functions/fnc_handleDamage.sqf b/addons/medical/functions/fnc_handleDamage.sqf index 876feae637..1632a8f55b 100644 --- a/addons/medical/functions/fnc_handleDamage.sqf +++ b/addons/medical/functions/fnc_handleDamage.sqf @@ -36,12 +36,6 @@ if !(_selection in (GVAR(SELECTIONS) + [""])) exitWith {0}; _damageReturn = _damage; if (GVAR(level) < 2) then { - if ([_unit] call EFUNC(common,isPlayer)) then { - _this set [2, _damage / (GVAR(playerDamageThreshold) max 0.01)]; - } else { - _this set [2, _damage / (GVAR(AIDamageThreshold) max 0.01)]; - }; - _damageReturn = _this call FUNC(handleDamage_basic); }; diff --git a/addons/medical/functions/fnc_handleDamage_basic.sqf b/addons/medical/functions/fnc_handleDamage_basic.sqf index aa9c2f61df..6e343b127a 100644 --- a/addons/medical/functions/fnc_handleDamage_basic.sqf +++ b/addons/medical/functions/fnc_handleDamage_basic.sqf @@ -63,6 +63,12 @@ if (_selectionName in GVAR(SELECTIONS)) then { _newDamage = _damage - (_unit getHitPointDamage (GVAR(HITPOINTS) select (GVAR(SELECTIONS) find _selectionName))); }; +if ([_unit] call EFUNC(common,isPlayer)) then { + _newDamage = _newDamage / (GVAR(playerDamageThreshold) max 0.01); +} else { + _newDamage = _newDamage / (GVAR(AIDamageThreshold) max 0.01); +}; + _damage = _damage - _newDamage; From 9670267d2001cf7bd8aeb61f65546d250a2e3f63 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 22:21:54 +0200 Subject: [PATCH 28/59] Fixed wrong classnames for IV treatments --- addons/medical/ACE_Medical_Actions.hpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/addons/medical/ACE_Medical_Actions.hpp b/addons/medical/ACE_Medical_Actions.hpp index 3acc53cf05..ed5670f814 100644 --- a/addons/medical/ACE_Medical_Actions.hpp +++ b/addons/medical/ACE_Medical_Actions.hpp @@ -427,8 +427,8 @@ class ACE_ArmRight { }; class PlasmaIV: BloodIV { displayName = "$STR_ACE_MEDICAL_ACTIONS_Plasma4_1000"; - condition = QUOTE([ARR_4(_player, _target, 'hand_r', 'BloodIV')] call DFUNC(canTreatCached)); - statement = QUOTE([ARR_4(_player, _target, 'hand_r', 'BloodIV')] call DFUNC(treatment)); + condition = QUOTE([ARR_4(_player, _target, 'hand_r', 'PlasmaIV')] call DFUNC(canTreatCached)); + statement = QUOTE([ARR_4(_player, _target, 'hand_r', 'PlasmaIV')] call DFUNC(treatment)); EXCEPTIONS }; class PlasmaIV_500: PlasmaIV { @@ -583,8 +583,8 @@ class ACE_LegLeft { }; class PlasmaIV: BloodIV { displayName = "$STR_ACE_MEDICAL_ACTIONS_Plasma4_1000"; - condition = QUOTE([ARR_4(_player, _target, 'leg_l', 'BloodIV')] call DFUNC(canTreatCached)); - statement = QUOTE([ARR_4(_player, _target, 'leg_l', 'BloodIV')] call DFUNC(treatment)); + condition = QUOTE([ARR_4(_player, _target, 'leg_l', 'PlasmaIV')] call DFUNC(canTreatCached)); + statement = QUOTE([ARR_4(_player, _target, 'leg_l', 'PlasmaIV')] call DFUNC(treatment)); EXCEPTIONS }; class PlasmaIV_500: PlasmaIV { @@ -724,8 +724,8 @@ class ACE_LegRight { }; class PlasmaIV: BloodIV { displayName = "$STR_ACE_MEDICAL_ACTIONS_Plasma4_1000"; - condition = QUOTE([ARR_4(_player, _target, 'leg_r', 'BloodIV')] call DFUNC(canTreatCached)); - statement = QUOTE([ARR_4(_player, _target, 'leg_r', 'BloodIV')] call DFUNC(treatment)); + condition = QUOTE([ARR_4(_player, _target, 'leg_r', 'PlasmaIV')] call DFUNC(canTreatCached)); + statement = QUOTE([ARR_4(_player, _target, 'leg_r', 'PlasmaIV')] call DFUNC(treatment)); EXCEPTIONS }; class PlasmaIV_500: PlasmaIV { From cbc3584f9d6624f8e4bba525c0632d98b0d57e04 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 22:24:42 +0200 Subject: [PATCH 29/59] removed duplicate condition attribute --- addons/medical/ACE_Medical_SelfActions.hpp | 1 - 1 file changed, 1 deletion(-) diff --git a/addons/medical/ACE_Medical_SelfActions.hpp b/addons/medical/ACE_Medical_SelfActions.hpp index e31e99ad01..9c79503f3d 100644 --- a/addons/medical/ACE_Medical_SelfActions.hpp +++ b/addons/medical/ACE_Medical_SelfActions.hpp @@ -80,7 +80,6 @@ class Medical { runOnHover = 1; exceptions[] = {"isNotInside"}; statement = QUOTE([ARR_3(_target, true, 1)] call DFUNC(displayPatientInformation)); - condition = "true"; showDisabled = 1; priority = 2; hotkey = ""; From bc4d102d0890023f59bfea846bc4cdc85651f92b Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 22:43:31 +0200 Subject: [PATCH 30/59] changed variable initialization - everything is now done local --- addons/medical/XEH_init.sqf | 5 +-- addons/medical/XEH_respawn.sqf | 3 +- addons/medical/functions/fnc_init.sqf | 49 ++++++++++++++------------- 3 files changed, 28 insertions(+), 29 deletions(-) diff --git a/addons/medical/XEH_init.sqf b/addons/medical/XEH_init.sqf index 2f840fe950..f3fb2b1e93 100644 --- a/addons/medical/XEH_init.sqf +++ b/addons/medical/XEH_init.sqf @@ -4,7 +4,4 @@ private ["_unit"]; _unit = _this select 0; _unit addEventHandler ["HandleDamage", {_this call FUNC(handleDamage)}]; - -if (local _unit) then { - [_unit] call FUNC(init); -}; +[_unit] call FUNC(init); diff --git a/addons/medical/XEH_respawn.sqf b/addons/medical/XEH_respawn.sqf index b2101b1d4e..5047f0026c 100644 --- a/addons/medical/XEH_respawn.sqf +++ b/addons/medical/XEH_respawn.sqf @@ -6,8 +6,7 @@ _unit = _this select 0; if !(local _unit) exitWith {}; -diag_log "running respawn"; -[_unit] call FUNC(init); +[_unit, true] call FUNC(init); //Reset captive status for respawning unit if (!(_unit getVariable ["ACE_isUnconscious", false])) then { diff --git a/addons/medical/functions/fnc_init.sqf b/addons/medical/functions/fnc_init.sqf index fa6aa357c2..0147b99204 100644 --- a/addons/medical/functions/fnc_init.sqf +++ b/addons/medical/functions/fnc_init.sqf @@ -13,21 +13,24 @@ #include "script_component.hpp" -private ["_unit", "_allUsedMedication", "_logs"]; +private ["_unit", "_allUsedMedication", "_logs", "_forceNew"]; _unit = _this select 0; +_forceNew = if (count _this > 1) then {_this select 1} else {false}; -_unit setVariable [QGVAR(pain), 0, true]; -_unit setVariable [QGVAR(morphine), 0, true]; -_unit setVariable [QGVAR(bloodVolume), 100, true]; +if (!(isnil {_unit getvariable QGVAR(triageLevel)}) && !_forceNew) exitwith {}; + +_unit setVariable [QGVAR(pain), 0]; +_unit setVariable [QGVAR(morphine), 0]; +_unit setVariable [QGVAR(bloodVolume), 100]; // tourniquets -_unit setvariable [QGVAR(tourniquets), [0,0,0,0,0,0], true]; +_unit setvariable [QGVAR(tourniquets), [0,0,0,0,0,0]]; // wounds and injuries -_unit setvariable [QGVAR(openWounds), [], true]; -_unit setvariable [QGVAR(bandagedWounds), [], true]; -_unit setVariable [QGVAR(internalWounds), [], true]; +_unit setvariable [QGVAR(openWounds), []]; +_unit setvariable [QGVAR(bandagedWounds), []]; +_unit setVariable [QGVAR(internalWounds), []]; _unit setvariable [QGVAR(lastUniqueWoundID), 1]; // vitals @@ -40,8 +43,8 @@ _unit setVariable [QGVAR(peripheralResistance), 100]; _unit setVariable [QGVAR(fractures), []]; // triage card and logs -_unit setvariable [QGVAR(triageLevel), 0, true]; -_unit setvariable [QGVAR(triageCard), [], true]; +_unit setvariable [QGVAR(triageLevel), 0]; +_unit setvariable [QGVAR(triageCard), []]; // IVs _unit setVariable [QGVAR(salineIVVolume), 0]; @@ -49,21 +52,21 @@ _unit setVariable [QGVAR(plasmaIVVolume), 0]; _unit setVariable [QGVAR(bloodIVVolume), 0]; // damage storage -_unit setvariable [QGVAR(bodyPartStatus), [0,0,0,0,0,0], true]; +_unit setvariable [QGVAR(bodyPartStatus), [0,0,0,0,0,0]]; // airway -_unit setvariable [QGVAR(airwayStatus), 100, true]; -_unit setVariable [QGVAR(airwayOccluded), false, true]; -_unit setvariable [QGVAR(airwayCollapsed), false, true]; +_unit setvariable [QGVAR(airwayStatus), 100]; +_unit setVariable [QGVAR(airwayOccluded), false]; +_unit setvariable [QGVAR(airwayCollapsed), false]; // generic medical admin -_unit setvariable [QGVAR(addedToUnitLoop), false, true]; -_unit setvariable [QGVAR(inCardiacArrest), false, true]; -_unit setVariable ["ACE_isUnconscious", false, true]; -_unit setvariable [QGVAR(hasLostBlood), false, true]; -_unit setvariable [QGVAR(isBleeding), false, true]; -_unit setvariable [QGVAR(hasPain), false, true]; -_unit setvariable [QGVAR(amountOfReviveLives), GVAR(amountOfReviveLives), true]; +_unit setvariable [QGVAR(addedToUnitLoop), false]; +_unit setvariable [QGVAR(inCardiacArrest), false]; +_unit setVariable ["ACE_isUnconscious", false]; +_unit setvariable [QGVAR(hasLostBlood), false]; +_unit setvariable [QGVAR(isBleeding), false]; +_unit setvariable [QGVAR(hasPain), false]; +_unit setvariable [QGVAR(amountOfReviveLives), GVAR(amountOfReviveLives)]; // medication _allUsedMedication = _unit getVariable [QGVAR(allUsedMedication), []]; @@ -74,9 +77,9 @@ _unit setVariable [QGVAR(allUsedMedication), []]; _logs = _unit getvariable [QGVAR(allLogs), []]; { - _unit setvariable [_x, nil, true]; + _unit setvariable [_x, nil]; } foreach _logs; -_unit setvariable [QGVAR(allLogs), [], true]; +_unit setvariable [QGVAR(allLogs), []]; // items [{ From d1a09ae7fc1429fe5d69d5d797110395b3aa51ea Mon Sep 17 00:00:00 2001 From: Glowbal Date: Fri, 17 Apr 2015 23:15:41 +0200 Subject: [PATCH 31/59] fixed vehicle crashes for adv --- addons/medical/functions/fnc_handleDamage.sqf | 6 ++++++ addons/medical/functions/fnc_handleDamage_advanced.sqf | 2 ++ addons/medical/functions/fnc_handleDamage_caching.sqf | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/addons/medical/functions/fnc_handleDamage.sqf b/addons/medical/functions/fnc_handleDamage.sqf index 1632a8f55b..c13818bbcd 100644 --- a/addons/medical/functions/fnc_handleDamage.sqf +++ b/addons/medical/functions/fnc_handleDamage.sqf @@ -57,6 +57,12 @@ if (GVAR(level) >= 2) then { _minLethalDamage = GVAR(minLethalDamages) select _typeIndex; }; + if (vehicle _unit != _unit && {!(vehicle _unit isKindOf "StaticWeapon")} && {isNull _source} && {_projectile == ""} && {_selection == ""}) then { + if (GVAR(enableVehicleCrashes)) then { + _selection = GVAR(SELECTIONS) select (floor(random(count GVAR(SELECTIONS)))); + }; + }; + if ((_minLethalDamage <= _newDamage) && {[_unit, [_selection] call FUNC(selectionNameToNumber), _newDamage] call FUNC(determineIfFatal)} && {_selection in ["", "head", "body"]}) then { if ([_unit] call FUNC(setDead)) then { _damageReturn = 1; diff --git a/addons/medical/functions/fnc_handleDamage_advanced.sqf b/addons/medical/functions/fnc_handleDamage_advanced.sqf index ba0eb8af24..8bd0267d3f 100644 --- a/addons/medical/functions/fnc_handleDamage_advanced.sqf +++ b/addons/medical/functions/fnc_handleDamage_advanced.sqf @@ -33,10 +33,12 @@ if (isNull _sourceOfDamage && {_typeOfProjectile == ""} && {vehicle _unit == _un }; _typeOfDamage = [_typeOfProjectile] call FUNC(getTypeOfDamage); _part = [_selectionName] call FUNC(selectionNameToNumber); +if (_part < 0) exitwith {}; _hitPoints = ["HitHead", "HitBody", "HitLeftArm", "HitRightArm", "HitLeftLeg", "HitRightLeg"]; // Sorting out the damage _damageBodyParts = _unit getvariable [QGVAR(bodyPartStatus), [0,0,0,0,0,0]]; + _damageBodyParts set [_part, (_damageBodyParts select _part) + _newDamage]; _unit setvariable [QGVAR(bodyPartStatus), _damageBodyParts, true]; diff --git a/addons/medical/functions/fnc_handleDamage_caching.sqf b/addons/medical/functions/fnc_handleDamage_caching.sqf index 98b2373c74..95d750843d 100644 --- a/addons/medical/functions/fnc_handleDamage_caching.sqf +++ b/addons/medical/functions/fnc_handleDamage_caching.sqf @@ -38,7 +38,7 @@ if (_selectionName in _hitSelections) then { // Check for vehicle crash if (vehicle _unit != _unit && {!(vehicle _unit isKindOf "StaticWeapon")} && {isNull _source} && {_projectile == ""} && {_selectionName == ""}) then { - if (missionNamespace getvariable [QGVAR(allowVehicleCrashDamage), true]) then { + if (GVAR(enableVehicleCrashes)) then { _selectionName = _hitSelections select (floor(random(count _hitSelections))); _projectile = "vehiclecrash"; }; From 25d8c6c93e0670fba02cb58d0507925cb40fa405 Mon Sep 17 00:00:00 2001 From: commy2 Date: Fri, 17 Apr 2015 23:24:43 +0200 Subject: [PATCH 32/59] function to show error message box --- addons/common/XEH_preInit.sqf | 1 + addons/common/functions/fnc_errorMessage.sqf | 144 +++++++++++++++++++ 2 files changed, 145 insertions(+) create mode 100644 addons/common/functions/fnc_errorMessage.sqf diff --git a/addons/common/XEH_preInit.sqf b/addons/common/XEH_preInit.sqf index b5382d0b5e..c484fd985e 100644 --- a/addons/common/XEH_preInit.sqf +++ b/addons/common/XEH_preInit.sqf @@ -42,6 +42,7 @@ PREP(doAnimation); PREP(dropBackpack); PREP(endRadioTransmission); PREP(eraseCache); +PREP(errorMessage); PREP(execNextFrame); PREP(execPersistentFnc); PREP(execRemoteFnc); diff --git a/addons/common/functions/fnc_errorMessage.sqf b/addons/common/functions/fnc_errorMessage.sqf new file mode 100644 index 0000000000..46f2d2c9d4 --- /dev/null +++ b/addons/common/functions/fnc_errorMessage.sqf @@ -0,0 +1,144 @@ +/* + * Author: commy2, based on BIS_fnc_errorMsg and BIS_fnc_guiMessage by Karel Moricky (BI) + * Stops simulation and opens a textbox with error message. + * + * Arguments: + * 0: Error name + * + * Return Value: + * None + * + * Public: No + */ +#include "script_component.hpp" + +disableSerialization; +endLoadingScreen; + +private ["_textHeader", "_textMessage", "_onOK", "_onCancel"]; + +_textHeader = _this select 0; +_textMessage = _this select 1; +_onOK = ARR_SELECT(_this,2,{}); +_onCancel = ARR_SELECT(_this,3,{}); + +if (typeName _textMessage == "STRING") then { + _textMessage = parseText _textMessage; +}; + +(call BIS_fnc_displayMission) createDisplay "RscDisplayCommonMessagePause"; + +private ["_display", "_ctrlRscMessageBox", "_ctrlBcgCommonTop", "_ctrlBcgCommon", "_ctrlText", "_ctrlBackgroundButtonOK", "_ctrlBackgroundButtonMiddle", "_ctrlBackgroundButtonCancel", "_ctrlButtonOK", "_ctrlButtonCancel"]; + +_display = uiNamespace getVariable "RscDisplayCommonMessage_display"; +_ctrlRscMessageBox = _display displayCtrl 2351; +_ctrlBcgCommonTop = _display displayCtrl 235100; +_ctrlBcgCommon = _display displayCtrl 235101; +_ctrlText = _display displayCtrl 235102; +_ctrlBackgroundButtonOK = _display displayCtrl 235103; +_ctrlBackgroundButtonMiddle = _display displayCtrl 235104; +_ctrlBackgroundButtonCancel = _display displayCtrl 235105; +_ctrlButtonOK = _display displayCtrl 235106; +_ctrlButtonCancel = _display displayCtrl 235107; + +_ctrlBcgCommonTop ctrlSetText _textHeader; + +private ["_ctrlButtonOKPos", "_ctrlBcgCommonPos", "_bottomSpaceY", "_ctrlTextPos", "_marginX", "_marginY"]; + +_ctrlButtonOKPos = ctrlPosition _ctrlButtonOK; +_ctrlBcgCommonPos = ctrlPosition _ctrlBcgCommon; +_bottomSpaceY = (_ctrlButtonOKPos select 1) - ((_ctrlBcgCommonPos select 1) + (_ctrlBcgCommonPos select 3)); + +_ctrlTextPos = ctrlPosition _ctrlText; +_marginX = (_ctrlTextPos select 0) - (_ctrlBcgCommonPos select 0); +_marginY = (_ctrlTextPos select 1) - (_ctrlBcgCommonPos select 1); + +private ["_ctrlTextPosH", "_bottomPosY"]; + +_ctrlText ctrlSetStructuredText _textMessage; +_ctrlTextPosH = ctrlTextHeight _ctrlText; + +_ctrlBcgCommon ctrlSetPosition [ + _ctrlBcgCommonPos select 0, + _ctrlBcgCommonPos select 1, + _ctrlBcgCommonPos select 2, + _ctrlTextPosH + _marginY * 2 +]; +_ctrlBcgCommon ctrlCommit 0; + +_ctrlText ctrlSetPosition [ + (_ctrlBcgCommonPos select 0) + _marginX, + (_ctrlBcgCommonPos select 1) + _marginY, + (_ctrlBcgCommonPos select 2) - _marginX * 2, + _ctrlTextPosH +]; +_ctrlText ctrlCommit 0; + +_bottomPosY = (_ctrlBcgCommonPos select 1) + _ctrlTextPosH + (_marginY * 2) + _bottomSpaceY; + +{ + private "_xPos"; + _xPos = ctrlPosition _x; + + _xPos set [1, _bottomPosY]; + _x ctrlSetPosition _xPos; + _x ctrlCommit 0; +} foreach [ + _ctrlBackgroundButtonOK, + _ctrlBackgroundButtonMiddle, + _ctrlBackgroundButtonCancel, + _ctrlButtonOK, + _ctrlButtonCancel +]; + +private ["_ctrlRscMessageBoxPos", "_ctrlRscMessageBoxPosH"]; + +_ctrlRscMessageBoxPos = ctrlPosition _ctrlRscMessageBox; +_ctrlRscMessageBoxPosH = _bottomPosY + (_ctrlButtonOKPos select 3); + +_ctrlRscMessageBox ctrlSetPosition [ + 0.5 - (_ctrlBcgCommonPos select 2) / 2, + 0.5 - _ctrlRscMessageBoxPosH / 2, + (_ctrlBcgCommonPos select 2) + 0.5, + _ctrlRscMessageBoxPosH +]; + +_ctrlRscMessageBox ctrlEnable true; +_ctrlRscMessageBox ctrlCommit 0; + +if (_onOK isEqualTo {}) then { + _ctrlButtonOK ctrlEnable false; + _ctrlButtonOK ctrlSetFade 0; + _ctrlButtonOK ctrlSetText ""; + _ctrlButtonOK ctrlCommit 0; +} else { + _ctrlButtonOK ctrlEnable true; + _ctrlButtonOK ctrlSetFade 0; + _ctrlButtonOK ctrlSetText localize "STR_DISP_OK"; + _ctrlButtonOK ctrlCommit 0; + + ctrlSetFocus _ctrlButtonOK; +}; + +if (_onCancel isEqualTo {}) then { + _ctrlButtonCancel ctrlEnable false; + _ctrlButtonCancel ctrlSetFade 0; + _ctrlButtonCancel ctrlSetText ""; + _ctrlButtonCancel ctrlCommit 0; +} else { + _ctrlButtonCancel ctrlEnable true; + _ctrlButtonCancel ctrlSetFade 0; + _ctrlButtonCancel ctrlSetText localize "STR_DISP_CANCEL"; + _ctrlButtonCancel ctrlCommit 0; + + ctrlSetFocus _ctrlButtonCancel; +}; + +_ctrlButtonOK ctrlAddEventHandler ["buttonClick", {(ctrlParent (_this select 0)) closeDisplay 1; true}]; +_ctrlButtonCancel ctrlAddEventHandler ["buttonClick", {(ctrlParent (_this select 0)) closeDisplay 2; true}]; + +GVAR(errorOnOK) = _onOK; +GVAR(errorOnCancel) = _onCancel; + +_display displayAddEventHandler ["unload", {call ([{}, GVAR(errorOnOK), GVAR(errorOnCancel)] select (_this select 1))}]; +_display displayAddEventHandler ["keyDown", {_this select 1 == 1}]; From 3ec5acbdb0a72f04ae89485fd442485d64196fe1 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 18 Apr 2015 01:05:30 +0200 Subject: [PATCH 33/59] stuff --- addons/common/config.cpp | 8 ++++++++ addons/common/functions/fnc_errorMessage.sqf | 4 ++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/addons/common/config.cpp b/addons/common/config.cpp index 769ba37de1..21d6a6facb 100644 --- a/addons/common/config.cpp +++ b/addons/common/config.cpp @@ -152,3 +152,11 @@ class CfgUIGrids { }; }; }; + +/* +// check dll +class RscStandardDisplay; +class RscDisplayMain: RscStandardDisplay { + onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDisplayMain"",'GUI')] call (uinamespace getvariable 'BIS_fnc_initDisplay'); [ARR_5('header','tail',{0},{},_this select 0)] call COMPILE_FILE(functions\fnc_errorMessage)); +}; +*/ diff --git a/addons/common/functions/fnc_errorMessage.sqf b/addons/common/functions/fnc_errorMessage.sqf index 46f2d2c9d4..e061772942 100644 --- a/addons/common/functions/fnc_errorMessage.sqf +++ b/addons/common/functions/fnc_errorMessage.sqf @@ -3,7 +3,7 @@ * Stops simulation and opens a textbox with error message. * * Arguments: - * 0: Error name + * ? * * Return Value: * None @@ -26,7 +26,7 @@ if (typeName _textMessage == "STRING") then { _textMessage = parseText _textMessage; }; -(call BIS_fnc_displayMission) createDisplay "RscDisplayCommonMessagePause"; +(ARR_SELECT(_this,4,call BIS_fnc_displayMission)) createDisplay "RscDisplayCommonMessagePause"; private ["_display", "_ctrlRscMessageBox", "_ctrlBcgCommonTop", "_ctrlBcgCommon", "_ctrlText", "_ctrlBackgroundButtonOK", "_ctrlBackgroundButtonMiddle", "_ctrlBackgroundButtonCancel", "_ctrlButtonOK", "_ctrlButtonCancel"]; From 708a2aa374567e84ab500eead2d5320a0ab7513f Mon Sep 17 00:00:00 2001 From: commy2 Date: Sat, 18 Apr 2015 01:44:53 +0200 Subject: [PATCH 34/59] check if ddls are present on mission start --- addons/common/XEH_postInit.sqf | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index e470e91c95..eda61c66ad 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -188,3 +188,14 @@ GVAR(OldPlayerWeapon) = currentWeapon ACE_player; // Players can always interact with passengers of the same vehicle {!((_this select 0) isEqualTo (_this select 1)) && {vehicle (_this select 0) == vehicle (_this select 1)}} }] call FUNC(addCanInteractWithCondition); + +// check dlls +{ + if (_x callExtension "version" == "") then { + private "_errorMsg"; + _errorMsg = format ["Extension %1.dll not installed.", _x]; + + diag_log text format ["[ACE] ERROR: %1", _errorMsg]; + ["[ACE] ERROR", _errorMsg, {findDisplay 46 closeDisplay 0}] call FUNC(errorMessage); + }; +} forEach ["ace_breakLine", "ace_advanced_ballistics", "ace_fcs"]; From db4de5100d63d2c76d4753d483113efed30877a2 Mon Sep 17 00:00:00 2001 From: ViperMaul Date: Fri, 17 Apr 2015 20:23:39 -0700 Subject: [PATCH 35/59] #552 - Copy important files and extensions --- tools/make.py | 62 ++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 57 insertions(+), 5 deletions(-) diff --git a/tools/make.py b/tools/make.py index 166d21c49d..380c29faa7 100644 --- a/tools/make.py +++ b/tools/make.py @@ -284,6 +284,50 @@ def print_yellow(msg): print(msg) color("reset") + +def copy_important_files(source_dir,destination_dir): + + originalDir = os.getcwd() + importantFiles = ["mod.cpp", + "README.md", + "AUTHORS.txt", + "LICENSE", + "logo_ace3_ca.paa" + ] + + print_yellow ("source_dir: " + source_dir) + print_yellow("destination_dir: " + destination_dir) + + #copy importantFiles + try: + print_blue("Searching for important files in " + source_dir) + for file in importantFiles: + print_green("Copying file => " + os.path.join(source_dir,file)) + shutil.copyfile(os.path.join(source_dir,file),os.path.join(destination_dir,file)) + except: + print_error("COPYING IMPORTANT FILES.") + raise + + print("") + + #copy all extension dlls + try: + os.chdir(os.path.join(source_dir)) + print_blue("Searching for DLLs in " + os.getcwd()) + filenames = glob.glob("*.dll") + + if not filenames: + print ("Empty SET") + + for dll in filenames: + print_green("Copying dll => " + os.path.join(source_dir,dll)) + if os.path.isfile(dll): + shutil.copyfile(os.path.join(source_dir,dll),os.path.join(destination_dir,dll)) + except: + print_error("COPYING DLL FILES.") + raise + finally: + os.chdir(originalDir) ############################################################################### def main(argv): @@ -436,27 +480,36 @@ See the make.cfg file for additional build options. # Release/build directory, relative to script dir release_dir = cfg.get(make_target, "release_dir", fallback="release") - + # Project PBO file prefix (files are renamed to prefix_name.pbo) pbo_name_prefix = cfg.get(make_target, "pbo_name_prefix", fallback=None) # Project module Root module_root_parent = os.path.abspath(os.path.join(os.path.join(work_drive, prefix), os.pardir)) module_root = cfg.get(make_target, "module_root", fallback=os.path.join(make_root_parent, "addons")) + ace_optionals_root = os.path.join(module_root_parent, "optionals") print_green ("module_root: " + module_root) + if (os.path.isdir(module_root)): os.chdir(module_root) else: print_error ("Directory " + module_root + " does not exist.") sys.exit() + if (os.path.isdir(ace_optionals_root)): + print_green ("ace_optionals_root: " + ace_optionals_root) + else: + print_error ("Directory " + ace_optionals_root + " does not exist.") + sys.exit() + + print_green ("release_dir: " + release_dir) + copy_important_files(module_root_parent,os.path.join(release_dir, "@ace")) + except: raise print_error("Could not parse make.cfg.") sys.exit(1) - - # See if we have been given specific modules to build from command line. if len(argv) > 1 and not make_release: arg_modules = True @@ -501,7 +554,7 @@ See the make.cfg file for additional build options. # Get list of subdirs in make root. dirs = next(os.walk(module_root))[1] - + # Autodetect what directories to build. if module_autodetect and not arg_modules: modules = [] @@ -670,7 +723,6 @@ See the make.cfg file for additional build options. else: cmd = [pboproject, "-P", os.path.join(work_drive, prefix, module), "+Engine=Arma3", "-S","+Noisy", "-X", "+Clean", "+Mod="+os.path.join(module_root, release_dir, project), "-Key"] - print_yellow(cmd) color("grey") if quiet: devnull = open(os.devnull, 'w') From 22456a4301f89e45f1c4734f45922b3bd0ecd1e0 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sat, 18 Apr 2015 19:49:29 +0200 Subject: [PATCH 36/59] use pain instead --- addons/medical/functions/fnc_init.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/functions/fnc_init.sqf b/addons/medical/functions/fnc_init.sqf index 0147b99204..a9e3625c2b 100644 --- a/addons/medical/functions/fnc_init.sqf +++ b/addons/medical/functions/fnc_init.sqf @@ -18,7 +18,7 @@ private ["_unit", "_allUsedMedication", "_logs", "_forceNew"]; _unit = _this select 0; _forceNew = if (count _this > 1) then {_this select 1} else {false}; -if (!(isnil {_unit getvariable QGVAR(triageLevel)}) && !_forceNew) exitwith {}; +if (!(isnil {_unit getvariable QGVAR(pain)}) && !_forceNew) exitwith {}; _unit setVariable [QGVAR(pain), 0]; _unit setVariable [QGVAR(morphine), 0]; From 5558a6491d1ff25c644d3357c302d0598d1c08e0 Mon Sep 17 00:00:00 2001 From: commy2 Date: Sun, 19 Apr 2015 00:40:29 +0200 Subject: [PATCH 37/59] remove weapon select in favor of the new controls from bi --- addons/weaponselect/XEH_postInit.sqf | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/addons/weaponselect/XEH_postInit.sqf b/addons/weaponselect/XEH_postInit.sqf index 6dc648d54c..ae6cfafb9d 100644 --- a/addons/weaponselect/XEH_postInit.sqf +++ b/addons/weaponselect/XEH_postInit.sqf @@ -4,7 +4,7 @@ if !(hasInterface) exitWith {}; // Add keybinds -["ACE3", QGVAR(SelectPistol), localize "STR_ACE_WeaponSelect_SelectPistol", +/*["ACE3", QGVAR(SelectPistol), localize "STR_ACE_WeaponSelect_SelectPistol", { // Conditions: canInteract if !([ACE_player, ACE_player, ["isNotEscorting"]] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -72,7 +72,7 @@ if !(hasInterface) exitWith {}; true }, {false}, -[6, [false, false, false]], false] call cba_fnc_addKeybind; //5 Key +[6, [false, false, false]], false] call cba_fnc_addKeybind; //5 Key*/ ["ACE3", QGVAR(SelectGrenadeFrag), localize "STR_ACE_WeaponSelect_SelectGrenadeFrag", { @@ -144,7 +144,7 @@ if !(hasInterface) exitWith {}; {false}, [2, [false, false, false]], false] call cba_fnc_addKeybind; //1 Key -["ACE3", QGVAR(SelectMainGun), localize "STR_ACE_WeaponSelect_SelectMainGun", +/*["ACE3", QGVAR(SelectMainGun), localize "STR_ACE_WeaponSelect_SelectMainGun", { // Conditions: canInteract if !([ACE_player, ACE_player, []] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -184,7 +184,7 @@ if !(hasInterface) exitWith {}; true }, {false}, -[6, [false, false, false]], false] call cba_fnc_addKeybind; //5 Key +[6, [false, false, false]], false] call cba_fnc_addKeybind; //5 Key*/ ["ACE3", QGVAR(FireSmokeLauncher), localize "STR_ACE_WeaponSelect_FireSmokeLauncher", { From fe92110b4d7be5559f2f48a35076247e5a8cae53 Mon Sep 17 00:00:00 2001 From: ViperMaul Date: Sat, 18 Apr 2015 19:16:12 -0700 Subject: [PATCH 38/59] Make sure you build missing files. Even if cache says the source files has not changed. #735 --- tools/make.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tools/make.py b/tools/make.py index 380c29faa7..ce5b770383 100644 --- a/tools/make.py +++ b/tools/make.py @@ -597,7 +597,8 @@ See the make.cfg file for additional build options. # For each module, prep files and then build. for module in modules: print_green("\nMaking " + module + "-"*max(1, (60-len(module)))) - + missing = False + # Cache check if module in cache: old_sha = cache[module] @@ -610,10 +611,15 @@ See the make.cfg file for additional build options. # Hash the module new_sha = get_directory_hash(os.path.join(module_root, module)) + + # Is the pbo file missing? + missing = not os.path.isfile(os.path.join(release_dir, project, "addons", "ace_{}.pbo".format(module))) + if missing: + print("ace_{}.pbo".format(module) + " is missing. Building...") # Check if it needs rebuilt # print ("Hash:", new_sha) - if old_sha == new_sha: + if old_sha == new_sha and not missing: if not force_build: print("Module has not changed.") # Skip everything else From 8a7b3a1b334de2ee6108d63865c47ff6ec7e44e9 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sun, 19 Apr 2015 13:08:28 +0200 Subject: [PATCH 39/59] Removed damage thresholds from basic medical --- addons/medical/functions/fnc_handleDamage_basic.sqf | 6 ------ 1 file changed, 6 deletions(-) diff --git a/addons/medical/functions/fnc_handleDamage_basic.sqf b/addons/medical/functions/fnc_handleDamage_basic.sqf index 6e343b127a..aa9c2f61df 100644 --- a/addons/medical/functions/fnc_handleDamage_basic.sqf +++ b/addons/medical/functions/fnc_handleDamage_basic.sqf @@ -63,12 +63,6 @@ if (_selectionName in GVAR(SELECTIONS)) then { _newDamage = _damage - (_unit getHitPointDamage (GVAR(HITPOINTS) select (GVAR(SELECTIONS) find _selectionName))); }; -if ([_unit] call EFUNC(common,isPlayer)) then { - _newDamage = _newDamage / (GVAR(playerDamageThreshold) max 0.01); -} else { - _newDamage = _newDamage / (GVAR(AIDamageThreshold) max 0.01); -}; - _damage = _damage - _newDamage; From f6bbeb6bd6778977aa66983845b096e84c390f76 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sun, 19 Apr 2015 17:28:47 +0200 Subject: [PATCH 40/59] switched back to old init method --- addons/medical/XEH_init.sqf | 5 ++- addons/medical/XEH_respawn.sqf | 2 +- addons/medical/functions/fnc_init.sqf | 51 +++++++++++++-------------- 3 files changed, 29 insertions(+), 29 deletions(-) diff --git a/addons/medical/XEH_init.sqf b/addons/medical/XEH_init.sqf index f3fb2b1e93..0ded7d471f 100644 --- a/addons/medical/XEH_init.sqf +++ b/addons/medical/XEH_init.sqf @@ -4,4 +4,7 @@ private ["_unit"]; _unit = _this select 0; _unit addEventHandler ["HandleDamage", {_this call FUNC(handleDamage)}]; -[_unit] call FUNC(init); + +if (local _unit) then { + [_unit] call FUNC(init); +}; diff --git a/addons/medical/XEH_respawn.sqf b/addons/medical/XEH_respawn.sqf index 5047f0026c..ac6cc2d6ef 100644 --- a/addons/medical/XEH_respawn.sqf +++ b/addons/medical/XEH_respawn.sqf @@ -6,7 +6,7 @@ _unit = _this select 0; if !(local _unit) exitWith {}; -[_unit, true] call FUNC(init); +[_unit] call FUNC(init); //Reset captive status for respawning unit if (!(_unit getVariable ["ACE_isUnconscious", false])) then { diff --git a/addons/medical/functions/fnc_init.sqf b/addons/medical/functions/fnc_init.sqf index a9e3625c2b..d01a63b3a5 100644 --- a/addons/medical/functions/fnc_init.sqf +++ b/addons/medical/functions/fnc_init.sqf @@ -16,22 +16,19 @@ private ["_unit", "_allUsedMedication", "_logs", "_forceNew"]; _unit = _this select 0; -_forceNew = if (count _this > 1) then {_this select 1} else {false}; -if (!(isnil {_unit getvariable QGVAR(pain)}) && !_forceNew) exitwith {}; - -_unit setVariable [QGVAR(pain), 0]; -_unit setVariable [QGVAR(morphine), 0]; -_unit setVariable [QGVAR(bloodVolume), 100]; +_unit setVariable [QGVAR(pain), 0, true]; +_unit setVariable [QGVAR(morphine), 0, true]; +_unit setVariable [QGVAR(bloodVolume), 100, true]; // tourniquets -_unit setvariable [QGVAR(tourniquets), [0,0,0,0,0,0]]; +_unit setvariable [QGVAR(tourniquets), [0,0,0,0,0,0], true]; // wounds and injuries -_unit setvariable [QGVAR(openWounds), []]; -_unit setvariable [QGVAR(bandagedWounds), []]; -_unit setVariable [QGVAR(internalWounds), []]; -_unit setvariable [QGVAR(lastUniqueWoundID), 1]; +_unit setvariable [QGVAR(openWounds), [], true]; +_unit setvariable [QGVAR(bandagedWounds), [], true]; +_unit setVariable [QGVAR(internalWounds), [], true]; +_unit setvariable [QGVAR(lastUniqueWoundID), 1, true]; // vitals _unit setVariable [QGVAR(heartRate), 80]; @@ -40,19 +37,19 @@ _unit setvariable [QGVAR(bloodPressure), [80, 120]]; _unit setVariable [QGVAR(peripheralResistance), 100]; // fractures -_unit setVariable [QGVAR(fractures), []]; +_unit setVariable [QGVAR(fractures), [], true]; // triage card and logs -_unit setvariable [QGVAR(triageLevel), 0]; -_unit setvariable [QGVAR(triageCard), []]; +_unit setvariable [QGVAR(triageLevel), 0, true]; +_unit setvariable [QGVAR(triageCard), [], true]; // IVs -_unit setVariable [QGVAR(salineIVVolume), 0]; -_unit setVariable [QGVAR(plasmaIVVolume), 0]; -_unit setVariable [QGVAR(bloodIVVolume), 0]; +_unit setVariable [QGVAR(salineIVVolume), 0, true]; +_unit setVariable [QGVAR(plasmaIVVolume), 0, true]; +_unit setVariable [QGVAR(bloodIVVolume), 0, true]; // damage storage -_unit setvariable [QGVAR(bodyPartStatus), [0,0,0,0,0,0]]; +_unit setvariable [QGVAR(bodyPartStatus), [0,0,0,0,0,0], true]; // airway _unit setvariable [QGVAR(airwayStatus), 100]; @@ -60,26 +57,26 @@ _unit setVariable [QGVAR(airwayOccluded), false]; _unit setvariable [QGVAR(airwayCollapsed), false]; // generic medical admin -_unit setvariable [QGVAR(addedToUnitLoop), false]; -_unit setvariable [QGVAR(inCardiacArrest), false]; -_unit setVariable ["ACE_isUnconscious", false]; -_unit setvariable [QGVAR(hasLostBlood), false]; -_unit setvariable [QGVAR(isBleeding), false]; -_unit setvariable [QGVAR(hasPain), false]; -_unit setvariable [QGVAR(amountOfReviveLives), GVAR(amountOfReviveLives)]; +_unit setvariable [QGVAR(addedToUnitLoop), false, true]; +_unit setvariable [QGVAR(inCardiacArrest), false, true]; +_unit setVariable ["ACE_isUnconscious", false, true]; +_unit setvariable [QGVAR(hasLostBlood), false, true]; +_unit setvariable [QGVAR(isBleeding), false, true]; +_unit setvariable [QGVAR(hasPain), false, true]; +_unit setvariable [QGVAR(amountOfReviveLives), GVAR(amountOfReviveLives), true]; // medication _allUsedMedication = _unit getVariable [QGVAR(allUsedMedication), []]; { _unit setvariable [_x select 0, nil]; } foreach _allUsedMedication; -_unit setVariable [QGVAR(allUsedMedication), []]; +_unit setVariable [QGVAR(allUsedMedication), [], true]; _logs = _unit getvariable [QGVAR(allLogs), []]; { _unit setvariable [_x, nil]; } foreach _logs; -_unit setvariable [QGVAR(allLogs), []]; +_unit setvariable [QGVAR(allLogs), [], true]; // items [{ From 17899db086726ce830e79abd4f3a363e512f53c1 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sun, 19 Apr 2015 19:49:56 +0200 Subject: [PATCH 41/59] added some missing privates --- addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf b/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf index 02626ff1fe..29bc6dc4d3 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf @@ -15,7 +15,7 @@ #include "script_component.hpp" -private ["_target", "_bandage", "_part", "_selectionName", "_openWounds", "_config", "_effectiveness","_mostEffectiveInjury", "_mostEffectiveSpot", "_woundEffectivenss", "_mostEffectiveInjury", "_impact", "_exit"]; +private ["_target", "_bandage", "_part", "_selectionName", "_openWounds", "_config", "_effectiveness","_mostEffectiveInjury", "_mostEffectiveSpot", "_woundEffectivenss", "_mostEffectiveInjury", "_impact", "_exit", "_specificClass", "_classID", "_effectivenessFound"]; _target = _this select 0; _bandage = _this select 1; _selectionName = _this select 2; From ac201d334c70bb6a5201776dd4ce63dd9129ea52 Mon Sep 17 00:00:00 2001 From: ViperMaul Date: Sun, 19 Apr 2015 14:51:51 -0700 Subject: [PATCH 42/59] Added support for building server.pbo Added new optionals_root to make.cfg Updated version Added global variables. #552 --- tools/make.cfg | 5 ++++ tools/make.py | 67 ++++++++++++++++++++++++++++++++++++++++++-------- 2 files changed, 62 insertions(+), 10 deletions(-) diff --git a/tools/make.cfg b/tools/make.cfg index 1eb02b826f..e89568d60e 100644 --- a/tools/make.cfg +++ b/tools/make.cfg @@ -39,6 +39,11 @@ prefix = z\ace\addons # Default: \\addons module_root = P:\z\ace\addons +# Set the location where the optional addon source folders (i.e. P:\z\ace\optionals) +# Default: \\optionals +optionals_root = P:\z\ace\optionals + + # Directory where the built addon will be saved. # Default: release release_dir = P:\z\ace\release diff --git a/tools/make.py b/tools/make.py index ce5b770383..ffa5f75e25 100644 --- a/tools/make.py +++ b/tools/make.py @@ -30,7 +30,7 @@ ############################################################################### -__version__ = "0.3dev" +__version__ = "0.4" import sys @@ -54,6 +54,13 @@ import re if sys.platform == "win32": import winreg +######## GLOBALS ######### +work_drive = "" +module_root = "" +release_dir = "" +module_root_parent = "" +optionals_root = "" + ############################################################################### # http://akiscode.com/articles/sha-1directoryhash.shtml # Copyright (c) 2009 Stephen Akiki @@ -300,7 +307,7 @@ def copy_important_files(source_dir,destination_dir): #copy importantFiles try: - print_blue("Searching for important files in " + source_dir) + print_blue("\nSearching for important files in " + source_dir) for file in importantFiles: print_green("Copying file => " + os.path.join(source_dir,file)) shutil.copyfile(os.path.join(source_dir,file),os.path.join(destination_dir,file)) @@ -308,12 +315,10 @@ def copy_important_files(source_dir,destination_dir): print_error("COPYING IMPORTANT FILES.") raise - print("") - #copy all extension dlls try: os.chdir(os.path.join(source_dir)) - print_blue("Searching for DLLs in " + os.getcwd()) + print_blue("\nSearching for DLLs in " + os.getcwd()) filenames = glob.glob("*.dll") if not filenames: @@ -328,11 +333,42 @@ def copy_important_files(source_dir,destination_dir): raise finally: os.chdir(originalDir) + +def copy_optionals_for_building(mod): + src_directories = os.listdir(optionals_root) + print("") + try: + for dir_name in src_directories: + mod.append(dir_name) + if (dir_name == "userconfig"): + destination = os.path.join(work_drive,dir_name) + else: + destination = os.path.join(module_root,dir_name) + + print("Temporarily copying " + os.path.join(optionals_root,dir_name) + " => " + destination + " for building.") + shutil.rmtree(destination, True) + shutil.copytree(os.path.join(optionals_root,dir_name), destination) + except: + print_error("Copy Optionals Failed") + raise + +def cleanup_optionals(mod): + try: + for dir_name in mod: + if (dir_name == "userconfig"): + destination = os.path.join(work_drive,dir_name) + else: + destination = os.path.join(module_root,dir_name) + print("Cleaning " + destination) + shutil.rmtree(destination) + except: + print_error("Cleaning Optionals Failed") + raise ############################################################################### def main(argv): """Build an Arma addon suite in a directory from rules in a make.cfg file.""" - print_blue(("\nmake.py for Arma, v" + __version__)) + print_blue(("\nmake.py for Arma, modified for Advanced Combat Environment v" + __version__)) if sys.platform != "win32": print_error("Non-Windows platform (Cygwin?). Please re-run from cmd.") @@ -447,6 +483,12 @@ See the make.cfg file for additional build options. cfg = configparser.ConfigParser(); try: + global work_drive + global module_root + global release_dir + global module_root_parent + global optionals_root + cfg.read(os.path.join(make_root, "make.cfg")) # Project name (with @ symbol) @@ -487,7 +529,7 @@ See the make.cfg file for additional build options. # Project module Root module_root_parent = os.path.abspath(os.path.join(os.path.join(work_drive, prefix), os.pardir)) module_root = cfg.get(make_target, "module_root", fallback=os.path.join(make_root_parent, "addons")) - ace_optionals_root = os.path.join(module_root_parent, "optionals") + optionals_root = os.path.join(module_root_parent, "optionals") print_green ("module_root: " + module_root) if (os.path.isdir(module_root)): @@ -496,10 +538,10 @@ See the make.cfg file for additional build options. print_error ("Directory " + module_root + " does not exist.") sys.exit() - if (os.path.isdir(ace_optionals_root)): - print_green ("ace_optionals_root: " + ace_optionals_root) + if (os.path.isdir(optionals_root)): + print_green ("optionals_root: " + optionals_root) else: - print_error ("Directory " + ace_optionals_root + " does not exist.") + print_error ("Directory " + optionals_root + " does not exist.") sys.exit() print_green ("release_dir: " + release_dir) @@ -552,6 +594,10 @@ See the make.cfg file for additional build options. print ("No cache found.") cache = {} + #Temporarily copy optionals_root for building. They will be removed later. + optionals_modules = [] + copy_optionals_for_building(optionals_modules) + # Get list of subdirs in make root. dirs = next(os.walk(module_root))[1] @@ -910,6 +956,7 @@ See the make.cfg file for additional build options. except: print_error("Could not copy files. Is Arma 3 running?") + cleanup_optionals(optionals_modules) if __name__ == "__main__": main(sys.argv) input("Press Enter to continue...") From 9c11e47ef45ca29ffa3ef096120ebb8f87492491 Mon Sep 17 00:00:00 2001 From: ViperMaul Date: Sun, 19 Apr 2015 15:28:54 -0700 Subject: [PATCH 43/59] Missing changes that Git Extensions client left out #552 --- tools/make.py | 53 ++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 46 insertions(+), 7 deletions(-) diff --git a/tools/make.py b/tools/make.py index ffa5f75e25..f036bd0c83 100644 --- a/tools/make.py +++ b/tools/make.py @@ -334,8 +334,30 @@ def copy_important_files(source_dir,destination_dir): finally: os.chdir(originalDir) -def copy_optionals_for_building(mod): +def copy_optionals_for_building(mod,pbos): src_directories = os.listdir(optionals_root) + current_dir = os.getcwd() + + print("") + try: + + #special server.pbo processing + files = glob.glob(os.path.join(release_dir, "@ace","optionals","*.pbo")) + for file in files: + file_name = os.path.basename(file) + print ("Adding the following file: " + file_name) + pbos.append(file_name) + pbo_path = os.path.join(release_dir, "@ace","optionals",file_name) + if (os.path.isfile(pbo_path)): + print("Moving " + pbo_path + " for processing.") + shutil.move(pbo_path, os.path.join(release_dir,"@ace","addons",file_name)) + + except: + print_error("Error in moving") + raise + finally: + os.chdir(current_dir) + print("") try: for dir_name in src_directories: @@ -344,23 +366,39 @@ def copy_optionals_for_building(mod): destination = os.path.join(work_drive,dir_name) else: destination = os.path.join(module_root,dir_name) - + print("Temporarily copying " + os.path.join(optionals_root,dir_name) + " => " + destination + " for building.") shutil.rmtree(destination, True) shutil.copytree(os.path.join(optionals_root,dir_name), destination) except: print_error("Copy Optionals Failed") raise + finally: + os.chdir(current_dir) -def cleanup_optionals(mod): - try: +def cleanup_optionals(mod,pbos): + print("") + try: for dir_name in mod: if (dir_name == "userconfig"): destination = os.path.join(work_drive,dir_name) else: destination = os.path.join(module_root,dir_name) + print("Cleaning " + destination) + + try: + file_name = "ace_{}.pbo".format(dir_name) + src_file_path = os.path.join(release_dir, "@ace","addons",file_name) + dst_file_path = os.path.join(release_dir, "@ace","optionals",file_name) + if (os.path.isfile(src_file_path)): + #print("Preserving " + file_name) + os.renames(src_file_path,dst_file_path) + except FileExistsError: + print_error(file_name + " already exists") + continue shutil.rmtree(destination) + except: print_error("Cleaning Optionals Failed") raise @@ -596,7 +634,8 @@ See the make.cfg file for additional build options. #Temporarily copy optionals_root for building. They will be removed later. optionals_modules = [] - copy_optionals_for_building(optionals_modules) + optional_files = [] + copy_optionals_for_building(optionals_modules,optional_files) # Get list of subdirs in make root. dirs = next(os.walk(module_root))[1] @@ -955,8 +994,8 @@ See the make.cfg file for additional build options. shutil.copytree(os.path.join(module_root, release_dir, project), os.path.join(a3_path, project)) except: print_error("Could not copy files. Is Arma 3 running?") - - cleanup_optionals(optionals_modules) + + cleanup_optionals(optionals_modules,optional_files) if __name__ == "__main__": main(sys.argv) input("Press Enter to continue...") From 5793175c1fe75cec868816c1b93c8d4fcbf0b8eb Mon Sep 17 00:00:00 2001 From: ViperMaul Date: Sun, 19 Apr 2015 16:00:34 -0700 Subject: [PATCH 44/59] Fixing issue when release directory is missing #552 --- tools/make.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/make.py b/tools/make.py index f036bd0c83..5146a666bb 100644 --- a/tools/make.py +++ b/tools/make.py @@ -583,7 +583,6 @@ See the make.cfg file for additional build options. sys.exit() print_green ("release_dir: " + release_dir) - copy_important_files(module_root_parent,os.path.join(release_dir, "@ace")) except: raise @@ -635,7 +634,7 @@ See the make.cfg file for additional build options. #Temporarily copy optionals_root for building. They will be removed later. optionals_modules = [] optional_files = [] - copy_optionals_for_building(optionals_modules,optional_files) + copy_optionals_for_building(optionals_modules,optional_files) # Get list of subdirs in make root. dirs = next(os.walk(module_root))[1] @@ -994,7 +993,8 @@ See the make.cfg file for additional build options. shutil.copytree(os.path.join(module_root, release_dir, project), os.path.join(a3_path, project)) except: print_error("Could not copy files. Is Arma 3 running?") - + + copy_important_files(module_root_parent,os.path.join(release_dir, "@ace")) cleanup_optionals(optionals_modules,optional_files) if __name__ == "__main__": main(sys.argv) From 6c00aef6e89972c4d89954aa0f067f6b315f58d9 Mon Sep 17 00:00:00 2001 From: commy2 Date: Mon, 20 Apr 2015 16:02:36 +0200 Subject: [PATCH 45/59] coeficients for recoil configs --- addons/recoil/CfgRecoils.hpp | 255 ++++++++++++++++++----------------- 1 file changed, 135 insertions(+), 120 deletions(-) diff --git a/addons/recoil/CfgRecoils.hpp b/addons/recoil/CfgRecoils.hpp index 27283e71f1..eac31babe8 100644 --- a/addons/recoil/CfgRecoils.hpp +++ b/addons/recoil/CfgRecoils.hpp @@ -1,240 +1,255 @@ +#define KICKBACK 1 + +#define MUZZLETEMP 1 +#define MUZZLEPERM 1 + +#define MUZZLECLIMB_POS 1 +#define MUZZLERIGHT_POS 1 + +#define MUZZLECLIMB_MAG 1 +#define MUZZLERIGHT_MAG 1 + class CfgRecoils { class Default { - muzzleOuter[] = {0,"0.4f","0.5f","0.6f"}; - muzzleInner[] = {0,"0.05f","0.2f","0.2f"}; - kickBack[] = {"0.05f",0.1}; - permanent = 0.1; - temporary = 0.01; + // doc: http://forums.bistudio.com/showthread.php?188999-Recoil-Overhaul-Feedback&s=dba8590ec07adb5ffa87f72d38dde6fc&p=2886744&viewfull=1#post2886744 + // {horizontal axis position, vertical axis position, horizontal magnitude, vertical magnitude} + muzzleOuter[] = {0*MUZZLERIGHT_POS,0.4*MUZZLECLIMB_POS,0.5*MUZZLERIGHT_MAG,0.6*MUZZLECLIMB_MAG}; + // restricted area inside the outer ellipse where the recoil cannot end + muzzleInner[] = {0,0.05,0.2,0.2}; + // minimum and maximum interval for backward force + kickBack[] = {0.05*KICKBACK,0.1*KICKBACK}; + permanent = 0.1*MUZZLEPERM; + temporary = 0.01*MUZZLETEMP; }; class recoil_default: Default { - muzzleOuter[] = {0.3,1,0.3,0.2}; + muzzleOuter[] = {0.3*MUZZLERIGHT_POS,1*MUZZLECLIMB_POS,0.3*MUZZLERIGHT_MAG,0.2*MUZZLECLIMB_MAG}; muzzleInner[] = {0,0,0.1,0.1}; - kickBack[] = {0.03,0.06}; - permanent = 0.1; - temporary = 0.01; + kickBack[] = {0.03*KICKBACK,0.06*KICKBACK}; + permanent = 0.1*MUZZLEPERM; + temporary = 0.01*MUZZLETEMP; }; class recoil_mk20: recoil_default { - muzzleOuter[] = {0.2,0.6,0.2,0.2}; - kickBack[] = {0.01,0.03}; - temporary = 0.01; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,0.6*MUZZLECLIMB_POS,0.2*MUZZLERIGHT_MAG,0.2*MUZZLECLIMB_MAG}; + kickBack[] = {0.01*KICKBACK,0.03*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_mk20c: recoil_default { - muzzleOuter[] = {0.2,0.8,0.3,0.2}; - kickBack[] = {0.02,0.04}; - temporary = 0.015; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,0.8*MUZZLECLIMB_POS,0.3*MUZZLERIGHT_MAG,0.2*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.015*MUZZLETEMP; }; class recoil_trg20: recoil_default { - muzzleOuter[] = {0.2,1,0.3,0.3}; - kickBack[] = {0.02,0.04}; - temporary = 0.015; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,1*MUZZLECLIMB_POS,0.3*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.015*MUZZLETEMP; }; class recoil_trg21: recoil_default { - muzzleOuter[] = {0.2,0.8,0.3,0.2}; - kickBack[] = {0.01,0.03}; - temporary = 0.01; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,0.8*MUZZLECLIMB_POS,0.3*MUZZLERIGHT_MAG,0.2*MUZZLECLIMB_MAG}; + kickBack[] = {0.01*KICKBACK,0.03*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_mx: recoil_default { - muzzleOuter[] = {0.3,1,0.4,0.3}; - kickBack[] = {0.02,0.04}; - temporary = 0.01; + muzzleOuter[] = {0.3*MUZZLERIGHT_POS,1*MUZZLECLIMB_POS,0.4*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_mxc: recoil_default { - muzzleOuter[] = {0.3,1.2,0.4,0.3}; - kickBack[] = {0.03,0.06}; - temporary = 0.015; + muzzleOuter[] = {0.3*MUZZLERIGHT_POS,1.2*MUZZLECLIMB_POS,0.4*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.03*KICKBACK,0.06*KICKBACK}; + temporary = 0.015*MUZZLETEMP; }; class recoil_sw: recoil_default { - muzzleOuter[] = {0.3,0.8,0.5,0.2}; - kickBack[] = {0.02,0.04}; - temporary = 0.005; + muzzleOuter[] = {0.3*MUZZLERIGHT_POS,0.8*MUZZLECLIMB_POS,0.5*MUZZLERIGHT_MAG,0.2*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.005*MUZZLETEMP; }; class recoil_mxm: recoil_default { - muzzleOuter[] = {0.3,0.8,0.4,0.3}; - kickBack[] = {0.02,0.04}; - temporary = 0.01; + muzzleOuter[] = {0.3*MUZZLERIGHT_POS,0.8*MUZZLECLIMB_POS,0.4*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_ktb: recoil_default { - muzzleOuter[] = {0.3,1,0.3,0.3}; - kickBack[] = {0.02,0.04}; - temporary = 0.01; + muzzleOuter[] = {0.3*MUZZLERIGHT_POS,1*MUZZLECLIMB_POS,0.3*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_ktbc: recoil_default { - muzzleOuter[] = {0.3,1.2,0.3,0.3}; - kickBack[] = {0.03,0.06}; - temporary = 0.015; + muzzleOuter[] = {0.3*MUZZLERIGHT_POS,1.2*MUZZLECLIMB_POS,0.3*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.03*KICKBACK,0.06*KICKBACK}; + temporary = 0.015*MUZZLETEMP; }; class recoil_smg_01: recoil_default { - muzzleOuter[] = {0.1,0.8,0.3,0.2}; - kickBack[] = {0.01,0.03}; - temporary = 0.015; + muzzleOuter[] = {0.1*MUZZLERIGHT_POS,0.8*MUZZLECLIMB_POS,0.3*MUZZLERIGHT_MAG,0.2*MUZZLECLIMB_MAG}; + kickBack[] = {0.01*KICKBACK,0.03*KICKBACK}; + temporary = 0.015*MUZZLETEMP; }; class recoil_smg_02: recoil_default { - muzzleOuter[] = {0.1,0.6,0.2,0.2}; - kickBack[] = {0.01,0.02}; - temporary = 0.01; + muzzleOuter[] = {0.1*MUZZLERIGHT_POS,0.6*MUZZLECLIMB_POS,0.2*MUZZLERIGHT_MAG,0.2*MUZZLECLIMB_MAG}; + kickBack[] = {0.01*KICKBACK,0.02*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_pdw: recoil_default { - muzzleOuter[] = {0.2,1,0.3,0.3}; - kickBack[] = {0.02,0.04}; - temporary = 0.02; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,1*MUZZLECLIMB_POS,0.3*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.02*MUZZLETEMP; }; class recoil_sdar: recoil_default { - muzzleOuter[] = {0.2,1,0.3,0.3}; - kickBack[] = {0.02,0.04}; - temporary = 0.01; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,1*MUZZLECLIMB_POS,0.3*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_pistol_p07: recoil_default { - muzzleOuter[] = {0.2,1,0.2,0.3}; - kickBack[] = {0.03,0.06}; - temporary = 0.03; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,1*MUZZLECLIMB_POS,0.2*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.03*KICKBACK,0.06*KICKBACK}; + temporary = 0.03*MUZZLETEMP; }; class recoil_pistol_rook40: recoil_default { - muzzleOuter[] = {0.2,1,0.2,0.3}; - kickBack[] = {0.03,0.06}; - temporary = 0.02; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,1*MUZZLECLIMB_POS,0.2*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.03*KICKBACK,0.06*KICKBACK}; + temporary = 0.02*MUZZLETEMP; }; class recoil_pistol_acpc2: recoil_default { - muzzleOuter[] = {0.2,1.5,0.2,0.3}; - kickBack[] = {0.04,0.08}; - temporary = 0.04; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,1.5*MUZZLECLIMB_POS,0.2*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.04*KICKBACK,0.08*KICKBACK}; + temporary = 0.04*MUZZLETEMP; }; class recoil_pistol_4five: recoil_default { - muzzleOuter[] = {0.2,1.5,0.2,0.3}; - kickBack[] = {0.04,0.08}; - temporary = 0.06; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,1.5*MUZZLECLIMB_POS,0.2*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.04*KICKBACK,0.08*KICKBACK}; + temporary = 0.06*MUZZLETEMP; }; class recoil_pistol_zubr: recoil_default { - muzzleOuter[] = {0.2,1.5,0.2,0.3}; - kickBack[] = {0.04,0.08}; - temporary = 0.08; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,1.5*MUZZLECLIMB_POS,0.2*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.04*KICKBACK,0.08*KICKBACK}; + temporary = 0.08*MUZZLETEMP; }; class recoil_pistol_signal: recoil_default { - muzzleOuter[] = {0.2,1.5,0.2,0.3}; - kickBack[] = {0.02,0.04}; - temporary = 0.02; + muzzleOuter[] = {0.2*MUZZLERIGHT_POS,1.5*MUZZLECLIMB_POS,0.2*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.02*MUZZLETEMP; }; class recoil_rpg: recoil_default { - muzzleOuter[] = {2,3,1,0.5}; - kickBack[] = {0.08,0.1}; - temporary = 0.1; + muzzleOuter[] = {2*MUZZLERIGHT_POS,3*MUZZLECLIMB_POS,1*MUZZLERIGHT_MAG,0.5*MUZZLECLIMB_MAG}; + kickBack[] = {0.08*KICKBACK,0.1*KICKBACK}; + temporary = 0.1*MUZZLETEMP; }; class recoil_nlaw: recoil_default { - muzzleOuter[] = {2,3,1,0.5}; - kickBack[] = {0.06,0.08}; - temporary = 0.08; + muzzleOuter[] = {2*MUZZLERIGHT_POS,3*MUZZLECLIMB_POS,1*MUZZLERIGHT_MAG,0.5*MUZZLECLIMB_MAG}; + kickBack[] = {0.06*KICKBACK,0.08*KICKBACK}; + temporary = 0.08*MUZZLETEMP; }; class recoil_titan_long: recoil_default { - muzzleOuter[] = {2,3,1,0.5}; - kickBack[] = {0.1,0.12}; - temporary = 0.15; + muzzleOuter[] = {2*MUZZLERIGHT_POS,3*MUZZLECLIMB_POS,1*MUZZLERIGHT_MAG,0.5*MUZZLECLIMB_MAG}; + kickBack[] = {0.1*KICKBACK,0.12*KICKBACK}; + temporary = 0.15*MUZZLETEMP; }; class recoil_titan_short: recoil_default { - muzzleOuter[] = {2,3,1,0.5}; - kickBack[] = {0.1,0.12}; - temporary = 0.12; + muzzleOuter[] = {2*MUZZLERIGHT_POS,3*MUZZLECLIMB_POS,1*MUZZLERIGHT_MAG,0.5*MUZZLECLIMB_MAG}; + kickBack[] = {0.1*KICKBACK,0.12*KICKBACK}; + temporary = 0.12*MUZZLETEMP; }; class recoil_mk200: recoil_default { - muzzleOuter[] = {0.4,0.6,0.6,0.2}; - kickBack[] = {0.03,0.06}; - temporary = 0.005; + muzzleOuter[] = {0.4*MUZZLERIGHT_POS,0.6*MUZZLECLIMB_POS,0.6*MUZZLERIGHT_MAG,0.2*MUZZLECLIMB_MAG}; + kickBack[] = {0.03*KICKBACK,0.06*KICKBACK}; + temporary = 0.005*MUZZLETEMP; }; class recoil_zafir: recoil_default { - muzzleOuter[] = {0.5,1,0.7,0.3}; - kickBack[] = {0.02,0.08}; - temporary = 0.005; + muzzleOuter[] = {0.5*MUZZLERIGHT_POS,1*MUZZLECLIMB_POS,0.7*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.08*KICKBACK}; + temporary = 0.005*MUZZLETEMP; }; class recoil_m320: recoil_default { - muzzleOuter[] = {1,3,0.5,0.6}; - kickBack[] = {0.08,0.1}; - temporary = 0.02; + muzzleOuter[] = {1*MUZZLERIGHT_POS,3*MUZZLECLIMB_POS,0.5*MUZZLERIGHT_MAG,0.6*MUZZLECLIMB_MAG}; + kickBack[] = {0.08*KICKBACK,0.1*KICKBACK}; + temporary = 0.02*MUZZLETEMP; }; class recoil_gm6: recoil_default { - muzzleOuter[] = {1.4,3.5,0.7,0.8}; - kickBack[] = {0.1,0.12}; - temporary = 0.025; + muzzleOuter[] = {1.4*MUZZLERIGHT_POS,3.5*MUZZLECLIMB_POS,0.7*MUZZLERIGHT_MAG,0.8*MUZZLECLIMB_MAG}; + kickBack[] = {0.1*KICKBACK,0.12*KICKBACK}; + temporary = 0.025*MUZZLETEMP; }; class recoil_ebr: recoil_default { - muzzleOuter[] = {0.4,1.5,0.6,0.4}; - kickBack[] = {0.04,0.07}; - temporary = 0.01; + muzzleOuter[] = {0.4*MUZZLERIGHT_POS,1.5*MUZZLECLIMB_POS,0.6*MUZZLERIGHT_MAG,0.4*MUZZLECLIMB_MAG}; + kickBack[] = {0.04*KICKBACK,0.07*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_dmr_01: recoil_default { - muzzleOuter[] = {0.5,2,0.5,0.5}; - kickBack[] = {0.03,0.08}; - temporary = 0.015; + muzzleOuter[] = {0.5*MUZZLERIGHT_POS,2*MUZZLECLIMB_POS,0.5*MUZZLERIGHT_MAG,0.5*MUZZLECLIMB_MAG}; + kickBack[] = {0.03*KICKBACK,0.08*KICKBACK}; + temporary = 0.015*MUZZLETEMP; }; class recoil_dmr_02: recoil_default { - muzzleOuter[] = {0.5,2.5,0.6,0.5}; - kickBack[] = {0.06,0.08}; - temporary = 0.01; + muzzleOuter[] = {0.5*MUZZLERIGHT_POS,2.5*MUZZLECLIMB_POS,0.6*MUZZLERIGHT_MAG,0.5*MUZZLECLIMB_MAG}; + kickBack[] = {0.06*KICKBACK,0.08*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_dmr_03: recoil_default { - muzzleOuter[] = {0.3,1.5,0.5,0.4}; - kickBack[] = {0.03,0.06}; - temporary = 0.005; + muzzleOuter[] = {0.3*MUZZLERIGHT_POS,1.5*MUZZLECLIMB_POS,0.5*MUZZLERIGHT_MAG,0.4*MUZZLECLIMB_MAG}; + kickBack[] = {0.03*KICKBACK,0.06*KICKBACK}; + temporary = 0.005*MUZZLETEMP; }; class recoil_dmr_04: recoil_default { - muzzleOuter[] = {0.4,1.5,0.5,0.4}; - kickBack[] = {0.02,0.04}; - temporary = 0.015; + muzzleOuter[] = {0.4*MUZZLERIGHT_POS,1.5*MUZZLECLIMB_POS,0.5*MUZZLERIGHT_MAG,0.4*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.04*KICKBACK}; + temporary = 0.015*MUZZLETEMP; }; class recoil_dmr_05: recoil_default { - muzzleOuter[] = {0.5,2.5,0.8,0.6}; - kickBack[] = {0.08,0.1}; - temporary = 0.01; + muzzleOuter[] = {0.5*MUZZLERIGHT_POS,2.5*MUZZLECLIMB_POS,0.8*MUZZLERIGHT_MAG,0.6*MUZZLECLIMB_MAG}; + kickBack[] = {0.08*KICKBACK,0.1*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_dmr_06: recoil_default { - muzzleOuter[] = {0.5,2,0.7,0.5}; - kickBack[] = {0.05,0.1}; - temporary = 0.01; + muzzleOuter[] = {0.5*MUZZLERIGHT_POS,2*MUZZLECLIMB_POS,0.7*MUZZLERIGHT_MAG,0.5*MUZZLECLIMB_MAG}; + kickBack[] = {0.05*KICKBACK,0.1*KICKBACK}; + temporary = 0.01*MUZZLETEMP; }; class recoil_mmg_01: recoil_default { - muzzleOuter[] = {0.6,1.5,0.8,0.3}; - kickBack[] = {0.02,0.08}; - temporary = 0.005; + muzzleOuter[] = {0.6*MUZZLERIGHT_POS,1.5*MUZZLECLIMB_POS,0.8*MUZZLERIGHT_MAG,0.3*MUZZLECLIMB_MAG}; + kickBack[] = {0.02*KICKBACK,0.08*KICKBACK}; + temporary = 0.005*MUZZLETEMP; }; class recoil_mmg_02: recoil_default { - muzzleOuter[] = {0.5,1.5,0.6,0.4}; - kickBack[] = {0.04,0.08}; - temporary = 0.005; + muzzleOuter[] = {0.5*MUZZLERIGHT_POS,1.5*MUZZLECLIMB_POS,0.6*MUZZLERIGHT_MAG,0.4*MUZZLECLIMB_MAG}; + kickBack[] = {0.04*KICKBACK,0.08*KICKBACK}; + temporary = 0.005*MUZZLETEMP; }; }; From 16c6a3ee78670aff369eed85ab769c93bba3966a Mon Sep 17 00:00:00 2001 From: commy2 Date: Mon, 20 Apr 2015 17:38:45 +0200 Subject: [PATCH 46/59] tweaking recoil --- addons/recoil/CfgRecoils.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/recoil/CfgRecoils.hpp b/addons/recoil/CfgRecoils.hpp index eac31babe8..56a28f1dc1 100644 --- a/addons/recoil/CfgRecoils.hpp +++ b/addons/recoil/CfgRecoils.hpp @@ -1,11 +1,11 @@ -#define KICKBACK 1 +#define KICKBACK 1.6 #define MUZZLETEMP 1 -#define MUZZLEPERM 1 +#define MUZZLEPERM 0.1 #define MUZZLECLIMB_POS 1 -#define MUZZLERIGHT_POS 1 +#define MUZZLERIGHT_POS 0.4 #define MUZZLECLIMB_MAG 1 #define MUZZLERIGHT_MAG 1 From ea368511b7ed013dcd72dbefa8791c404de4f341 Mon Sep 17 00:00:00 2001 From: commy2 Date: Mon, 20 Apr 2015 18:48:58 +0200 Subject: [PATCH 47/59] ace extensions class for modularity --- addons/advanced_ballistics/config.cpp | 6 +++++- addons/common/XEH_postInit.sqf | 2 +- addons/common/config.cpp | 4 ++++ addons/common/script_component.hpp | 4 +--- addons/fcs/config.cpp | 4 ++++ addons/interact_menu/config.cpp | 4 ++++ 6 files changed, 19 insertions(+), 5 deletions(-) diff --git a/addons/advanced_ballistics/config.cpp b/addons/advanced_ballistics/config.cpp index 32f1406a07..1a2187783b 100644 --- a/addons/advanced_ballistics/config.cpp +++ b/addons/advanced_ballistics/config.cpp @@ -15,4 +15,8 @@ class CfgPatches { #include "CfgEventHandlers.hpp" #include "CfgVehicles.hpp" #include "RscTitles.hpp" -#include "ACE_Settings.hpp" \ No newline at end of file +#include "ACE_Settings.hpp" + +class ACE_Extensions { + extensions[] += {"ace_advanced_ballistics"}; +}; diff --git a/addons/common/XEH_postInit.sqf b/addons/common/XEH_postInit.sqf index 55a7cfde40..3a16ac9d43 100644 --- a/addons/common/XEH_postInit.sqf +++ b/addons/common/XEH_postInit.sqf @@ -257,4 +257,4 @@ if(isMultiplayer && { time > 0 || isNull player } ) then { diag_log text format ["[ACE] ERROR: %1", _errorMsg]; ["[ACE] ERROR", _errorMsg, {findDisplay 46 closeDisplay 0}] call FUNC(errorMessage); }; -} forEach ACE_DLLS; +} forEach getArray (configFile >> "ACE_Extensions" >> "extensions"); diff --git a/addons/common/config.cpp b/addons/common/config.cpp index 21d6a6facb..16bd13fc0c 100644 --- a/addons/common/config.cpp +++ b/addons/common/config.cpp @@ -160,3 +160,7 @@ class RscDisplayMain: RscStandardDisplay { onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDisplayMain"",'GUI')] call (uinamespace getvariable 'BIS_fnc_initDisplay'); [ARR_5('header','tail',{0},{},_this select 0)] call COMPILE_FILE(functions\fnc_errorMessage)); }; */ + +class ACE_Extensions { + extensions[] = {}; +}; diff --git a/addons/common/script_component.hpp b/addons/common/script_component.hpp index 398080f7ec..7c266c169d 100644 --- a/addons/common/script_component.hpp +++ b/addons/common/script_component.hpp @@ -11,6 +11,4 @@ #define DEBUG_SETTINGS DEBUG_SETTINGS_COMMON #endif -#include "\z\ace\addons\main\script_macros.hpp" - -#define ACE_DLLS ["ace_breakLine","ace_advanced_ballistics","ace_fcs"] +#include "\z\ace\addons\main\script_macros.hpp" \ No newline at end of file diff --git a/addons/fcs/config.cpp b/addons/fcs/config.cpp index 711cbbbd25..12edf02ba3 100644 --- a/addons/fcs/config.cpp +++ b/addons/fcs/config.cpp @@ -20,3 +20,7 @@ class CfgPatches { #include "CfgWeapons.hpp" #include "CfgOptics.hpp" + +class ACE_Extensions { + extensions[] += {"ace_fcs"}; +}; diff --git a/addons/interact_menu/config.cpp b/addons/interact_menu/config.cpp index f87062bf6f..26579ba05b 100644 --- a/addons/interact_menu/config.cpp +++ b/addons/interact_menu/config.cpp @@ -30,3 +30,7 @@ class ACE_Settings { displayName = "$STR_ACE_Interact_Menu_UseListMenu"; }; }; + +class ACE_Extensions { + extensions[] += {"ace_breakLine"}; +}; From a1afd873427bc924966e640bf6f2f3e4ab02f598 Mon Sep 17 00:00:00 2001 From: OnkelDisMaster Date: Mon, 20 Apr 2015 19:56:10 +0200 Subject: [PATCH 48/59] Update config.cpp --- optionals/asdg_comp/config.cpp | 54 +++++++++++++++------------------- 1 file changed, 24 insertions(+), 30 deletions(-) diff --git a/optionals/asdg_comp/config.cpp b/optionals/asdg_comp/config.cpp index 18ef70cb1c..b485685c55 100644 --- a/optionals/asdg_comp/config.cpp +++ b/optionals/asdg_comp/config.cpp @@ -1,42 +1,36 @@ #include "script_component.hpp" -class CfgPatches -{ - class ADDON - { - units[] = {}; - weapons[] = {}; - requiredVersion = REQUIRED_VERSION; - requiredAddons[] = {"asdg_jointrails","ace_laserpointer","ace_optics"}; - author[]={"OnkelDisMaster"}; - authorUrl = "http://2.xn--gebirgsjgerkompanie-nwb.de/"; - VERSION_CONFIG; +class CfgPatches { + class ADDON { + units[] = {}; + weapons[] = {}; + requiredVersion = REQUIRED_VERSION; + requiredAddons[] = {"asdg_jointrails","ace_laserpointer","ace_optics"}; + author[]={"OnkelDisMaster"}; + authorUrl = "http://2.xn--gebirgsjgerkompanie-nwb.de/"; + VERSION_CONFIG; }; }; class asdg_SlotInfo; -class asdg_FrontSideRail: asdg_SlotInfo -{ - class compatibleItems - { - ACE_acc_pointer_red = 1; - ACE_acc_pointer_green = 1; +class asdg_FrontSideRail: asdg_SlotInfo { + class compatibleItems { + ACE_acc_pointer_red = 1; + ACE_acc_pointer_green = 1; }; }; class asdg_OpticRail; -class asdg_OpticRail1913: asdg_OpticRail -{ - class compatibleItems - { - ACE_optic_Hamr_2D = 1; - ACE_optic_Hamr_PIP = 1; - ACE_optic_Arco_2D = 1; - ACE_optic_Arco_PIP = 1; - ACE_optic_MRCO_2D = 1; - ACE_optic_SOS_2D = 1; - ACE_optic_SOS_PIP = 1; - ACE_optic_LRPS_2D = 1; - ACE_optic_LRPS_PIP = 1; +class asdg_OpticRail1913: asdg_OpticRail { + class compatibleItems { + ACE_optic_Hamr_2D = 1; + ACE_optic_Hamr_PIP = 1; + ACE_optic_Arco_2D = 1; + ACE_optic_Arco_PIP = 1; + ACE_optic_MRCO_2D = 1; + ACE_optic_SOS_2D = 1; + ACE_optic_SOS_PIP = 1; + ACE_optic_LRPS_2D = 1; + ACE_optic_LRPS_PIP = 1; }; }; From 51abafd09938ef6bc99bbe9235b021f335e9ad7d Mon Sep 17 00:00:00 2001 From: OnkelDisMaster Date: Mon, 20 Apr 2015 20:28:34 +0200 Subject: [PATCH 49/59] Added my name to AUTHORS.txt Added myself to the contirbutors, after #485 --- AUTHORS.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/AUTHORS.txt b/AUTHORS.txt index 2f16aea49c..05049978e6 100644 --- a/AUTHORS.txt +++ b/AUTHORS.txt @@ -82,3 +82,4 @@ BlackPixxel Asgar Serran Kavinsky Coren +OnkelDisMaster From ae3c8e3d88e073cdb02bf1db771a7703d57844e1 Mon Sep 17 00:00:00 2001 From: commy2 Date: Mon, 20 Apr 2015 21:10:56 +0200 Subject: [PATCH 50/59] weapon select keys are optional --- addons/weaponselect/XEH_postInit.sqf | 48 ++++++++++++++-------------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/addons/weaponselect/XEH_postInit.sqf b/addons/weaponselect/XEH_postInit.sqf index ae6cfafb9d..93813b4ed0 100644 --- a/addons/weaponselect/XEH_postInit.sqf +++ b/addons/weaponselect/XEH_postInit.sqf @@ -4,7 +4,7 @@ if !(hasInterface) exitWith {}; // Add keybinds -/*["ACE3", QGVAR(SelectPistol), localize "STR_ACE_WeaponSelect_SelectPistol", +["ACE3", QGVAR(SelectPistolNew), localize "STR_ACE_WeaponSelect_SelectPistol", { // Conditions: canInteract if !([ACE_player, ACE_player, ["isNotEscorting"]] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -13,12 +13,12 @@ if !(hasInterface) exitWith {}; // Statement [ACE_player, handgunWeapon ACE_player] call FUNC(selectWeaponMode); - true + false }, {false}, -[2, [false, false, false]], false] call cba_fnc_addKeybind; //1 Key +[0, [false, false, false]], false] call cba_fnc_addKeybind; //1 Key -["ACE3", QGVAR(SelectRifle), localize "STR_ACE_WeaponSelect_SelectRifle", +["ACE3", QGVAR(SelectRifleNew), localize "STR_ACE_WeaponSelect_SelectRifle", { // Conditions: canInteract if !([ACE_player, ACE_player, ["isNotEscorting"]] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -27,12 +27,12 @@ if !(hasInterface) exitWith {}; // Statement [ACE_player, primaryWeapon ACE_player] call FUNC(selectWeaponMode); - true + false }, {false}, -[3, [false, false, false]], false] call cba_fnc_addKeybind; //2 Key +[0, [false, false, false]], false] call cba_fnc_addKeybind; //2 Key -["ACE3", QGVAR(SelectRifleMuzzle), localize "STR_ACE_WeaponSelect_SelectRifleMuzzle", +["ACE3", QGVAR(SelectRifleMuzzleNew), localize "STR_ACE_WeaponSelect_SelectRifleMuzzle", { // Conditions: canInteract if !([ACE_player, ACE_player, ["isNotEscorting"]] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -41,12 +41,12 @@ if !(hasInterface) exitWith {}; // Statement [ACE_player, primaryWeapon ACE_player] call FUNC(selectWeaponMuzzle); - true + false }, {false}, -[4, [false, false, false]], false] call cba_fnc_addKeybind; //3 Key +[0, [false, false, false]], false] call cba_fnc_addKeybind; //3 Key -["ACE3", QGVAR(SelectLauncher), localize "STR_ACE_WeaponSelect_SelectLauncher", +["ACE3", QGVAR(SelectLauncherNew), localize "STR_ACE_WeaponSelect_SelectLauncher", { // Conditions: canInteract if !([ACE_player, ACE_player, ["isNotEscorting"]] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -55,12 +55,12 @@ if !(hasInterface) exitWith {}; // Statement [ACE_player, secondaryWeapon ACE_player] call FUNC(selectWeaponMode); - true + false }, {false}, -[5, [false, false, false]], false] call cba_fnc_addKeybind; //4 Key +[0, [false, false, false]], false] call cba_fnc_addKeybind; //4 Key -["ACE3", QGVAR(SelectBinocular), localize "STR_ACE_WeaponSelect_SelectBinocular", +["ACE3", QGVAR(SelectBinocularNew), localize "STR_ACE_WeaponSelect_SelectBinocular", { // Conditions: canInteract if !([ACE_player, ACE_player, ["isNotEscorting"]] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -69,10 +69,10 @@ if !(hasInterface) exitWith {}; // Statement [ACE_player, binocular ACE_player] call FUNC(selectWeaponMode); - true + false }, {false}, -[6, [false, false, false]], false] call cba_fnc_addKeybind; //5 Key*/ +[0, [false, false, false]], false] call cba_fnc_addKeybind; //5 Key ["ACE3", QGVAR(SelectGrenadeFrag), localize "STR_ACE_WeaponSelect_SelectGrenadeFrag", { @@ -144,7 +144,7 @@ if !(hasInterface) exitWith {}; {false}, [2, [false, false, false]], false] call cba_fnc_addKeybind; //1 Key -/*["ACE3", QGVAR(SelectMainGun), localize "STR_ACE_WeaponSelect_SelectMainGun", +["ACE3", QGVAR(SelectMainGunNew), localize "STR_ACE_WeaponSelect_SelectMainGun", { // Conditions: canInteract if !([ACE_player, ACE_player, []] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -153,12 +153,12 @@ if !(hasInterface) exitWith {}; // Statement [ACE_player, vehicle ACE_player, 0] call FUNC(selectWeaponVehicle); - true + false }, {false}, -[4, [false, false, false]], false] call cba_fnc_addKeybind; //3 Key +[0, [false, false, false]], false] call cba_fnc_addKeybind; //3 Key -["ACE3", QGVAR(SelectMachineGun), localize "STR_ACE_WeaponSelect_SelectMachineGun", +["ACE3", QGVAR(SelectMachineGunNew), localize "STR_ACE_WeaponSelect_SelectMachineGun", { // Conditions: canInteract if !([ACE_player, ACE_player, []] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -167,12 +167,12 @@ if !(hasInterface) exitWith {}; // Statement [ACE_player, vehicle ACE_player, 1] call FUNC(selectWeaponVehicle); - true + false }, {false}, -[5, [false, false, false]], false] call cba_fnc_addKeybind; //4 Key +[0, [false, false, false]], false] call cba_fnc_addKeybind; //4 Key -["ACE3", QGVAR(SelectMissiles), localize "STR_ACE_WeaponSelect_SelectMissiles", +["ACE3", QGVAR(SelectMissilesNew), localize "STR_ACE_WeaponSelect_SelectMissiles", { // Conditions: canInteract if !([ACE_player, ACE_player, []] call EFUNC(common,canInteractWith)) exitWith {false}; @@ -181,10 +181,10 @@ if !(hasInterface) exitWith {}; // Statement [ACE_player, vehicle ACE_player, 2] call FUNC(selectWeaponVehicle); - true + false }, {false}, -[6, [false, false, false]], false] call cba_fnc_addKeybind; //5 Key*/ +[0, [false, false, false]], false] call cba_fnc_addKeybind; //5 Key ["ACE3", QGVAR(FireSmokeLauncher), localize "STR_ACE_WeaponSelect_FireSmokeLauncher", { From 8be7ccaab7989b717b6559f87816d59c71428a0e Mon Sep 17 00:00:00 2001 From: Glowbal Date: Mon, 20 Apr 2015 21:37:30 +0200 Subject: [PATCH 51/59] setting for moving unit from group on unconscious --- addons/medical/ACE_Settings.hpp | 10 +++++++--- addons/medical/functions/fnc_setUnconscious.sqf | 4 +++- addons/medical/functions/fnc_unconsciousPFH.sqf | 8 ++++++-- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/addons/medical/ACE_Settings.hpp b/addons/medical/ACE_Settings.hpp index 0270bee89b..e7f60a14e8 100644 --- a/addons/medical/ACE_Settings.hpp +++ b/addons/medical/ACE_Settings.hpp @@ -79,16 +79,16 @@ class ACE_Settings { displayName = "$STR_ACE_Medical_litterSimulationDetail"; description = "$STR_ACE_Medical_litterSimulationDetail_Desc"; typeName = "SCALAR"; - + value = 3; values[] = {"Off", "Low", "Medium", "High", "Ultra"}; _values[] = { 0, 50, 100, 1000, 5000 }; - + isClientSettable = 1; }; class GVAR(litterCleanUpDelay) { typeName = "SCALAR"; - value = 0; + value = 0; }; class GVAR(medicSetting_PAK) { typeName = "SCALAR"; @@ -139,4 +139,8 @@ class ACE_Settings { typeName = "BOOL"; value = 0; }; + class GVAR(moveUnitsFromGroupOnUnconscious) { + typeName = "BOOL"; + value = 0; + }; }; diff --git a/addons/medical/functions/fnc_setUnconscious.sqf b/addons/medical/functions/fnc_setUnconscious.sqf index ef9ccb246d..e527215c51 100644 --- a/addons/medical/functions/fnc_setUnconscious.sqf +++ b/addons/medical/functions/fnc_setUnconscious.sqf @@ -73,7 +73,9 @@ _unit setUnitPos "DOWN"; // So the AI does not get stuck, we are moving the unit to a temp group on its own. //Unconscious units shouldn't be put in another group #527: -// [_unit, true, "ACE_isUnconscious", side group _unit] call EFUNC(common,switchToGroupSide); +if (GVAR(moveUnitsFromGroupOnUnconscious)) then { + [_unit, true, "ACE_isUnconscious", side group _unit] call EFUNC(common,switchToGroupSide); +}; [_unit, QGVAR(unconscious), true] call EFUNC(common,setCaptivityStatus); [_unit, [_unit] call EFUNC(common,getDeathAnim), 1, true] call EFUNC(common,doAnimation); diff --git a/addons/medical/functions/fnc_unconsciousPFH.sqf b/addons/medical/functions/fnc_unconsciousPFH.sqf index 406d0278c1..1d7558e5fc 100644 --- a/addons/medical/functions/fnc_unconsciousPFH.sqf +++ b/addons/medical/functions/fnc_unconsciousPFH.sqf @@ -24,6 +24,9 @@ _hasMovedOut = _args select 5; _parachuteCheck = _args select 6; if (!alive _unit) exitwith { + if (GVAR(moveUnitsFromGroupOnUnconscious)) then { + [_unit, false, "ACE_isUnconscious", side group _unit] call EFUNC(common,switchToGroupSide); + }; [_unit, QGVAR(unconscious), false] call EFUNC(common,setCaptivityStatus); [_unit, false] call EFUNC(common,disableAI); //_unit setUnitPos _originalPos; @@ -60,8 +63,9 @@ if !(_unit getvariable ["ACE_isUnconscious",false]) exitwith { // Swhich the unit back to its original group //Unconscious units shouldn't be put in another group #527: - // [_unit, false, "ACE_isUnconscious", side group _unit] call EFUNC(common,switchToGroupSide); - + if (GVAR(moveUnitsFromGroupOnUnconscious)) then { + [_unit, false, "ACE_isUnconscious", side group _unit] call EFUNC(common,switchToGroupSide); + }; [_unit, false] call EFUNC(common,disableAI); _unit setUnitPos _originalPos; // This is not position but stance (DOWN, MIDDLE, UP) From 90cf882e026fd310000b9598963c15dcf23ab8d1 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Mon, 20 Apr 2015 21:58:27 +0200 Subject: [PATCH 52/59] Using setvar instead of event sync again --- addons/medical/script_component.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/medical/script_component.hpp b/addons/medical/script_component.hpp index bac6744bc1..939a811a41 100644 --- a/addons/medical/script_component.hpp +++ b/addons/medical/script_component.hpp @@ -11,4 +11,4 @@ #include "\z\ace\addons\main\script_macros.hpp" -#define USE_WOUND_EVENT_SYNC true +#define USE_WOUND_EVENT_SYNC false From 842bfe0b98360874e1c78354f469045549b19789 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Mon, 20 Apr 2015 22:00:11 +0200 Subject: [PATCH 53/59] enabled advanced wounds setting --- .../medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf b/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf index 29bc6dc4d3..2884503599 100644 --- a/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf +++ b/addons/medical/functions/fnc_treatmentAdvanced_bandageLocal.sqf @@ -92,8 +92,7 @@ if (USE_WOUND_EVENT_SYNC) then { }; // Handle the reopening of bandaged wounds if (_impact > 0 && {GVAR(enableAdvancedWounds)}) then { -// TODO temp disabled until bandaged wounds are supported by event sync. -// [_target, _impact, _part, _mostEffectiveSpot, _mostEffectiveInjury, _bandage] call FUNC(handleBandageOpening); + [_target, _impact, _part, _mostEffectiveSpot, _mostEffectiveInjury, _bandage] call FUNC(handleBandageOpening); }; // If all wounds have been bandaged, we will reset all damage to 0, so the unit is not showing any blood on the model anymore. From afc8abce851bc66e3bce6b5fb911e08d386964dc Mon Sep 17 00:00:00 2001 From: commy2 Date: Mon, 20 Apr 2015 22:00:13 +0200 Subject: [PATCH 54/59] hide open bag option when it's not selected via scroll wheel --- addons/interact_menu/CfgActions.hpp | 7 +++++++ addons/interact_menu/config.cpp | 2 ++ 2 files changed, 9 insertions(+) create mode 100644 addons/interact_menu/CfgActions.hpp diff --git a/addons/interact_menu/CfgActions.hpp b/addons/interact_menu/CfgActions.hpp new file mode 100644 index 0000000000..79af4f09b2 --- /dev/null +++ b/addons/interact_menu/CfgActions.hpp @@ -0,0 +1,7 @@ + +class CfgActions { + class None; + class OpenBag: None { + showWindow = 0; + }; +}; diff --git a/addons/interact_menu/config.cpp b/addons/interact_menu/config.cpp index 81d2dc3f75..eeff688a1a 100644 --- a/addons/interact_menu/config.cpp +++ b/addons/interact_menu/config.cpp @@ -14,6 +14,8 @@ class CfgPatches { #include "CfgEventHandlers.hpp" +#include "CfgActions.hpp" + #include "CursorMenus.hpp" class ACE_Settings { From f7719f0e0ae7a8564881dba89ae7022a5cc4520c Mon Sep 17 00:00:00 2001 From: Glowbal Date: Mon, 20 Apr 2015 22:08:31 +0200 Subject: [PATCH 55/59] tab --- addons/medical/functions/fnc_actionLoadUnit.sqf | 4 ++-- addons/medical/functions/fnc_handleLocal.sqf | 10 +++++----- addons/medical/functions/fnc_treatment_failure.sqf | 4 ++-- addons/medical/functions/fnc_treatment_success.sqf | 4 ++-- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/addons/medical/functions/fnc_actionLoadUnit.sqf b/addons/medical/functions/fnc_actionLoadUnit.sqf index 5606f15d19..990467521a 100644 --- a/addons/medical/functions/fnc_actionLoadUnit.sqf +++ b/addons/medical/functions/fnc_actionLoadUnit.sqf @@ -23,10 +23,10 @@ if ([_target] call EFUNC(common,isAwake)) exitwith { ["displayTextStructured", [_caller], [["This person (%1) is awake and cannot be loaded", [_target] call EFUNC(common,getName)], 1.5, _caller]] call EFUNC(common,targetEvent); }; if ([_target] call FUNC(isBeingCarried)) then { - [_caller, _target] call FUNC(dropObject_carry); + [_caller, _target] call FUNC(dropObject_carry); }; if ([_target] call FUNC(isBeingDragged)) then { - [_caller, _target] call FUNC(dropObject); + [_caller, _target] call FUNC(dropObject); }; _vehicle = [_caller, _target] call EFUNC(common,loadPerson); diff --git a/addons/medical/functions/fnc_handleLocal.sqf b/addons/medical/functions/fnc_handleLocal.sqf index 98b390b51a..f79c1c3a6d 100644 --- a/addons/medical/functions/fnc_handleLocal.sqf +++ b/addons/medical/functions/fnc_handleLocal.sqf @@ -24,12 +24,12 @@ if (_local) then { }; if ((_unit getvariable ["ACE_isUnconscious",false]) && {count (_unit getvariable [QGVAR(unconsciousArguments), []]) >= 7}) then { - private "_arguments"; - _arguments = (_unit getvariable [QGVAR(unconsciousArguments), []]); - _arguments set [ 3, time]; + private "_arguments"; + _arguments = (_unit getvariable [QGVAR(unconsciousArguments), []]); + _arguments set [ 3, time]; - [DFUNC(unconsciousPFH), 0.1, _arguments ] call CBA_fnc_addPerFrameHandler; + [DFUNC(unconsciousPFH), 0.1, _arguments ] call CBA_fnc_addPerFrameHandler; - _unit setvariable [QGVAR(unconsciousArguments), nil, true]; + _unit setvariable [QGVAR(unconsciousArguments), nil, true]; }; }; diff --git a/addons/medical/functions/fnc_treatment_failure.sqf b/addons/medical/functions/fnc_treatment_failure.sqf index fe8bafb0c7..33712956a0 100644 --- a/addons/medical/functions/fnc_treatment_failure.sqf +++ b/addons/medical/functions/fnc_treatment_failure.sqf @@ -36,9 +36,9 @@ _caller setvariable [QGVAR(treatmentPrevAnimCaller), nil]; _weaponSelect = (_caller getvariable [QGVAR(selectedWeaponOnTreatment), ""]); if (_weaponSelect != "") then { - _caller selectWeapon _weaponSelect; + _caller selectWeapon _weaponSelect; } else { - _caller action ["SwitchWeapon", _caller, _caller, 99]; + _caller action ["SwitchWeapon", _caller, _caller, 99]; }; { diff --git a/addons/medical/functions/fnc_treatment_success.sqf b/addons/medical/functions/fnc_treatment_success.sqf index 6822f674c7..66406a180a 100644 --- a/addons/medical/functions/fnc_treatment_success.sqf +++ b/addons/medical/functions/fnc_treatment_success.sqf @@ -34,9 +34,9 @@ _caller setvariable [QGVAR(treatmentPrevAnimCaller), nil]; _weaponSelect = (_caller getvariable [QGVAR(selectedWeaponOnTreatment), ""]); if (_weaponSelect != "") then { - _caller selectWeapon _weaponSelect; + _caller selectWeapon _weaponSelect; } else { - _caller action ["SwitchWeapon", _caller, _caller, 99]; + _caller action ["SwitchWeapon", _caller, _caller, 99]; }; // Record specific callback From 1df42b17c201521bbf3a15529809a1c206093087 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Mon, 20 Apr 2015 22:22:09 +0200 Subject: [PATCH 56/59] close all dialogs --- addons/medical/functions/fnc_setUnconscious.sqf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/medical/functions/fnc_setUnconscious.sqf b/addons/medical/functions/fnc_setUnconscious.sqf index e527215c51..c5809f8c8e 100644 --- a/addons/medical/functions/fnc_setUnconscious.sqf +++ b/addons/medical/functions/fnc_setUnconscious.sqf @@ -37,7 +37,9 @@ _unit setUnconscious true; if (_unit == ACE_player) then { if (visibleMap) then {openMap false}; - closeDialog 0; + while {dialog} do { + closeDialog 0; + }; }; // if we have unconsciousness for AI disabled, we will kill the unit instead From 404eb876312659b0e75eb7b4220c9f3416f0f903 Mon Sep 17 00:00:00 2001 From: ulteq Date: Mon, 20 Apr 2015 22:24:37 +0200 Subject: [PATCH 57/59] Added some ammo class reference data --- extras/CfgAmmoReference.hpp | 2801 +++++++++++++++++++++++++++++++++++ 1 file changed, 2801 insertions(+) create mode 100644 extras/CfgAmmoReference.hpp diff --git a/extras/CfgAmmoReference.hpp b/extras/CfgAmmoReference.hpp new file mode 100644 index 0000000000..85201b92cc --- /dev/null +++ b/extras/CfgAmmoReference.hpp @@ -0,0 +1,2801 @@ +class CfgAmmo +{ + class BulletBase; + class B_556x45_Ball : BulletBase { + airFriction=-0.001265; + hit=8; + typicalSpeed=750; + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.151}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class ACE_556x45_Ball_Mk262 : B_556x45_Ball { + airFriction=-0.001125; + caliber=0.6; + deflecting=18; + hit=11; + typicalSpeed=836; + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=77; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.361}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={624, 816, 832, 838}; + ACE_barrelLengths[]={7.5, 14.5, 18, 20}; + }; + class ACE_556x45_Ball_Mk318 : B_556x45_Ball { + airFriction=-0.001120; + caliber=0.6; + deflecting=18; + hit=9; + typicalSpeed=886; + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.307}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={780, 886, 950}; + ACE_barrelLengths[]={10, 15.5, 20}; + }; + class B_556x45_Ball_Tracer_Red; + class ACE_B_556x45_Ball_Tracer_Dim: B_556x45_Ball_Tracer_Red { + nvgOnly = 1; + }; + class ACE_545x39_Ball_7N6M : B_556x45_Ball { + airFriction=-0.001162; + caliber=0.5; + deflecting=18; + hit=7; + typicalSpeed=880; + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=52.9; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={780, 880, 920}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class B_556x45_Ball_Tracer_Yellow; + class ACE_545x39_Ball_7T3M : B_556x45_Ball_Tracer_Yellow { + airFriction=-0.001162; + caliber=0.5; + deflecting=18; + hit=7; + typicalSpeed=883; + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=49.8; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={785, 883, 925}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class B_65x39_Caseless : BulletBase { + airFriction=-0.000785; + typicalSpeed=800; + ACE_caliber=0.264; + ACE_bulletLength=1.295; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.263}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={730, 760, 788, 800, 810, 830}; + ACE_barrelLengths[]={10, 16, 20, 24, 26, 30}; + }; + class B_65x39_Case_yellow; + class ACE_65x39_Caseless_Tracer_Dim : B_65x39_Case_yellow { + nvgOnly = 1; + }; + class B_65x39_Caseless_green; + class ACE_65x39_Caseless_green_Tracer_Dim : B_65x39_Caseless_green { + nvgOnly = 1; + }; + class ACE_65x47_Ball_Scenar: B_65x39_Caseless + { + airFriction=-0.00078; + typicalSpeed=820 ; + ACE_caliber=0.264; + ACE_bulletLength=1.364; + ACE_bulletMass=139; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.290}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={730, 760, 790, 820, 830}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class B_762x51_Ball : BulletBase { + airFriction=-0.001035; + typicalSpeed=833; + hit=9; + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class B_762x51_Tracer_Yellow; + class ACE_B_762x51_Tracer_Dim: B_762x51_Tracer_Yellow { + nvgOnly = 1; + }; + class ACE_762x51_Ball_M118LR : B_762x51_Ball { + airFriction=-0.0008525; + caliber=1.05; + hit=16; + typicalSpeed=790; + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=175; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.243}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={750, 780, 790, 794}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class ACE_762x51_Ball_Mk319_Mod_0 : B_762x51_Ball { + airFriction=-0.00103; + caliber=0.85; + hit=14; + typicalSpeed=890; + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=130; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.377}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={838, 892, 910}; + ACE_barrelLengths[]={13, 16, 20}; + }; + class ACE_762x51_Ball_Subsonic : B_762x51_Ball { + airFriction=-0.000535; + caliber=0.5; + hit=6; + typicalSpeed=790; + ACE_caliber=0.308; + ACE_bulletLength=1.340; + ACE_bulletMass=200; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.235}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={305, 325, 335, 340}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class ACE_762x67_Ball_Mk248_Mod_0 : B_762x51_Ball { + airFriction=-0.000830; + caliber=1.08; + hit=17; + typicalSpeed=900; + ACE_caliber=0.308; + ACE_bulletLength=1.353; + ACE_bulletMass=190; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.268}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={865, 900, 924}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class ACE_762x67_Ball_Mk248_Mod_1 : B_762x51_Ball { + airFriction=-0.000815; + caliber=1.12; + hit=18; + typicalSpeed=867; + ACE_caliber=0.308; + ACE_bulletLength=1.489; + ACE_bulletMass=220; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.310}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={847, 867, 877}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class ACE_762x67_Ball_Berger_Hybrid_OTM : B_762x51_Ball { + airFriction=-0.00076; + caliber=1.15; + hit=19; + typicalSpeed=853; + ACE_caliber=0.308; + ACE_bulletLength=1.602; + ACE_bulletMass=230; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.368}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={800, 853, 884}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class B_762x54_Ball: B_762x51_Ball { + airFriction=-0.001023; + typicalSpeed=820; + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=152; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.4}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={700, 800, 820, 833}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class ACE_762x54_Ball_7N14 : B_762x51_Ball { + airFriction=-0.001023; + caliber=0.95; + hit=15; + typicalSpeed=820; + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=152; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.4}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={700, 800, 820, 833}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class B_762x54_Tracer_Green; + class ACE_762x54_Ball_7T2 : B_762x54_Tracer_Green { + airFriction=-0.001023; + caliber=0.9; + hit=15; + typicalSpeed=800; + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=149; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.395}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 750, 798, 800}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class ACE_762x35_Ball : B_762x51_Ball { + airFriction=-0.000821; + caliber=0.9; + hit=11; + typicalSpeed=790; + ACE_caliber=0.308; + ACE_bulletLength=1.153; + ACE_bulletMass=125; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.349, 0.338, 0.330, 0.310}; + ACE_velocityBoundaries[]={792, 610, 488}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={620, 655, 675}; + ACE_barrelLengths[]={9, 16, 20}; + }; + class ACE_762x39_Ball : B_762x51_Ball { + airFriction=-0.0015168; + hit=12; + typicalSpeed=716; + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class ACE_762x39_Ball_57N231P : B_762x51_Tracer_Yellow { + airFriction=-0.0015168; + hit=12; + typicalSpeed=716; + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=117; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class B_9x21_Ball : BulletBase { + airFriction=-0.00125; + typicalSpeed=390; + hit=6; + ACE_caliber=0.356; + ACE_bulletLength=0.610; + ACE_bulletMass=115; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.17}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={440, 460, 480}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class ACE_9x18_Ball_57N181S : B_9x21_Ball { + hit=5; + airFriction=-0.001234; + typicalSpeed=298; + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class ACE_9x19_Ball : B_9x21_Ball { + airFriction=-0.001234; + typicalSpeed=370; + hit=6; + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class ACE_10x25_Ball : B_9x21_Ball { + airFriction=-0.00168; + typicalSpeed=425; + hit=7; + ACE_caliber=0.5; + ACE_bulletLength=0.764; + ACE_bulletMass=165; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.189}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={360, 400, 430}; + ACE_barrelLengths[]={4, 4.61, 9}; + }; + class ACE_765x17_Ball: B_9x21_Ball { + airFriction=-0.001213; + typicalSpeed=282; + hit=7; + ACE_caliber=0.3125; + ACE_bulletLength=0.610; + ACE_bulletMass=65; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.118}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={282, 300, 320}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class ACE_303_Ball : ACE_762x51_Ball_M118LR { + airFriction=-0.00083; + typicalSpeed=761; + ACE_caliber=0.311; + ACE_bulletLength=1.227; + ACE_bulletMass=174; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.499, 0.493, 0.48}; + ACE_velocityBoundaries[]={671, 549}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={748, 761, 765}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class B_93x64_Ball : BulletBase { + airFriction=-0.00106; + typicalSpeed=880; + ACE_caliber=0.366; + ACE_bulletLength=1.350; + ACE_bulletMass=230; + ACE_transonicStabilityCoef=1; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.368}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={850, 870, 880}; + ACE_barrelLengths[]={20, 24.41, 26}; + }; + class B_408_Ball : BulletBase { + timeToLive=10; + airFriction=-0.000395; + typicalSpeed=910; + ACE_caliber=0.408; + ACE_bulletLength=2.126; + ACE_bulletMass=410; + ACE_transonicStabilityCoef=1; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.97}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={910}; + ACE_barrelLengths[]={29}; + }; + class ACE_106x83mm_Ball : B_408_Ball { + timeToLive=10; + ACE_caliber=0.416; + ACE_bulletLength=2.089; + ACE_bulletMass=398; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.72}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={960}; + ACE_barrelLengths[]={29}; + }; + class B_338_Ball : BulletBase { + timeToLive=10; + airFriction=-0.000606; + typicalSpeed=915; + ACE_caliber=0.338; + ACE_bulletLength=1.558; + ACE_bulletMass=250; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.322}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={880, 915, 925}; + ACE_barrelLengths[]={20, 26, 28}; + }; + class B_338_NM_Ball : BulletBase { + airFriction=-0.000537; + typicalSpeed=820; + ACE_caliber=0.338; + ACE_bulletLength=1.70; + ACE_bulletMass=300; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.381}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={790, 807, 820}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class ACE_338_Ball : B_338_Ball { + timeToLive=10; + airFriction=-0.000535; + caliber=1.55; + typicalSpeed=826; + ACE_caliber=0.338; + ACE_bulletLength=1.70; + ACE_bulletMass=300; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.381}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={800, 820, 826, 830}; + ACE_barrelLengths[]={20, 24, 26.5, 28}; + }; + class ACE_338_Ball_API526 : B_338_Ball { + timeToLive=10; + airFriction=-0.000673; + caliber=2.4; + typicalSpeed=826; + ACE_caliber=0.338; + ACE_bulletLength=1.535; + ACE_bulletMass=253; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.290}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={880, 915, 925}; + ACE_barrelLengths[]={20, 26, 28}; + }; + class B_127x54_Ball : BulletBase { + airFriction=-0.00014; + typicalSpeed=300; + ACE_caliber=0.510; + ACE_bulletLength=2.540; + ACE_bulletMass=750; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={1.050}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={300}; + ACE_barrelLengths[]={17.2}; + }; + class B_127x99_Ball : BulletBase { + timeToLive=10; + airFriction=-0.0006; + typicalSpeed=853; + ACE_caliber=0.510; + ACE_bulletLength=2.310; + ACE_bulletMass=647; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.670}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={853}; + ACE_barrelLengths[]={29}; + }; + class ACE_127x99_Ball_AMAX : B_127x99_Ball { + timeToLive=10; + airFriction=-0.000374; + typicalSpeed=860; + ACE_caliber=0.510; + ACE_bulletLength=2.540; + ACE_bulletMass=750; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={1.050}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={860}; + ACE_barrelLengths[]={29}; + }; + class B_127x108_Ball : BulletBase { + timeToLive=10; + airFriction=-0.00064; + typicalSpeed=820; + ACE_caliber=0.511; + ACE_bulletLength=2.520; + ACE_bulletMass=745; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.63}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={820}; + ACE_barrelLengths[]={28.7}; + }; + class B_45ACP_Ball : BulletBase { + airFriction=-0.0007182; + typicalSpeed=250; + ACE_caliber=0.452; + ACE_bulletLength=0.68; + ACE_bulletMass=230; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.195}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={230, 250, 285}; + ACE_barrelLengths[]={4, 5, 9}; + }; + + class TMR_B_762x51_M118LR : B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=175; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.505, 0.496, 0.485, 0.485, 0.485}; + ACE_velocityBoundaries[]={853, 549, 549, 549}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={750, 780, 790, 794}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + + class RH_50_AE_Ball: BulletBase + { + ACE_caliber=0.5; + ACE_bulletLength=1.110; + ACE_bulletMass=325; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.228}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={360, 398, 420}; + ACE_barrelLengths[]={4, 6, 9}; + }; + class RH_454_Casull: BulletBase + { + ACE_caliber=0.452; + ACE_bulletLength=0.895; + ACE_bulletMass=325; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.171}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={450, 490, 500}; + ACE_barrelLengths[]={4, 7.5, 9}; + }; + class RH_32ACP: BulletBase + { + ACE_caliber=0.3125; + ACE_bulletLength=0.610; + ACE_bulletMass=65; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.118}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={282, 300, 320}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class RH_45ACP: BulletBase + { + ACE_caliber=0.452; + ACE_bulletLength=0.68; + ACE_bulletMass=230; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.195}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={230, 250, 285}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class RH_B_40SW: BulletBase + { + ACE_caliber=0.4; + ACE_bulletLength=0.447; + ACE_bulletMass=135; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.105, 0.115, 0.120, 0.105}; + ACE_velocityBoundaries[]={365, 305, 259}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={360, 380, 400}; + ACE_barrelLengths[]={4, 6, 9}; + }; + class RH_44mag_ball: BulletBase + { + ACE_caliber=0.429; + ACE_bulletLength=0.804; + ACE_bulletMass=200; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.172}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={360, 390, 420}; + ACE_barrelLengths[]={4, 7.5, 9}; + }; + class RH_357mag_ball: BulletBase + { + ACE_caliber=0.357; + ACE_bulletLength=0.541; + ACE_bulletMass=125; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.148}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={490, 510, 535}; + ACE_barrelLengths[]={4, 6, 9}; + }; + class RH_762x25: BulletBase + { + ACE_caliber=0.310; + ACE_bulletLength=0.5455; + ACE_bulletMass=86; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.17}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={360, 380, 400}; + ACE_barrelLengths[]={4, 6, 9}; + }; + class RH_9x18_Ball: BulletBase + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class RH_B_9x19_Ball: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class RH_B_22LR_SD: BulletBase + { + ACE_caliber=0.223; + ACE_bulletLength=0.45; + ACE_bulletMass=38; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.111}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={330, 340, 360}; + ACE_barrelLengths[]={4, 6, 9}; + }; + class RH_57x28mm: BulletBase + { + ACE_caliber=0.224; + ACE_bulletLength=0.495; + ACE_bulletMass=28; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.144}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={550, 625, 720}; + ACE_barrelLengths[]={4, 6, 10.35}; + }; + + class RH_9x19_B_M822: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class RH_9x19_B_HP: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class RH_9x19_B_HPSB: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.603; + ACE_bulletMass=147; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.212}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={295, 310, 330}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class RH_B_6x35: BulletBase + { + ACE_caliber=0.224; + ACE_bulletLength=0.445; + ACE_bulletMass=65; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.26}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={730, 750, 760}; + ACE_barrelLengths[]={8, 10, 12}; + }; + class RH_556x45_B_M855A1 : B_556x45_Ball + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.152}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class RH_556x45_B_Mk262 : B_556x45_Ball + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=77; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.361}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={624, 816, 832, 838}; + ACE_barrelLengths[]={7.5, 14.5, 18, 20}; + }; + class RH_556x45_B_Mk318 : B_556x45_Ball + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.307}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={780, 886, 950}; + ACE_barrelLengths[]={10, 15.5, 20}; + }; + class RH_68x43_B_FMJ: B_65x39_Caseless + { + ACE_caliber=0.277; + ACE_bulletLength=0.959; + ACE_bulletMass=115; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.162}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={713, 785, 810, 850}; + ACE_barrelLengths[]={12, 16, 20, 24}; + }; + class RH_68x43_B_Match: B_65x39_Caseless + { + ACE_caliber=0.277; + ACE_bulletLength=1.250; + ACE_bulletMass=135; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.253}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 732, 750, 780}; + ACE_barrelLengths[]={12, 16, 20, 24}; + }; + class RH_762x35_B_FMJ: B_65x39_Caseless + { + ACE_caliber=0.308; + ACE_bulletLength=1.118; + ACE_bulletMass=147; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.398}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={559, 609, 625}; + ACE_barrelLengths[]={6, 16, 20}; + }; + class RH_762x35_B_Match: B_65x39_Caseless + { + ACE_caliber=0.308; + ACE_bulletLength=1.153; + ACE_bulletMass=125; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.349, 0.338, 0.330, 0.310}; + ACE_velocityBoundaries[]={792, 610, 488}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={590, 650, 665}; + ACE_barrelLengths[]={6, 16, 20}; + }; + class RH_762x35_B_MSB: B_65x39_Caseless + { + ACE_caliber=0.308; + ACE_bulletLength=1.489; + ACE_bulletMass=220; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.608}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={300, 320, 340}; + ACE_barrelLengths[]={9, 16, 20}; + }; + class RH_762x51_B_M80A1 : B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class RH_762x51_B_Mk316LR : B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=175; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.243}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={750, 780, 790, 794}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class RH_762x51_B_Mk319 : B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.074; + ACE_bulletMass=130; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.277}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={838, 892, 920}; + ACE_barrelLengths[]={13, 16, 20}; + }; + class RH_762x51_B_LFMJSB: B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.340; + ACE_bulletMass=200; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.252}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={305, 325, 335, 340}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + + class HLC_556NATO_SOST: BulletBase + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.307}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={780, 886, 950}; + ACE_barrelLengths[]={10, 15.5, 20}; + }; + class HLC_556NATO_SPR: BulletBase + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=77; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.361}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={624, 816, 832, 838}; + ACE_barrelLengths[]={7.5, 14.5, 18, 20}; + }; + class HLC_556NATO_EPR: BulletBase + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.152}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class HLC_300Blackout_Ball: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.118; + ACE_bulletMass=147; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.398}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={559, 609, 625}; + ACE_barrelLengths[]={6, 16, 20}; + }; + class HLC_300Blackout_SMK: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.489; + ACE_bulletMass=220; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.608}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={300, 320, 340}; + ACE_barrelLengths[]={9, 16, 20}; + }; + class HLC_762x51_BTSub: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.340; + ACE_bulletMass=200; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.235}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={305, 325, 335, 340}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class HLC_762x54_ball: BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=152; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.4}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={700, 800, 820, 833}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class HLC_762x54_tracer: BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=149; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.395}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 750, 798, 800}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class HLC_303Brit_B: BulletBase + { + ACE_caliber=0.311; + ACE_bulletLength=1.227; + ACE_bulletMass=174; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.499, 0.493, 0.48}; + ACE_velocityBoundaries[]={671, 549}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={748, 761, 765}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class HLC_792x57_Ball: BulletBase + { + ACE_caliber=0.318; + ACE_bulletLength=1.128; + ACE_bulletMass=196; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.315}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={785, 800, 815}; + ACE_barrelLengths[]={20, 23.62, 26}; + }; + class FH_545x39_Ball: BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=52.9; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={780, 880, 920}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class FH_545x39_7u1: FH_545x39_Ball + { + ACE_bulletMass=80; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_muzzleVelocities[]={260, 303, 320}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class HLC_9x19_Ball: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class HLC_9x19_GoldDot: HLC_9x19_Ball + { + ACE_muzzleVelocities[]={350, 380, 420}; + }; + class HLC_9x19_Subsonic: HLC_9x19_Ball + { + ACE_muzzleVelocities[]={300, 320, 340}; + }; + class HLC_10mm_FMJ: HLC_9x19_Ball + { + ACE_caliber=0.5; + ACE_bulletLength=0.764; + ACE_bulletMass=165; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.189}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={360, 400, 430}; + ACE_barrelLengths[]={4, 4.61, 9}; + }; + class HLC_9x19_M882_SMG: HLC_9x19_Ball + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + + class M_mas_545x39_Ball_7N6M : BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=52.9; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={780, 880, 920}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class M_mas_545x39_Ball_7T3M : BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=49.8; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={785, 883, 925}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class B_mas_556x45_Ball_Mk262 : B_556x45_Ball + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=77; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.361}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={624, 816, 832, 838}; + ACE_barrelLengths[]={7.5, 14.5, 18, 20}; + }; + class B_mas_9x18_Ball_57N181S : BulletBase + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class B_mas_9x21p_Ball: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class B_mas_9x21_Ball: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class B_mas_9x21d_Ball: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={210, 250, 285}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class B_mas_765x17_Ball: BulletBase + { + ACE_caliber=0.3125; + ACE_bulletLength=0.610; + ACE_bulletMass=65; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.118}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={282, 300, 320}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class B_mas_762x39_Ball: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class B_mas_762x39_Ball_T: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=117; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class B_mas_762x51_Ball_M118LR : B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=175; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.505, 0.496, 0.485, 0.485, 0.485}; + ACE_velocityBoundaries[]={853, 549, 549, 549}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={750, 780, 790, 794}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class B_mas_762x67_Ball_Mk248_Mod_0 : B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.353; + ACE_bulletMass=190; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.268}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={865, 900, 924}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class B_mas_762x67_Ball_Mk248_Mod_1 : B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.489; + ACE_bulletMass=220; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.310}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={820, 867, 900}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class B_mas_762x67_Ball_Berger_Hybrid_OTM : B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.602; + ACE_bulletMass=230; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.368}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={800, 853, 884}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class B_mas_762x54_Ball : BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=152; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.4}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={700, 800, 820, 833}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class B_mas_762x54_Ball_T : BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=149; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.395}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 750, 798, 800}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class BWA3_B_762x51_Ball_LR : BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=175; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.505, 0.496, 0.485, 0.485, 0.485}; + ACE_velocityBoundaries[]={853, 549, 549, 549}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={750, 780, 790, 794}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class BWA3_B_762x51_Ball_SD : BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=175; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={300, 340}; + ACE_barrelLengths[]={16, 24}; + }; + + class BWA3_B_46x30_Ball : BulletBase + { + ACE_caliber=0.193; + ACE_bulletLength=0.512; + ACE_bulletMass=31; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.1455}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 720, 730, 740}; + ACE_barrelLengths[]={4, 7, 9, 12}; + }; + + class Trixie_338_Ball : BulletBase + { + ACE_caliber=0.338; + ACE_bulletLength=1.70; + ACE_bulletMass=300; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.381}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={820, 826, 830}; + ACE_barrelLengths[]={24, 26.5, 28}; + }; + class Trixie_303_Ball : BulletBase + { + ACE_caliber=0.311; + ACE_bulletLength=1.227; + ACE_bulletMass=174; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.499, 0.493, 0.48}; + ACE_velocityBoundaries[]={671, 549}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={748, 761, 765}; + ACE_barrelLengths[]={20, 24, 26}; + }; + + class rhs_ammo_556x45_Mk318_Ball : BulletBase + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.307}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={780, 886, 950}; + ACE_barrelLengths[]={10, 15.5, 20}; + }; + class rhs_ammo_556x45_Mk262_Ball : BulletBase + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=77; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.361}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={624, 816, 832, 838}; + ACE_barrelLengths[]={7.5, 14.5, 18, 20}; + }; + class rhsammo_762x51_Ball : BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class rhs_B_545x39_Ball : BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=52.9; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={780, 880, 920}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class rhs_B_545x39_Ball_Tracer_Green : BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=49.8; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={785, 883, 925}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class rhs_ammo_762x51_M118_Special_Ball : BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=175; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.243}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={750, 780, 790, 794}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class rhs_B_762x54_Ball : BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=152; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.4}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={700, 800, 820, 833}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class rhs_B_762x54_Ball_Tracer_Green : BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=149; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.395}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 750, 798, 800}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class rhs_B_762x39_Ball : BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class rhs_B_762x39_Tracer : BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=117; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class rhs_ammo_762x51_M80_Ball : BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class rhsusf_B_300winmag : BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.489; + ACE_bulletMass=220; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.310}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={847, 867, 877}; + ACE_barrelLengths[]={20, 24, 26}; + }; + + class R3F_9x19_Ball: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class R3F_556x45_Ball: BulletBase + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.151}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class R3F_762x51_Ball: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class R3F_762x51_Ball2: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=175; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.505, 0.496, 0.485, 0.485, 0.485}; + ACE_velocityBoundaries[]={853, 549, 549, 549}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={750, 780, 790, 794}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class R3F_127x99_Ball: BulletBase + { + ACE_caliber=0.510; + ACE_bulletLength=2.310; + ACE_bulletMass=647; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.670}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={853}; + ACE_barrelLengths[]={29}; + }; + class R3F_127x99_Ball2: BulletBase + { + ACE_caliber=0.510; + ACE_bulletLength=2.310; + ACE_bulletMass=647; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.670}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={853}; + ACE_barrelLengths[]={29}; + }; + + class CUP_B_545x39_Ball: BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=52.9; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={780, 880, 920}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class CUP_B_545x39_Ball_Tracer_Green: BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=49.8; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={785, 883, 925}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class CUP_B_545x39_Ball_Tracer_Red: BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=49.8; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={785, 883, 925}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class CUP_B_545x39_Ball_Tracer_White: BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=49.8; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={785, 883, 925}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class CUP_B_545x39_Ball_Tracer_Yellow: BulletBase + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=49.8; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={785, 883, 925}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class CUP_B_762x39_Ball: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class CUP_B_762x39_Ball_Tracer_Green: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=117; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class B_762x39mm_KLT: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class CUP_B_9x18_Ball: BulletBase + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class CUP_B_9x18_Ball_Tracer_Green: BulletBase + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class CUP_B_9x18_Ball_Tracer_Red: BulletBase + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class CUP_B_9x18_Ball_Tracer_Yellow: BulletBase + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class CUP_B_9x18_Ball_White_Tracer: BulletBase + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class CUP_B_9x19_Ball: BulletBase + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class CUP_B_762x51_noTracer: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class CUP_B_762x51_Red_Tracer_3RndBurst: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class CUP_B_762x51_White_Tracer_3RndBurst: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class CUP_B_303_Ball: BulletBase + { + ACE_caliber=0.311; + ACE_bulletLength=1.227; + ACE_bulletMass=174; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.499, 0.493, 0.48}; + ACE_velocityBoundaries[]={671, 549}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={748, 761, 765}; + ACE_barrelLengths[]={20, 24, 26}; + }; + class CUP_B_127x107_Ball_Green_Tracer: BulletBase + { + ACE_caliber=0.511; + ACE_bulletLength=2.520; + ACE_bulletMass=745; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.63}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={820}; + ACE_barrelLengths[]={28.7}; + }; + class CUP_B_127x108_Ball_Green_Tracer: BulletBase + { + ACE_caliber=0.511; + ACE_bulletLength=2.520; + ACE_bulletMass=745; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.63}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={820}; + ACE_barrelLengths[]={28.7}; + }; + class CUP_B_762x54_Ball_White_Tracer: BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=149; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.395}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 750, 798, 800}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class CUP_B_762x54_Ball_Red_Tracer: BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=149; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.395}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 750, 798, 800}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class CUP_B_762x54_Ball_Green_Tracer: BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=149; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.395}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 750, 798, 800}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class CUP_B_762x54_Ball_Yellow_Tracer: BulletBase + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=149; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.395}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 750, 798, 800}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class CUP_B_9x39_SP5: BulletBase + { + ACE_caliber=0.364; + ACE_bulletLength=1.24; + ACE_bulletMass=250; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={280, 300, 320}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class CUP_B_762x51_Tracer_Green: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class CUP_B_762x51_Tracer_Red: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class CUP_B_762x51_Tracer_Yellow: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class CUP_B_762x51_Tracer_White: BulletBase + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class B_127x107_Ball: BulletBase + { + ACE_caliber=0.511; + ACE_bulletLength=2.520; + ACE_bulletMass=745; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.63}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={820}; + ACE_barrelLengths[]={28.7}; + }; + class CUP_B_9x18_SD: BulletBase + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 340}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class CUP_B_765x17_Ball: BulletBase + { + ACE_caliber=0.3125; + ACE_bulletLength=0.610; + ACE_bulletMass=65; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.118}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={282, 300, 320}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class CUP_B_145x115_AP_Green_Tracer: BulletBase + { + ACE_caliber=0.586; + ACE_bulletLength=2.00; + ACE_bulletMass=1010; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.620}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={1000}; + ACE_barrelLengths[]={53}; + }; + class CUP_B_127x99_Ball_White_Tracer: BulletBase + { + ACE_caliber=0.510; + ACE_bulletLength=2.310; + ACE_bulletMass=647; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.670}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={853}; + ACE_barrelLengths[]={29}; + }; + class CUP_B_86x70_Ball_noTracer: BulletBase + { + ACE_caliber=0.338; + ACE_bulletLength=1.70; + ACE_bulletMass=300; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.381}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={820, 826, 830}; + ACE_barrelLengths[]={24, 26.5, 28}; + }; + + class VTN_9x18_Ball_FMJ: B_9x21_Ball + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class VTN_9x18_Ball_SC: VTN_9x18_Ball_FMJ + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class VTN_9x18_Ball_TRC: VTN_9x18_Ball_FMJ + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class VTN_9x18_Ball_AP1: VTN_9x18_Ball_FMJ + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class VTN_9x18_Ball_AP2: VTN_9x18_Ball_FMJ + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class VTN_9x18_Ball_PRS: VTN_9x18_Ball_FMJ + { + ACE_caliber=0.365; + ACE_bulletLength=0.610; + ACE_bulletMass=92.6; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.125}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={298, 330, 350}; + ACE_barrelLengths[]={3.8, 5, 9}; + }; + class VTN_9x19_Ball_SC: VTN_9x18_Ball_FMJ + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class VTN_9x19_Ball_TRC: VTN_9x19_Ball_SC + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class VTN_9x19_Ball_AP: VTN_9x19_Ball_SC + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class VTN_9x19_Ball_PRS: VTN_9x19_Ball_SC + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class VTN_9x39_Ball_SC: B_9x21_Ball + { + ACE_caliber=0.364; + ACE_bulletLength=1.24; + ACE_bulletMass=250; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={280, 300, 320}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_9x39_Ball_AP: VTN_9x39_Ball_SC + { + ACE_caliber=0.364; + ACE_bulletLength=1.24; + ACE_bulletMass=250; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={280, 300, 320}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_545x39_Ball_SC: B_556x45_Ball + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=52.9; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={780, 880, 920}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_545x39_Ball_TRC: VTN_545x39_Ball_SC + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=49.8; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={785, 883, 925}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_545x39_Ball_AP: VTN_545x39_Ball_TRC + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=52.9; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={780, 880, 920}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_545x39_Ball_AP2: VTN_545x39_Ball_AP + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=52.9; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={780, 880, 920}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_545x39_Ball_SS: VTN_545x39_Ball_SC + { + ACE_caliber=0.220; + ACE_bulletLength=0.85; + ACE_bulletMass=52.9; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.168}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={300, 320, 340}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_762x39_Ball_SC: B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_762x39_Ball_TRC: VTN_762x39_Ball_SC + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=117; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_762x39_Ball_AP: VTN_762x39_Ball_TRC + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_762x39_Ball_INC: VTN_762x39_Ball_AP + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_762x39_Ball_API: VTN_762x39_Ball_INC + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_762x39_Ball_SS: VTN_762x39_Ball_SC + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={300, 320, 340}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_762x41_Ball_SS: B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=0.53; + ACE_bulletMass=143; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={200, 210, 220}; + ACE_barrelLengths[]={4, 6, 8}; + }; + class VTN_762x54_Ball_SC: VTN_762x39_Ball_SC + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=152; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.4}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={700, 800, 820, 833}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class VTN_762x54_Ball_TRC: VTN_762x54_Ball_SC + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=149; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.395}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={680, 750, 798, 800}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class VTN_762x54_Ball_AP: VTN_762x54_Ball_TRC + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=152; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.4}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={700, 800, 820, 833}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class VTN_762x54_Ball_INC: VTN_762x54_Ball_AP + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=152; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.4}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={700, 800, 820, 833}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class VTN_762x54_Ball_API: VTN_762x54_Ball_INC + { + ACE_caliber=0.312; + ACE_bulletLength=1.14; + ACE_bulletMass=152; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.4}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={700, 800, 820, 833}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class VTN_145x114_Ball_APT: B_127x108_Ball + { + ACE_caliber=0.586; + ACE_bulletLength=2.00; + ACE_bulletMass=1010; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.620}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={1000}; + ACE_barrelLengths[]={53}; + }; + class VTN_6mm_BB: B_65x39_Caseless + { + ACE_caliber=0.24; + ACE_bulletLength=0.24; + ACE_bulletMass=6; + ACE_ammoTempMuzzleVelocityShifts[]={}; + ACE_ballisticCoefficients[]={}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={100}; + ACE_barrelLengths[]={15}; + }; + class VTN_9x19_Ball_FMJ: B_9x21_Ball + { + ACE_caliber=0.355; + ACE_bulletLength=0.610; + ACE_bulletMass=124; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.165}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={340, 370, 400}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class VTN_556x45_Ball_FMJ: B_556x45_Ball + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.151}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class VTN_556x45_Ball_TRC: VTN_556x45_Ball_FMJ + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.151}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class VTN_556x45_Ball_TRCN: VTN_556x45_Ball_TRC + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.151}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class VTN_556x45_Ball_SC: VTN_556x45_Ball_FMJ + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.151}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class VTN_556x45_Ball_AP: VTN_556x45_Ball_TRC + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.151}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class VTN_556x45_Ball_INC: VTN_556x45_Ball_AP + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-27.20, -26.44, -23.76, -21.00, -17.54, -13.10, -7.95, -1.62, 6.24, 15.48, 27.75}; + ACE_ballisticCoefficients[]={0.151}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={723, 764, 796, 825, 843, 866, 878, 892, 906, 915, 922, 900}; + ACE_barrelLengths[]={8.3, 9.4, 10.6, 11.8, 13.0, 14.2, 15.4, 16.5, 17.7, 18.9, 20.0, 24.0}; + }; + class VTN_556x45_Ball_LR: VTN_556x45_Ball_FMJ + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=77; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.361}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={624, 816, 832, 838}; + ACE_barrelLengths[]={7.5, 14.5, 18, 20}; + }; + class VTN_556x45_Ball_SS: B_556x45_Ball + { + ACE_caliber=0.224; + ACE_bulletLength=0.906; + ACE_bulletMass=62; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.151}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={300, 320, 340}; + ACE_barrelLengths[]={10, 20.0, 24.0}; + }; + class VTN_762x51_Ball_SC: B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class VTN_762x51_Ball_TRC: VTN_762x51_Ball_SC + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class VTN_762x51_Ball_TRCN: VTN_762x51_Ball_TRC + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class VTN_762x51_Ball_AP: VTN_762x51_Ball_TRC + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=146; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.2}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={700, 800, 820, 833, 845}; + ACE_barrelLengths[]={10, 16, 20, 24, 26}; + }; + class VTN_762x51_Ball_LR: VTN_762x51_Ball_SC + { + ACE_caliber=0.308; + ACE_bulletLength=1.24; + ACE_bulletMass=175; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.243}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=7; + ACE_muzzleVelocities[]={750, 780, 790, 794}; + ACE_barrelLengths[]={16, 20, 24, 26}; + }; + class VTN_1143x23_Ball_FMJ: B_408_Ball + { + ACE_caliber=0.452; + ACE_bulletLength=0.68; + ACE_bulletMass=230; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.195}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={230, 250, 285}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class VTN_1143x23_Ball_HP: VTN_1143x23_Ball_FMJ + { + ACE_caliber=0.452; + ACE_bulletLength=0.68; + ACE_bulletMass=230; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.195}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={230, 250, 285}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class VTN_1143x23_Ball_JHP: VTN_1143x23_Ball_FMJ + { + ACE_caliber=0.452; + ACE_bulletLength=0.68; + ACE_bulletMass=230; + ACE_ammoTempMuzzleVelocityShifts[]={-2.655, -2.547, -2.285, -2.012, -1.698, -1.280, -0.764, -0.153, 0.596, 1.517, 2.619}; + ACE_ballisticCoefficients[]={0.195}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ASM"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={230, 250, 285}; + ACE_barrelLengths[]={4, 5, 9}; + }; + class VTN_762x39_Ball_FMJ: B_762x51_Ball + { + ACE_caliber=0.308; + ACE_bulletLength=1.14; + ACE_bulletMass=123; + ACE_ammoTempMuzzleVelocityShifts[]={-26.55, -25.47, -22.85, -20.12, -16.98, -12.80, -7.64, -1.53, 5.96, 15.17, 26.19}; + ACE_ballisticCoefficients[]={0.275}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={650, 716, 750}; + ACE_barrelLengths[]={10, 16.3, 20}; + }; + class VTN_45_Pellet: B_762x51_Ball + { + ACE_caliber=0.22; + ACE_bulletLength=0.23; + ACE_bulletMass=3; + ACE_ammoTempMuzzleVelocityShifts[]={}; + ACE_ballisticCoefficients[]={}; + ACE_velocityBoundaries[]={}; + ACE_standardAtmosphere="ICAO"; + ACE_dragModel=1; + ACE_muzzleVelocities[]={100, 138, 150}; + ACE_barrelLengths[]={5, 10, 16}; + }; +}; \ No newline at end of file From 387572c56018a4d965f94754bfea5be36ed1f7fd Mon Sep 17 00:00:00 2001 From: ulteq Date: Mon, 20 Apr 2015 22:29:15 +0200 Subject: [PATCH 58/59] Added some weapon class reference data --- extras/CfgWeaponsReference.hpp | 1894 ++++++++++++++++++++++++++++++++ 1 file changed, 1894 insertions(+) create mode 100644 extras/CfgWeaponsReference.hpp diff --git a/extras/CfgWeaponsReference.hpp b/extras/CfgWeaponsReference.hpp new file mode 100644 index 0000000000..77ce494e39 --- /dev/null +++ b/extras/CfgWeaponsReference.hpp @@ -0,0 +1,1894 @@ +class CfgWeapons +{ + class MGun; + class MGunCore; + class Pistol_Base_F; + class Rifle_Base_F; + class Rifle_Long_Base_F; + class arifle_MX_Base_F; + class PDW2000_Base_F; + class arifle_Katiba_Base_F; + class SDAR_base_F; + class SMG_02_Base_F; + class Tavor_base_F; + class SMG_01_Base; + class DMR_01_base_F; + class Mk20_Base_F; + class EBR_base_F; + class HMG_127; + class LRR_base_F; + class GM6_base_F; + class DMR_02_base_F; + class DMR_03_base_F; + class DMR_04_base_F; + class DMR_05_base_F; + class DMR_06_base_F; + class MMG_01_base_F; + class MMG_02_base_F; + class hgun_P07_F : Pistol_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=4; + }; + class hgun_Rook40_F : Pistol_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=4.4; + }; + class hgun_Pistol_heavy_01_F : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=4.5; + }; + class hgun_Pistol_heavy_02_F : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=3; + }; + class hgun_ACPC2_F : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=5; + }; + class hgun_PDW2000_F : PDW2000_Base_F + { + ACE_barrelTwist=9; + ACE_barrelLength=7; + }; + class arifle_Katiba_F : arifle_Katiba_Base_F + { + ACE_barrelTwist=8; + ACE_barrelLength=28.7; + }; + class arifle_Katiba_C_F : arifle_Katiba_Base_F + { + ACE_barrelTwist=8; + ACE_barrelLength=26.8; + }; + class arifle_Katiba_GL_F : arifle_Katiba_Base_F + { + ACE_barrelTwist=8; + ACE_barrelLength=28.7; + }; + class arifle_MX_F: arifle_MX_Base_F + { + ACE_barrelTwist=9; + ACE_barrelLength=14.5; + }; + class arifle_MX_GL_F: arifle_MX_Base_F + { + ACE_barrelTwist=9; + ACE_barrelLength=14.5; + }; + class arifle_MX_SW_F: arifle_MX_Base_F + { + ACE_barrelTwist=9; + ACE_barrelLength=16.0; + }; + class arifle_MXC_F: arifle_MX_Base_F + { + ACE_barrelTwist=8; + ACE_barrelLength=10.5; + }; + class arifle_MXM_F: arifle_MX_Base_F + { + ACE_barrelTwist=9; + ACE_barrelLength=18; + }; + class arifle_SDAR_F : SDAR_base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=18; + }; + class SMG_02_F : SMG_02_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=7.7; + }; + class arifle_TRG20_F : Tavor_base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=15; + }; + class arifle_TRG21_F : Tavor_base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18.1; + }; + class LMG_Zafir_F : Rifle_Long_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=18.1; + }; + class arifle_Mk20_F : Mk20_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=17.4; + }; + class arifle_Mk20C_F : Mk20_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16; + }; + class arifle_Mk20_GL_F : Mk20_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16; + }; + class SMG_01_F : SMG_01_Base + { + ACE_barrelTwist=16; + ACE_barrelLength=5.5; + }; + class srifle_DMR_01_F : DMR_01_base_F + { + ACE_barrelTwist=9.5; + ACE_barrelLength=24; + }; + class srifle_EBR_F : EBR_base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24; + }; + class LMG_Mk200_F : Rifle_Long_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=12.5; + }; + class srifle_LRR_F : LRR_base_F + { + ACE_barrelTwist=13; + ACE_barrelLength=29; + }; + class srifle_GM6_F : GM6_base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=43.3; + }; + class srifle_DMR_02_F: DMR_02_base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=26; + }; + class srifle_DMR_03_F: DMR_03_base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=20; + }; + class srifle_DMR_04_F: DMR_04_base_F + { + ACE_barrelTwist=8; + ACE_barrelLength=17.72; + }; + class srifle_DMR_05_blk_F: DMR_05_base_F + { + ACE_barrelTwist=14.17; + ACE_barrelLength=24.41; + }; + class srifle_DMR_06_camo_F: DMR_06_base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=22; + }; + class MMG_01_hex_F: MMG_01_base_F + { + ACE_barrelTwist=14.17; + ACE_barrelLength=21.65; + }; + class MMG_02_camo_F: MMG_02_base_F + { + ACE_barrelTwist=9.25; + ACE_barrelLength=24; + }; + class HMG_M2 : HMG_127 + { + ACE_barrelTwist=12; + ACE_barrelLength=45; + }; + + class RH_deagle : Pistol_Base_F + { + ACE_barrelTwist=19; + ACE_barrelLength=6; + }; + class RH_sw659 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=7.44; + }; + class RH_usp : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=4.41; + }; + class RH_uspm : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=6; + }; + class RH_mak : Pistol_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=3.68; + }; + class RH_m1911 : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=5; + }; + class RH_kimber : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=5; + }; + class RH_m9 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.9; + }; + class RH_vz61 : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=4.5; + }; + class RH_tec9 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=5; + }; + class RH_muzi : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=5; + }; + class RH_g18 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.49; + }; + class RH_g17 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.49; + }; + class RH_tt33 : Pistol_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=4.6; + }; + class RH_mk2 : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=4; + }; + class RH_p226 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.4; + }; + class RH_g19 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4; + }; + class RH_gsh18 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.1; + }; + class RH_mateba : Pistol_Base_F + { + ACE_barrelTwist=14; + ACE_barrelLength=6; + }; + class RH_python : Pistol_Base_F + { + ACE_barrelTwist=14; + ACE_barrelLength=6; + }; + class RH_bull : Pistol_Base_F + { + ACE_barrelTwist=24; + ACE_barrelLength=6.5; + }; + class RH_ttracker : Pistol_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=4; + }; + class RH_mp412 : Pistol_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=6; + }; + class RH_fnp45 : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=4.5; + }; + class RH_fn57 : Pistol_Base_F + { + ACE_barrelTwist=9.1; + ACE_barrelLength=4.8; + }; + class RH_vp70 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.6; + }; + class RH_cz75 : Pistol_Base_F + { + ACE_barrelTwist=9.7; + ACE_barrelLength=4.7; + }; + + class RH_PDW : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=10; + }; + + class RH_hb : Rifle_Base_F + { + ACE_barrelTwist=8; + ACE_barrelLength=6; + }; + class RH_sbr9 : Rifle_Base_F + { + ACE_barrelTwist=9.7; + ACE_barrelLength=9; + }; + class RH_ar10 : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=20.8; + }; + class RH_m4 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14.5; + }; + class RH_M4m : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=10.5; + }; + class RH_M4sbr : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=10.5; + }; + class RH_M16a1 : Rifle_Base_F + { + ACE_barrelTwist=14; + ACE_barrelLength=20; + }; + class RH_M16A2 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class RH_M16A3 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class RH_M16A4 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class RH_M16A6 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class RH_hk416 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14.5; + }; + class RH_hk416c : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=9; + }; + class RH_hk416s : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=10.4; + }; + class RH_m27iar : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16.5; + }; + class RH_Mk12mod1 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18; + }; + class RH_SAMR : Rifle_Base_F + { + ACE_barrelTwist=7.7; + ACE_barrelLength=20; + }; + class RH_m110 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=20; + }; + class RH_mk11 : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=24; + }; + class RH_sr25ec : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=20; + }; + + class hlc_rifle_ak74 : Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class hlc_rifle_aks74u : Rifle_Base_F + { + ACE_barrelTwist=6.3; + ACE_barrelLength=8.3; + }; + class hlc_rifle_ak47 : Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=16.3; + }; + class hlc_rifle_akm : Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class hlc_rifle_rpk : Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=23.2; + }; + class hlc_rifle_aek971 : Rifle_Base_F + { + ACE_barrelTwist=9.5; + ACE_barrelLength=17; + }; + class hlc_rifle_saiga12k : Rifle_Base_F + { + ACE_barrelTwist=0; + ACE_twistDirection=0; + ACE_barrelLength=16.9; + }; + class hlc_ar15_base : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=11.5; + }; + class hlc_rifle_bcmjack : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14.5; + }; + class hlc_rifle_Bushmaster300 : Rifle_Base_F + { + ACE_barrelTwist=8; + ACE_barrelLength=16; + }; + class hlc_rifle_SAMR : Rifle_Base_F + { + ACE_barrelTwist=9; + ACE_barrelLength=16; + }; + class hlc_rifle_honeybase : Rifle_Base_F + { + ACE_barrelTwist=8; + ACE_barrelLength=6; + }; + class hlc_rifle_SLRchopmod : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21; + }; + class hlc_rifle_LAR : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21; + }; + class hlc_rifle_c1A1 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21.7; + }; + class hlc_rifle_FAL5061 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=18; + }; + class hlc_rifle_STG58F : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21; + }; + class hlc_rifle_SLR : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21.7; + }; + class hlc_rifle_falosw : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=13; + }; + class hlc_rifle_psg1 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=25.6; + }; + class hlc_rifle_g3sg1 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=17.7; + }; + class hlc_rifle_hk51 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=8.31; + }; + class hlc_rifle_hk53 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=8.31; + }; + class hlc_rifle_g3a3 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=17.7; + }; + class hlc_M14_base : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=22; + }; + class hlc_rifle_m14sopmod : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=18; + }; + class hlc_lmg_M60E4 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=17; + }; + class hlc_lmg_m60 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=22; + }; + + class hlc_smg_mp5k_PDW : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=4.5; + }; + class hlc_smg_mp5a2 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=8.9; + }; + class hlc_smg_mp5a4 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=8.9; + }; + class hlc_smg_mp5n : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=8.9; + }; + class hlc_smg_mp5sd5 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=5.7; + }; + class hlc_smg_mp5sd6 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=5.7; + }; + class hlc_smg_9mmar : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=8.9; + }; + class hlc_smg_mp510 : Rifle_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=8.9; + }; + class hlc_smg_mp5a3 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=8.9; + }; + + class hgun_mas_usp_F: Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=4.41; + }; + class hgun_mas_m23_F: Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=5.87; + }; + class hgun_mas_acp_F: Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=5.03; + }; + class hgun_mas_m9_F: Pistol_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=4.9; + }; + class hgun_mas_bhp_F: Pistol_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=4.7; + }; + class hgun_mas_glock_F: Pistol_Base_F + { + ACE_barrelTwist=9.84; + ACE_barrelLength=4.48; + }; + class hgun_mas_glocksf_F: Pistol_Base_F + { + ACE_barrelTwist=15.75; + ACE_barrelLength=4.60; + }; + class hgun_mas_grach_F: Pistol_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=4.4; + }; + class hgun_mas_mak_F: Pistol_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=3.68; + }; + class hgun_mas_sa61_F: Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=4.5; + }; + class hgun_mas_uzi_F: Pistol_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=5.28; + }; + class arifle_mas_mk16 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=13.8; + }; + class arifle_mas_mk16_l : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18; + }; + class arifle_mas_mk17 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=16; + }; + class srifle_mas_m110 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=20; + }; + class arifle_mas_ak_74m : Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.34; + }; + class arifle_mas_ak_74m_gl : Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.34; + }; + class srifle_mas_svd : Rifle_Base_F + { + ACE_barrelTwist=9.4; + ACE_barrelLength=24.4; + }; + class srifle_mas_m91 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=29; + }; + class srifle_mas_ksvk : Rifle_Base_F + { + ACE_barrelTwist=18; + ACE_barrelLength=39.37; + }; + class LMG_mas_rpk_F : Rifle_Base_F + { + ACE_barrelTwist=7.68; + ACE_barrelLength=23.2; + }; + class LMG_mas_pkm_F : Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=25.4; + }; + class arifle_mas_aks74u : Rifle_Base_F + { + ACE_barrelTwist=6.3; + ACE_barrelLength=8.3; + }; + class arifle_mas_bizon : Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=9.1; + }; + class arifle_mas_saiga : Rifle_Base_F + { + ACE_barrelTwist=0; + ACE_twistDirection=0; + ACE_barrelLength=16.93; + }; + class arifle_mas_hk416 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14.5; + }; + class arifle_mas_hk416_gl : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14.5; + }; + class arifle_mas_hk416c : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=9.0; + }; + class arifle_mas_hk416_m203c : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=9.0; + }; + class arifle_mas_hk417c : Rifle_Base_F + { + ACE_barrelTwist=11; + ACE_barrelLength=13; + }; + class arifle_mas_m4 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14.5; + }; + class arifle_mas_m4c : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=10.3; + }; + class arifle_mas_l119 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16; + }; + class arifle_mas_l119_gl : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16; + }; + class arifle_mas_l119_m203 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16; + }; + class arifle_mas_m16 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class arifle_mas_m16_gl : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class srifle_mas_hk417 : Rifle_Base_F + { + ACE_barrelTwist=11; + ACE_barrelLength=16.5; + }; + class srifle_mas_sr25 : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=24; + }; + class srifle_mas_ebr : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=18; + }; + class srifle_mas_m24 : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=24; + }; + class arifle_mas_mp5 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=8.9; + }; + class arifle_mas_mp5sd : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=5.7; + }; + class srifle_mas_m107 : Rifle_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=29; + }; + class LMG_mas_M249_F : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16.3; + }; + class LMG_mas_M249a_F : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18; + }; + class LMG_mas_mk48_F : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=19.75; + }; + class LMG_mas_m240_F : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24.8; + }; + class LMG_mas_mg3_F : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=22.2; + }; + class arifle_mas_g3 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=17.7; + }; + class arifle_mas_g3_m203 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=17.7; + }; + class arifle_mas_fal : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21; + }; + class arifle_mas_fal_m203 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21; + }; + class arifle_mas_m1014 : Rifle_Base_F + { + ACE_barrelTwist=0; + ACE_twistDirection=0; + ACE_barrelLength=18.5; + }; + + class BWA3_P8 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.25; + }; + class BWA3_MP7 : Pistol_Base_F + { + ACE_barrelTwist=6.3; + ACE_barrelLength=7.1; + }; + class BWA3_G36 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18.9; + }; + class BWA3_G36K : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=12.5; + }; + class BWA3_G28_Standard : Rifle_Long_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=16.5; + }; + class BWA3_G27 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=16; + }; + class BWA3_MG4 : Rifle_Long_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18.9; + }; + class BWA3_MG5 : Rifle_Long_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21.6; + }; + class BWA3_G82 : Rifle_Long_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=29; + }; + + class Trixie_L131A1 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.5; + }; + class Trixie_XM8_Carbine : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=12.5; + }; + class Trixie_XM8_Compact : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=9; + }; + class Trixie_XM8_SAW : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class Trixie_XM8_SAW_NB : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class Trixie_XM8_DMR : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class Trixie_XM8_DMR_NB : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class L129A1_base : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=16; + }; + class Trixie_Enfield : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=25.2; + }; + class Trixie_CZ550_Rail : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=23.622; + }; + class Trixie_FNFAL_Rail : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21; + }; + + class Trixie_M110 : Rifle_Base_F + { + ACE_barrelTwist=11; + ACE_barrelLength=20; + }; + class Trixie_MK12 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18; + }; + class Trixie_LM308MWS : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=16; + }; + class Trixie_M14DMR : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=22; + }; + class Trixie_M14DMR_NG_Black_Short : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=18; + }; + class Trixie_M14DMR_NG_Short : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=18; + }; + class Trixie_M14 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=22; + }; + class Trixie_M40A3 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24; + }; + class Trixie_CZ750 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=26; + }; + class Trixie_M24 : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=24; + }; + class Trixie_AWM338 : Rifle_Base_F + { + ACE_barrelTwist=11; + ACE_barrelLength=27; + }; + class Trixie_M107 : Rifle_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=29; + }; + class Trixie_AS50 : Rifle_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=29; + }; + class L110A1_base : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=13.7; + }; + class Trixie_L86A2_base : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=25.4; + }; + class Trixie_l85a2_base : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20.4; + }; + class L7A2_base : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24.8; + }; + + class rhs_weap_pya : Pistol_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=4.4; + }; + class rhs_weap_pkp : Rifle_Long_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=25.9; + }; + class rhs_weap_pkm : Rifle_Long_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=25.4; + }; + class rhs_weap_rpk74m : Rifle_Long_Base_F + { + ACE_barrelTwist=7.68; + ACE_barrelLength=23.2; + }; + class rhs_weap_rpk74 : Rifle_Long_Base_F + { + ACE_barrelTwist=7.68; + ACE_barrelLength=23.2; + }; + class rhs_weap_ak74m : Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class rhs_weap_aks74u : Rifle_Base_F + { + ACE_barrelTwist=6.3; + ACE_barrelLength=8.3; + }; + class rhs_weap_akm : Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class rhs_weap_svd : Rifle_Base_F + { + ACE_barrelTwist=9.4; + ACE_barrelLength=24.4; + }; + class rhs_weap_svds : Rifle_Base_F + { + ACE_barrelTwist=9.4; + ACE_barrelLength=22.2; + }; + class rhs_weap_m4_Base : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14.5; + }; + class rhs_weap_m16a4 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class rhs_weap_m16a4_carryhandle : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class rhs_weap_m16a4_grip : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class rhs_weap_m240B : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24.8; + }; + class rhs_weap_m249_pip : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16.3; + }; + class rhs_weap_mk18 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=10.3; + }; + class rhs_weap_M590_5RD : Rifle_Base_F + { + ACE_barrelTwist=0; + ACE_twistDirection=0; + ACE_barrelLength=18.5; + }; + class rhs_weap_M590_8RD : Rifle_Base_F + { + ACE_barrelTwist=0; + ACE_twistDirection=0; + ACE_barrelLength=20; + }; + class rhs_weap_sr25 : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=24; + }; + class rhs_weap_sr25_ec : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=20; + }; + class rhs_weap_XM2010_Base_F: Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=24; + }; + + class R3F_PAMAS : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.9; + }; + class R3F_Famas_F1: Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=19.2; + }; + class R3F_Famas_surb: Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=15.9; + }; + class R3F_Minimi: Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=13.7; + }; + class R3F_Minimi_762: Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=19.8; + }; + class R3F_FRF2: Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=25.59; + }; + class R3F_PGM_Hecate_II: Rifle_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=27.6; + }; + class R3F_HK417S_HG : Rifle_Base_F + { + ACE_barrelTwist=11; + ACE_barrelLength=12; + }; + class R3F_HK417M : Rifle_Base_F + { + ACE_barrelTwist=11; + ACE_barrelLength=16; + }; + class R3F_HK417L : Rifle_Base_F + { + ACE_barrelTwist=11; + ACE_barrelLength=20; + }; + class R3F_M107 : Rifle_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=29; + }; + class R3F_HK416M : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14; + }; + class R3F_MP5SD : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=5.7; + }; + + class CUP_hgun_Colt1911 : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=5; + }; + class CUP_sgun_AA12 : Rifle_Base_F + { + ACE_barrelTwist=0; + ACE_twistDirection=0; + ACE_barrelLength=18; + }; + class CUP_arifle_AK_Base : Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=16.3; + }; + class CUP_arifle_AK107_Base : Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class CUP_arifle_AKS_Base : Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class CUP_arifle_AKS74U : Rifle_Base_F + { + ACE_barrelTwist=6.3; + ACE_barrelLength=8.3; + }; + class CUP_arifle_RPK74 : Rifle_Long_Base_F + { + ACE_barrelTwist=7.68; + ACE_barrelLength=23.2; + }; + class CUP_srifle_AS50 : Rifle_Long_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=29; + }; + class CUP_srifle_AWM_Base : Rifle_Long_Base_F + { + ACE_barrelTwist=11; + ACE_barrelLength=27; + }; + class CUP_smg_bizon : Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=9.1; + }; + class CUP_hgun_Compact : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=3.74; + }; + class CUP_srifle_CZ750 : Rifle_Long_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=26; + }; + class CUP_arifle_CZ805_Base : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=14; + }; + class CUP_arifle_CZ805_A1 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=14; + }; + class CUP_arifle_CZ805_A2 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=10.9; + }; + class CUP_srifle_DMR : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=22; + }; + class CUP_hgun_Duty : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=3.74; + }; + class CUP_arifle_FNFAL : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=21; + }; + class CUP_arifle_G36A : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18.9; + }; + class CUP_arifle_G36K : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=12.5; + }; + class CUP_arifle_G36C : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=9; + }; + class CUP_arifle_MG36 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18.9; + }; + class CUP_hgun_Glock17 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.49; + }; + class CUP_srifle_CZ550 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=23.622; + }; + class CUP_srifle_ksvk : Rifle_Long_Base_F + { + ACE_barrelTwist=18; + ACE_barrelLength=39.37; + }; + class CUP_lmg_L7A2 : Rifle_Long_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24.8; + }; + class CUP_arifle_L85A2_Base : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20.4; + }; + class CUP_lmg_L110A1 : Rifle_Long_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=13.7; + }; + class CUP_srifle_LeeEnfield : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=25.2; + }; + class CUP_hgun_M9 : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.9; + }; + class CUP_srifle_M14 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=22; + }; + class CUP_arifle_M16_Base : Rifle_Base_F + { + ACE_barrelTwist=14; + ACE_barrelLength=20; + }; + class CUP_arifle_M4_Base : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14.5; + }; + class CUP_srifle_Mk12SPR : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18; + }; + class CUP_srifle_M24_des : Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=24; + }; + class CUP_lmg_M60A4 : Rifle_Long_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=17; + }; + class CUP_srifle_M107_Base : Rifle_Long_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=29; + }; + class CUP_srifle_M110 : Rifle_Base_F + { + ACE_barrelTwist=11; + ACE_barrelLength=20; + }; + class CUP_lmg_M240 : Rifle_Long_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24.8; + }; + class CUP_lmg_M249_para : Rifle_Long_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16.3; + }; + class CUP_lmg_M249 : Rifle_Long_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18; + }; + class CUP_sgun_M1014 : Rifle_Base_F + { + ACE_twistDirection=0; + ACE_barrelTwist=0; + ACE_barrelLength=18.5; + }; + class CUP_hgun_Makarov : Pistol_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=3.68; + }; + class CUP_hgun_MicroUzi : Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=5; + }; + class CUP_lmg_Mk48_Base : Rifle_Long_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=19.75; + }; + class CUP_smg_MP5SD6 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=5.7; + }; + class CUP_smg_MP5A5 : Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=8.9; + }; + class CUP_hgun_PB6P9 : Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=4.1; + }; + class CUP_hgun_Phantom : Rifle_Base_F + { + ACE_barrelTwist=9.7; + ACE_barrelLength=4.7; + }; + class CUP_lmg_PKM : Rifle_Long_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=25.4; + }; + class CUP_lmg_Pecheneg : Rifle_Long_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=25.9; + }; + class CUP_hgun_TaurusTracker455 : Pistol_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=4; + }; + class CUP_arifle_Sa58P : Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=15.4; + }; + class CUP_arifle_Sa58V : Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=15.4; + }; + class CUP_hgun_SA61 : Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=4.5; + }; + class CUP_sgun_Saiga12K: Rifle_Base_F + { + ACE_barrelTwist=0; + ACE_twistDirection=0; + ACE_barrelLength=16.9; + } + class CUP_arifle_Mk16_CQC : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=10; + }; + class CUP_arifle_Mk16_STD : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14; + }; + class CUP_arifle_Mk16_SV : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18; + }; + class CUP_arifle_Mk17_CQC : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=13; + }; + class CUP_arifle_Mk17_STD : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=16; + }; + class CUP_arifle_Mk20 : Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=20; + }; + class CUP_srifle_SVD : Rifle_Base_F + { + ACE_barrelTwist=9.4; + ACE_barrelLength=24.4; + }; + class CUP_lmg_UK59 : Rifle_Long_Base_F + { + ACE_barrelTwist=15; + ACE_barrelLength=21.7; + }; + class CUP_DSHKM_W : MGun + { + ACE_barrelTwist=15; + ACE_barrelLength=42.1; + }; + class CUP_KPVT_W : MGun + { + ACE_barrelTwist=17.91; + ACE_barrelLength=53; + }; + class CUP_KPVB_W : MGun + { + ACE_barrelTwist=17.91; + ACE_barrelLength=53; + }; + class CUP_M134 : MGunCore + { + ACE_barrelTwist=12; + ACE_barrelLength=22; + }; + class CUP_M240_veh_W : Rifle_Long_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24.8; + }; + class CUP_PKT_W : MGun + { + ACE_barrelTwist=9.45; + ACE_barrelLength=28.43; + }; + class CUP_srifle_VSSVintorez : Rifle_Base_F + { + ACE_barrelTwist=8.3; + ACE_barrelLength=7.9; + }; + class CUP_arifle_XM8_Base : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=12.5; + }; + class CUP_arifle_XM8_Carbine : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=12.5; + }; + class CUP_arifle_xm8_sharpshooter : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class CUP_arifle_xm8_SAW : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=20; + }; + class CUP_arifle_XM8_Compact : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=9; + }; + class CUP_arifle_XM8_Railed_Base : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=12.5; + }; + class CUP_arifle_XM8_Carbine_FG : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=12.5; + }; + + class VTN_AK_BASE: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AK74M: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AK74M_GP25: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AK74M_GP30M: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AKS74: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AKS74N: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AKS74N_76: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AK74_76: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AKMS_aa: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=10.3; + }; + class VTN_AKS74U_BASE: Rifle_Base_F + { + ACE_barrelTwist=6.3; + ACE_barrelLength=8.3; + }; + class VTN_AKM_BASE: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AKMS: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AKMS_T_P: Rifle_Base_F + { + ACE_barrelTwist=7.87; + ACE_barrelLength=16.3; + }; + class VTN_AK103_BASE: Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=16.3; + }; + class VTN_AK104_BASE: Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=12.4; + }; + class VTN_AK105_BASE: Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=12.4; + }; + class VTN_AK105_P_BASE: Rifle_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=12.4; + }; + class VTN_SVD_BASE: Rifle_Base_F + { + ACE_barrelTwist=9.4; + ACE_barrelLength=24.4; + }; + class VTN_SVD_63: Rifle_Base_F + { + ACE_barrelTwist=9.4; + ACE_barrelLength=24.4; + }; + class VTN_SVD_86: Rifle_Base_F + { + ACE_barrelTwist=9.4; + ACE_barrelLength=24.4; + }; + class VTN_SV98_BASE: Rifle_Base_F + { + ACE_barrelTwist=12.6; + ACE_barrelLength=25.59; + }; + class VTN_PKM_BAS: Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=25.4; + }; + class VTN_PKP: Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=25.9; + }; + class VTN_PYA: Pistol_Base_F + { + ACE_barrelTwist=10; + ACE_barrelLength=4.4; + }; + class VTN_PM: Pistol_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=3.68; + }; + class VTN_PB: Pistol_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=4.1; + }; + class VTN_GSH18: Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.1; + }; + class VTN_PSS: Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=1.4; + }; + class VTN_PKT: Rifle_Base_F + { + ACE_barrelTwist=9.45; + ACE_barrelLength=28.43; + }; + class VTN_KORD: Rifle_Base_F + { + ACE_barrelTwist=17.91; + ACE_barrelLength=53; + }; + class VTN_KPVT: Rifle_Base_F + { + ACE_barrelTwist=17.91; + ACE_barrelLength=53; + }; + class VTN_C_M4A1 : Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=14.5; + }; + class VTN_MK18MOD0: Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=10.3; + }; + class VTN_M16_BASE: Rifle_Base_F + { + ACE_barrelTwist=14; + ACE_barrelLength=20; + }; + class VTN_FN_SAMR_BASE: Rifle_Base_F + { + ACE_barrelTwist=7.7; + ACE_barrelLength=20; + }; + class VTN_M249_SAW_BASE: Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=18; + }; + class VTN_M249_PARA: Rifle_Base_F + { + ACE_barrelTwist=7; + ACE_barrelLength=16.3; + }; + class VTN_M240G_BASE: Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24.8; + }; + class VTN_M9: Pistol_Base_F + { + ACE_barrelTwist=9.8; + ACE_barrelLength=4.9; + }; + class VTN_M45A1: Pistol_Base_F + { + ACE_barrelTwist=16; + ACE_barrelLength=5; + }; + class VTN_M24: Rifle_Base_F + { + ACE_barrelTwist=11.25; + ACE_barrelLength=24; + }; + class VTN_M240: Rifle_Base_F + { + ACE_barrelTwist=12; + ACE_barrelLength=24.8; + }; + class VTN_KO44: Rifle_Base_F + { + ACE_barrelTwist=9.5; + ACE_barrelLength=20.2; + }; + class VTN_SAIGA_MK03: Rifle_Base_F + { + ACE_twistDirection=9.45; + ACE_barrelLength=16.3; + }; +}; \ No newline at end of file From fdbd0c19057cefb52109fc5ed969c85561661ce9 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Mon, 20 Apr 2015 16:12:01 -0500 Subject: [PATCH 59/59] #777 - mDagr - Update map pos each frame. --- addons/microdagr/functions/fnc_mapOnDrawEH.sqf | 4 ++-- addons/microdagr/functions/fnc_openDisplay.sqf | 1 - addons/microdagr/functions/fnc_updateDisplay.sqf | 14 +++++++------- 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/addons/microdagr/functions/fnc_mapOnDrawEH.sqf b/addons/microdagr/functions/fnc_mapOnDrawEH.sqf index bff20a4b67..644064d069 100644 --- a/addons/microdagr/functions/fnc_mapOnDrawEH.sqf +++ b/addons/microdagr/functions/fnc_mapOnDrawEH.sqf @@ -49,11 +49,11 @@ if (GVAR(currentApplicationPage) == 1) then { } else { //Map Mode: if (GVAR(mapAutoTrackPosition)) then { - _theMap ctrlMapAnimAdd [0, (GVAR(mapZoom)/_mapSize), GVAR(gpsPositionASL)]; + _theMap ctrlMapAnimAdd [0, (GVAR(mapZoom)/_mapSize), (getPosASL ace_player)]; ctrlMapAnimCommit _theMap; }; _size = 48 * _mapSize; - _theMap drawIcon [QUOTE(PATHTO_R(images\icon_self.paa)), [0.533,0.769,0.76,0.75], GVAR(gpsPositionASL), _size, _size, (getDir ace_player), '', 0 ]; + _theMap drawIcon [QUOTE(PATHTO_R(images\icon_self.paa)), [0.533,0.769,0.76,0.75], (getPosASL ace_player), _size, _size, (getDir ace_player), '', 0 ]; if (GVAR(settingShowAllWaypointsOnMap)) then { _size = 32 * _mapSize; diff --git a/addons/microdagr/functions/fnc_openDisplay.sqf b/addons/microdagr/functions/fnc_openDisplay.sqf index ae5f7f47f5..b4cec0fe46 100644 --- a/addons/microdagr/functions/fnc_openDisplay.sqf +++ b/addons/microdagr/functions/fnc_openDisplay.sqf @@ -83,7 +83,6 @@ if ((_oldShowMode == DISPLAY_MODE_CLOSED) && {GVAR(currentShowMode) != DISPLAY_M }; [_pfID] call CBA_fnc_removePerFrameHandler; } else { - GVAR(gpsPositionASL) = getPosAsl ace_player; if (GVAR(currentShowMode) == DISPLAY_MODE_HIDDEN) then { //If display is hidden, and we can show, then swithc modes: if ([DISPLAY_MODE_DISPLAY] call FUNC(canShow)) then { diff --git a/addons/microdagr/functions/fnc_updateDisplay.sqf b/addons/microdagr/functions/fnc_updateDisplay.sqf index 2a5f34a12c..26e5ef8638 100644 --- a/addons/microdagr/functions/fnc_updateDisplay.sqf +++ b/addons/microdagr/functions/fnc_updateDisplay.sqf @@ -44,7 +44,7 @@ case (APP_MODE_INFODISPLAY): { (_display displayCtrl IDC_MODEDISPLAY_NORTHING) ctrlSetText _northingText; //Elevation: - _numASL = (GVAR(gpsPositionASL) select 2) + GVAR(mapAltitude); + _numASL = ((getPosASL ace_player) select 2) + GVAR(mapAltitude); _aboveSeaLevelText = [_numASL, 5, 0] call CBA_fnc_formatNumber; _aboveSeaLevelText = if (_numASL > 0) then {"+" + _aboveSeaLevelText + " MSL"} else {_aboveSeaLevelText + " MSL"}; (_display displayCtrl IDC_MODEDISPLAY_ELEVATIONNUM) ctrlSetText _aboveSeaLevelText; @@ -88,13 +88,13 @@ case (APP_MODE_INFODISPLAY): { }; if (!(_targetPosLocationASL isEqualTo [])) then { - _bearing = [GVAR(gpsPositionASL), _targetPosLocationASL] call BIS_fnc_dirTo; + _bearing = [(getPosASL ace_player), _targetPosLocationASL] call BIS_fnc_dirTo; _bearingText = if (GVAR(settingUseMils)) then { [(floor ((6400 / 360) * (_bearing))), 4, 0] call CBA_fnc_formatNumber; } else { ([(floor (_bearing)), 3, 1] call CBA_fnc_formatNumber) + "°" //degree symbol is in UTF-8 }; - _2dDistanceKm = ((GVAR(gpsPositionASL) select [0,2]) distance (_targetPosLocationASL select [0,2])) / 1000; + _2dDistanceKm = (((getPosASL ace_player) select [0,2]) distance (_targetPosLocationASL select [0,2])) / 1000; _rangeText = format ["%1km", ([_2dDistanceKm, 1, 1] call CBA_fnc_formatNumber)]; _numASL = (_targetPosLocationASL select 2) + GVAR(mapAltitude); _aboveSeaLevelText = [_numASL, 5, 0] call CBA_fnc_formatNumber; @@ -125,7 +125,7 @@ case (APP_MODE_COMPASS): { (_display displayCtrl IDC_MODECOMPASS_RANGE) ctrlSetText ""; (_display displayCtrl IDC_MODECOMPASS_TARGET) ctrlSetText ""; } else { - _playerPos2d = GVAR(gpsPositionASL) select [0,2]; + _playerPos2d = (getPosASL ace_player) select [0,2]; _targetPosName = ""; _targetPosLocationASL = []; @@ -145,13 +145,13 @@ case (APP_MODE_COMPASS): { _rangeText = "---"; if (!(_targetPosLocationASL isEqualTo [])) then { - _bearing = [GVAR(gpsPositionASL), _targetPosLocationASL] call BIS_fnc_dirTo; + _bearing = [(getPosASL ace_player), _targetPosLocationASL] call BIS_fnc_dirTo; _bearingText = if (GVAR(settingUseMils)) then { [(floor ((6400 / 360) * (_bearing))), 4, 0] call CBA_fnc_formatNumber; } else { ([(floor (_bearing)), 3, 1] call CBA_fnc_formatNumber) + "°" //degree symbol is in UTF-8 }; - _2dDistanceKm = ((GVAR(gpsPositionASL) select [0,2]) distance (_targetPosLocationASL select [0,2])) / 1000; + _2dDistanceKm = (((getPosASL ace_player) select [0,2]) distance (_targetPosLocationASL select [0,2])) / 1000; _rangeText = format ["%1km", ([_2dDistanceKm, 1, 1] call CBA_fnc_formatNumber)]; }; @@ -169,7 +169,7 @@ case (APP_MODE_WAYPOINTS): { { EXPLODE_2_PVT(_x,_wpName,_wpPos); _wpListBox lbAdd _wpName; - _2dDistanceKm = ((GVAR(gpsPositionASL) select [0,2]) distance (_wpPos select [0,2])) / 1000; + _2dDistanceKm = (((getPosASL ace_player) select [0,2]) distance (_wpPos select [0,2])) / 1000; _wpListBox lbSetTextRight [_forEachIndex, (format ["%1km", ([_2dDistanceKm, 1, 1] call CBA_fnc_formatNumber)])]; } forEach _waypoints;