mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Merge branch 'release' into fixFuelHoseExceededAfterDisconnect
This commit is contained in:
commit
ebf1321c0b
11
.travis.yml
11
.travis.yml
@ -1,6 +1,7 @@
|
||||
branches:
|
||||
only:
|
||||
- master
|
||||
- master
|
||||
- release
|
||||
language: python
|
||||
python:
|
||||
- '3.4'
|
||||
@ -19,12 +20,10 @@ env:
|
||||
- secure: KcJQbknBOdC5lA4nFGKPXVRVIGLDXDRzC8XkHuXJCE9pIR/wbxbkvx8fHKcC6SC9eHgzneC3+o4m4+CjIbVvIwDgslRbJ8Y59i90ncONmdoRx1HUYHwuYWVZm9HJFjCsIbrEqhSyyKS+PB3WZVOLbErtNHsgS8f43PTh5Ujg7Vg=
|
||||
notifications:
|
||||
slack:
|
||||
secure: aWYF/YX7vxEdXJ5w1jhYJQ2TtTP2NRdnXzJDMYXTv2dlXYhO9qp2qjxDGW3dezuPY7B1mPBgebfSKRx3Robkt1rAfEwPWivOiEztL30rwzOy+5Q1wpORv1JkvTC/q2wqQzxQCU/FPVjD2GkF1wtq1Rnx3ESWD8gbvzYoMNdIw1g=
|
||||
on_success: change
|
||||
on_failure: always
|
||||
on_start: never
|
||||
rooms:
|
||||
secure: MvxmqL1NGwiGTVv6uIVTM7jeNLQH95KYtTgSWlXaSw4jdjnf4cmrb/ofHQ3FHhhNVdhRN6W8n0cJfTC3DBZ90bionVh+528qw2mDnDbKljVdIwmoFSexBcH7H1uTLF3gsEz0tbrHtLcnAyTMxdjsdIXDLZ5hwxABNmW5/03jOgs=
|
||||
- secure: byZMNBl8PMlgjT9NA1WmhgCdGfX4b3g1kA0vEiwfm+IFNlx7BiM4J/5rp6zV/jV470xl/epAejx2tsa5SdTyFbO87NH63ILJSt5QnjUZjRuGKSutFs9WE671DtZkPRSJXHS4N6x802PRkyBz/84/lsc34FWvHvjwOuYAtOcJRFk=
|
||||
- secure: V22TNaLWV+yUNWqR7c6HVvIxkRDz7Dyz9xqa43FY8iFgvNL4Q/X69h5DYHU/ILNFM00tx8OBjtPRbcjWQ+F6eY8Sje/A2axJAU+qNurAvoyiTahXUprdUUpPdkgXWuSRTZ9kALxOq5e11RC8XUietghoMcl8zPcqdrZCOOKgoEM=
|
||||
on_success: change
|
||||
email:
|
||||
on_success: never
|
||||
on_failure: change
|
||||
|
@ -54,7 +54,7 @@ Crusty
|
||||
Dharma Bellamkonda <dharma.bellamkonda@gmail.com>
|
||||
Dimaslg <dimaslg@telecable.es>
|
||||
Drill <drill87@gmail.com>
|
||||
Dudakov <dudakov.s@gmail.com>
|
||||
Dudakov aka [OMCB]Kaban <dudakov.s@gmail.com>
|
||||
Dslyecxi <dslyecxi@gmail.com>
|
||||
eRazeri
|
||||
evromalarkey <evromalarkey@gmail.com>
|
||||
|
@ -7,7 +7,7 @@
|
||||
<img src="https://img.shields.io/badge/Version-3.4.1-blue.svg?style=flat-square" alt="ACE3 Version">
|
||||
</a>
|
||||
<a href="https://github.com/acemod/ACE3/releases/download/v3.4.1/ace3_3.4.1.zip">
|
||||
<img src="https://img.shields.io/badge/Download-65.7_MB-green.svg?style=flat-square" alt="ACE3 Download">
|
||||
<img src="https://img.shields.io/badge/Download-72.6_MB-green.svg?style=flat-square" alt="ACE3 Download">
|
||||
</a>
|
||||
<a href="https://github.com/acemod/ACE3/issues">
|
||||
<img src="https://img.shields.io/github/issues-raw/acemod/ACE3.svg?style=flat-square&label=Issues" alt="ACE3 Issues">
|
||||
|
@ -36,7 +36,7 @@ GVAR(Protractor) = true;
|
||||
if !(GVAR(Protractor) && !(weaponLowered ACE_player) && currentWeapon ACE_player == primaryWeapon ACE_player) exitWith {
|
||||
GVAR(Protractor) = false;
|
||||
1 cutText ["", "PLAIN"];
|
||||
[_idPFH] call cba_fnc_removePerFrameHandler;
|
||||
[_idPFH] call CBA_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
||||
1 cutRsc ["RscProtractor", "PLAIN", 1, false];
|
||||
|
@ -12,11 +12,7 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private "_deleted";
|
||||
|
||||
_deleted = 0;
|
||||
|
||||
_aceTimeSecond = floor ACE_time;
|
||||
private _aceTimeSecond = floor ACE_time;
|
||||
|
||||
{
|
||||
private ["_bulletVelocity", "_bulletPosition", "_bulletSpeed"];
|
||||
|
@ -54,7 +54,7 @@ if (GVAR(disabledInFullAutoMode) && getNumber(configFile >> "CfgWeapons" >> _wea
|
||||
|
||||
if (_abort || !(GVAR(extensionAvailable))) exitWith {
|
||||
if (missionNamespace getVariable [QEGVAR(windDeflection,enabled), false]) then {
|
||||
EGVAR(windDeflection,trackedBullets) pushBack [_bullet, getNumber(configFile >> "cfgAmmo" >> _ammo >> "airFriction")];
|
||||
EGVAR(windDeflection,trackedBullets) pushBack [_bullet, getNumber(configFile >> "CfgAmmo" >> _ammo >> "airFriction")];
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -40,7 +40,7 @@ GVAR(currentGrid) = 0;
|
||||
#ifdef DEBUG_MODE_FULL
|
||||
systemChat format["AdvancedBallistics: Finished terrain initialization in %1 seconds", ceil(ACE_time - _initStartTime)];
|
||||
#endif
|
||||
[_idPFH] call cba_fnc_removePerFrameHandler;
|
||||
[_idPFH] call CBA_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
||||
for "_i" from 1 to 50 do {
|
||||
|
@ -54,7 +54,7 @@ GVAR(active) = true;
|
||||
|
||||
GVAR(DialogPFH) = [{
|
||||
if (!GVAR(active)) exitWith {
|
||||
[_this select 1] call cba_fnc_removePerFrameHandler;
|
||||
[_this select 1] call CBA_fnc_removePerFrameHandler;
|
||||
};
|
||||
__ctrlBackground ctrlSetText format [QUOTE(PATHTOF(UI\ATRAG_%1.paa)), ["N", "D"] select (call EFUNC(common,ambientBrightness))];
|
||||
}, 60, []] call CBA_fnc_addPerFrameHandler;
|
||||
|
@ -2,4 +2,4 @@
|
||||
|
||||
uiNamespace setVariable ['ATragMX_Display', nil];
|
||||
GVAR(active) = false;
|
||||
[GVAR(DialogPFH)] call cba_fnc_removePerFrameHandler;
|
||||
[GVAR(DialogPFH)] call CBA_fnc_removePerFrameHandler;
|
@ -37,7 +37,7 @@ if !(ctrlVisible 9000) then {
|
||||
false call FUNC(show_target_speed_assist_timer);
|
||||
true call FUNC(show_target_speed_assist);
|
||||
|
||||
[_this select 1] call cba_fnc_removePerFrameHandler;
|
||||
[_this select 1] call CBA_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
||||
ctrlSetText [9001, Str(Round((ACE_time - _startTime) * 10) / 10)];
|
||||
|
@ -61,7 +61,6 @@ class CfgVehicles {
|
||||
showDisabled = 0;
|
||||
priority = 5;
|
||||
icon = PATHTOF(UI\attach_ca.paa);
|
||||
// hotkey = "T";
|
||||
};
|
||||
class GVAR(Detach) {
|
||||
displayName = CSTRING(Detach);
|
||||
@ -71,7 +70,6 @@ class CfgVehicles {
|
||||
showDisabled = 0;
|
||||
priority = 5;
|
||||
icon = PATHTOF(UI\detach_ca.paa);
|
||||
hotkey = "T";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -10,7 +10,7 @@
|
||||
* Arguments:
|
||||
* 0: Unit (player) <OBJECT>
|
||||
* 1: attachToVehicle <OBJECT>
|
||||
* 2: Item Classname (cfgWeapon/cfgMagazine) <STRING>
|
||||
* 2: Item Classname (CfgWeapon/CfgMagazine) <STRING>
|
||||
* 3: Light Vehicle Classname <STRING>
|
||||
* 4: On Attach Text <STRING>
|
||||
* 5: Starting Pos of dummy item <ARRAY>
|
||||
|
@ -32,7 +32,6 @@ class CfgVehicles {
|
||||
showDisabled = 0;
|
||||
icon = QUOTE(PATHTOF(UI\captive_ca.paa));
|
||||
priority = 2.3;
|
||||
hotkey = "E";
|
||||
};
|
||||
class ACE_StopEscorting {
|
||||
displayName = CSTRING(StopEscorting);
|
||||
@ -43,7 +42,6 @@ class CfgVehicles {
|
||||
showDisabled = 0;
|
||||
icon = QUOTE(PATHTOF(UI\captive_ca.paa));
|
||||
priority = 2.3;
|
||||
hotkey = "E";
|
||||
};
|
||||
class ACE_LoadCaptive {
|
||||
displayName = CSTRING(LoadCaptive);
|
||||
@ -54,7 +52,6 @@ class CfgVehicles {
|
||||
showDisabled = 0;
|
||||
icon = QUOTE(PATHTOF(UI\captive_ca.paa));
|
||||
priority = 2.2;
|
||||
hotkey = "L";
|
||||
};
|
||||
class GVAR(UnloadCaptive) {
|
||||
displayName = CSTRING(UnloadCaptive);
|
||||
@ -74,7 +71,6 @@ class CfgVehicles {
|
||||
exceptions[] = {"isNotEscorting"};
|
||||
showDisabled = 0;
|
||||
priority = 2.3;
|
||||
hotkey = "C";
|
||||
};
|
||||
class ACE_StartSurrenderingSelf {
|
||||
displayName = CSTRING(StartSurrendering);
|
||||
@ -165,7 +161,7 @@ class CfgVehicles {
|
||||
description = CSTRING(ModuleSurrender_Description);
|
||||
sync[] = {"AnyAI"};
|
||||
};
|
||||
};
|
||||
};
|
||||
class GVAR(ModuleHandcuffed): Module_F {
|
||||
author = ECSTRING(common,ACETeam);
|
||||
category = "ACE";
|
||||
|
@ -45,7 +45,7 @@ if (_state) then {
|
||||
};
|
||||
|
||||
if (!(_unit getVariable [QGVAR(isEscorting), false])) then {
|
||||
[(_this select 1)] call cba_fnc_removePerFrameHandler;
|
||||
[(_this select 1)] call CBA_fnc_removePerFrameHandler;
|
||||
[objNull, _target, false] call EFUNC(common,claim);
|
||||
detach _target;
|
||||
_unit removeAction _actionID;
|
||||
|
@ -19,7 +19,7 @@
|
||||
params ["_unit","_state"];
|
||||
TRACE_2("params",_unit,_state);
|
||||
|
||||
if (!local _unit) exitwith {
|
||||
if (!local _unit) exitWith {
|
||||
ERROR("running setHandcuffed on remote unit");
|
||||
};
|
||||
if ((_unit getVariable [QGVAR(isHandcuffed), false]) isEqualTo _state) exitWith {
|
||||
|
@ -19,7 +19,7 @@
|
||||
params ["_unit","_state"];
|
||||
TRACE_2("params",_unit,_state);
|
||||
|
||||
if (!local _unit) exitwith {
|
||||
if (!local _unit) exitWith {
|
||||
ERROR("running surrender on remote unit");
|
||||
};
|
||||
|
||||
|
@ -17,4 +17,4 @@
|
||||
|
||||
params ["_object"];
|
||||
|
||||
_object getVariable [QGVAR(space), getNumber (configFile >> "CfgVehicles" >> typeof _object >> QGVAR(space))]
|
||||
_object getVariable [QGVAR(space), getNumber (configFile >> "CfgVehicles" >> typeOf _object >> QGVAR(space))]
|
||||
|
@ -24,7 +24,7 @@ private ["_loaded", "_space", "_itemSize"];
|
||||
if !([_item, _vehicle] call FUNC(canLoadItemIn)) exitWith {false};
|
||||
|
||||
_loaded = _vehicle getVariable [QGVAR(loaded), []];
|
||||
_loaded pushback _item;
|
||||
_loaded pushBack _item;
|
||||
_vehicle setVariable [QGVAR(loaded), _loaded, true];
|
||||
|
||||
TRACE_1("added to loaded array",_loaded);
|
||||
|
@ -23,7 +23,7 @@ _vehicle = [_player] call FUNC(findNearestVehicle);
|
||||
if (isNull _vehicle || _vehicle isKindOf "Cargo_Base_F") then {
|
||||
{
|
||||
if ([_object, _x] call FUNC(canLoadItemIn)) exitWith {_vehicle = _x};
|
||||
} foreach (nearestObjects [_player, ["Cargo_base_F", "Land_PaperBox_closed_F"], MAX_LOAD_DISTANCE]);
|
||||
} forEach (nearestObjects [_player, ["Cargo_base_F", "Land_PaperBox_closed_F"], MAX_LOAD_DISTANCE]);
|
||||
};
|
||||
|
||||
if (isNull _vehicle) exitWith {false};
|
||||
|
@ -110,24 +110,28 @@
|
||||
<Portuguese>Carregando carga</Portuguese>
|
||||
<Polish>Ładowanie cargo</Polish>
|
||||
<Czech>Nakládám</Czech>
|
||||
<Russian>Погрузка</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Cargo_UnloadingItem">
|
||||
<English>Unloading Cargo</English>
|
||||
<Portuguese>Descarregando carga</Portuguese>
|
||||
<Polish>Rozładowywanie cargo</Polish>
|
||||
<Czech>Vykládám</Czech>
|
||||
<Russian>Выгрузка</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Cargo_LoadingFailed">
|
||||
<English>%1<br/>could not be loaded</English>
|
||||
<Portuguese>%1<br/>não pode ser carregado</Portuguese>
|
||||
<Polish>%1<br/>nie mógł zostać załadowany</Polish>
|
||||
<Czech>%1<br/>nemůže být naloženo</Czech>
|
||||
<Russian>%1<br/>не может быть погружен</Russian>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Cargo_UnloadingFailed">
|
||||
<English>%1<br/>could not be unloaded</English>
|
||||
<Portuguese>%1<br/>não pode ser descarregado</Portuguese>
|
||||
<Polish>%1<br/>nie mógł zostać rozładowany</Polish>
|
||||
<Czech>%1<br/>nemůže být vyloženo</Czech>
|
||||
<Russian>%1<br/>не может быть выгружен</Russian>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
@ -41,7 +41,7 @@ class GVAR(ProgressBar_Dialog) {
|
||||
w = "38 * (((safezoneW / safezoneH) min 1.2) / 40)";
|
||||
h = "1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)";
|
||||
colorFrame[] = {1,1,1,0.5};
|
||||
colorBar[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.77])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.51])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.08])","(profilenamespace getvariable ['GUI_BCG_RGB_A',0.8])"};
|
||||
colorBar[] = {"(profilenamespace getVariable ['GUI_BCG_RGB_R',0.77])","(profilenamespace getVariable ['GUI_BCG_RGB_G',0.51])","(profilenamespace getVariable ['GUI_BCG_RGB_B',0.08])","(profilenamespace getVariable ['GUI_BCG_RGB_A',0.8])"};
|
||||
texture = "#(argb,8,8,3)color(1,1,1,0.7)";
|
||||
};
|
||||
class TitleText: TitleBackground {
|
||||
|
@ -107,6 +107,10 @@ class RscInGameUI {
|
||||
class RscOptics_LaserDesignator_02 {
|
||||
onLoad = QUOTE([ARR_2('infoDisplayChanged', [ARR_2(_this select 0, 'Any')])] call FUNC(localEvent););
|
||||
};
|
||||
|
||||
class RscStaminaBar {
|
||||
onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscStaminaBar"",'IGUI')] call (uinamespace getvariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2(QUOTE(QGVAR(dlgStaminaBar)),_this select 0)]);
|
||||
};
|
||||
};
|
||||
|
||||
class RscDisplayInventory {
|
||||
@ -115,18 +119,18 @@ class RscDisplayInventory {
|
||||
|
||||
// map
|
||||
class RscDisplayMainMap {
|
||||
onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDiary"",'GUI')] call (uinamespace getvariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgMap', _this select 0)]; [ARR_2('mapDisplayLoaded', [ARR_2(_this select 0, 'Ingame')])] call FUNC(localEvent););
|
||||
onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDiary"",'GUI')] call (uinamespace getVariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgMap', _this select 0)]; [ARR_2('mapDisplayLoaded', [ARR_2(_this select 0, 'Ingame')])] call FUNC(localEvent););
|
||||
};
|
||||
|
||||
class RscDisplayGetReady: RscDisplayMainMap {
|
||||
onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDiary"",'GUI')] call (uinamespace getvariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgMap', _this select 0)]; [ARR_2('mapDisplayLoaded', [ARR_2(_this select 0, 'Briefing')])] call FUNC(localEvent););
|
||||
onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDiary"",'GUI')] call (uinamespace getVariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgMap', _this select 0)]; [ARR_2('mapDisplayLoaded', [ARR_2(_this select 0, 'Briefing')])] call FUNC(localEvent););
|
||||
};
|
||||
|
||||
class RscDisplayServerGetReady: RscDisplayGetReady {
|
||||
onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDiary"",'GUI')] call (uinamespace getvariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgMap', _this select 0)]; [ARR_2('mapDisplayLoaded', [ARR_2(_this select 0, 'ServerBriefing')])] call FUNC(localEvent););
|
||||
onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDiary"",'GUI')] call (uinamespace getVariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgMap', _this select 0)]; [ARR_2('mapDisplayLoaded', [ARR_2(_this select 0, 'ServerBriefing')])] call FUNC(localEvent););
|
||||
};
|
||||
|
||||
|
||||
class RscDisplayClientGetReady: RscDisplayGetReady {
|
||||
onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDiary"",'GUI')] call (uinamespace getvariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgMap', _this select 0)]; [ARR_2('mapDisplayLoaded', [ARR_2(_this select 0, 'ClientBriefing')])] call FUNC(localEvent););
|
||||
onLoad = QUOTE([ARR_4(""onLoad"",_this,""RscDiary"",'GUI')] call (uinamespace getVariable 'BIS_fnc_initDisplay'); uiNamespace setVariable [ARR_2('ACE_dlgMap', _this select 0)]; [ARR_2('mapDisplayLoaded', [ARR_2(_this select 0, 'ClientBriefing')])] call FUNC(localEvent););
|
||||
};
|
||||
|
@ -1,7 +1,7 @@
|
||||
// ACE - Common
|
||||
// #define ENABLE_PERFORMANCE_COUNTERS
|
||||
#include "script_component.hpp"
|
||||
|
||||
// #define ENABLE_PERFORMANCE_COUNTERS
|
||||
|
||||
//////////////////////////////////////////////////
|
||||
// PFHs
|
||||
@ -57,6 +57,24 @@
|
||||
// Eventhandlers
|
||||
//////////////////////////////////////////////////
|
||||
|
||||
//Add a fix for BIS's zeus remoteControl module not reseting variables on DC when RC a unit
|
||||
//This variable is used for isPlayer checks
|
||||
if (isServer) then {
|
||||
addMissionEventHandler ["HandleDisconnect", {
|
||||
params ["_dcPlayer"];
|
||||
private _zeusLogic = getAssignedCuratorLogic _dcPlayer;
|
||||
if ((!isNil "_zeusLogic") && {!isNull _zeusLogic}) then {
|
||||
{
|
||||
if ((_x getvariable ["bis_fnc_moduleRemoteControl_owner", objnull]) isEqualTo _dcPlayer) exitWith {
|
||||
ACE_LOGINFO_3("[%1] DC - Was Zeus [%2] while controlling unit [%3] - manually clearing `bis_fnc_moduleRemoteControl_owner`", [_x] call FUNC(getName), _dcPlayer, _x);
|
||||
_x setVariable ["bis_fnc_moduleRemoteControl_owner", nil, true];
|
||||
};
|
||||
nil
|
||||
} count (curatorEditableObjects _zeusLogic);
|
||||
};
|
||||
}];
|
||||
};
|
||||
|
||||
// Listens for global "SettingChanged" events, to update the force status locally
|
||||
["SettingChanged", {
|
||||
params ["_name", "_value", "_force"];
|
||||
@ -293,6 +311,17 @@ enableCamShake true;
|
||||
// Set up numerous eventhanders for player controlled units
|
||||
//////////////////////////////////////////////////
|
||||
|
||||
//CBA has events for zeus's display onLoad and onUnload (Need to delay a frame for display to be ready)
|
||||
private _zeusDisplayChangedFNC = {
|
||||
[{
|
||||
private _data = !(isNull findDisplay 312);
|
||||
["zeusDisplayChanged", [ACE_player, _data]] call FUNC(localEvent);
|
||||
}, []] call FUNC(execNextFrame);
|
||||
};
|
||||
["CBA_curatorOpened", _zeusDisplayChangedFNC] call CBA_fnc_addEventHandler;
|
||||
["CBA_curatorClosed", _zeusDisplayChangedFNC] call CBA_fnc_addEventHandler;
|
||||
|
||||
|
||||
// default variables
|
||||
GVAR(OldPlayerVehicle) = vehicle objNull;
|
||||
GVAR(OldPlayerTurret) = [objNull] call FUNC(getTurretIndex);
|
||||
@ -302,7 +331,6 @@ GVAR(OldPlayerVisionMode) = currentVisionMode objNull;
|
||||
GVAR(OldCameraView) = "";
|
||||
GVAR(OldVisibleMap) = false;
|
||||
GVAR(OldInventoryDisplayIsOpen) = nil; //@todo check this
|
||||
GVAR(OldZeusDisplayIsOpen) = false;
|
||||
GVAR(OldIsCamera) = false;
|
||||
|
||||
// clean up playerChanged eventhandler from preinit and put it in the same PFH as the other events to reduce overhead and guarantee advantageous execution order
|
||||
@ -314,13 +342,11 @@ if (!isNil QGVAR(PreInit_playerChanged_PFHID)) then {
|
||||
// PFH to raise varios events
|
||||
[{
|
||||
BEGIN_COUNTER(stateChecker);
|
||||
private "_data"; // reuse one variable to reduce number of variables that have to be set to private each frame
|
||||
|
||||
// "playerChanged" event
|
||||
_data = call FUNC(player);
|
||||
private _data = call FUNC(player); // reuse one variable to reduce number of variables that have to be set to private each frame
|
||||
if !(_data isEqualTo ACE_player) then {
|
||||
private "_oldPlayer";
|
||||
_oldPlayer = ACE_player;
|
||||
private _oldPlayer = ACE_player;
|
||||
|
||||
ACE_player = _data;
|
||||
uiNamespace setVariable ["ACE_player", _data];
|
||||
@ -393,14 +419,6 @@ if (!isNil QGVAR(PreInit_playerChanged_PFHID)) then {
|
||||
["inventoryDisplayChanged", [ACE_player, _data]] call FUNC(localEvent);
|
||||
};
|
||||
|
||||
// "zeusDisplayChanged" event
|
||||
_data = !(isNull findDisplay 312);
|
||||
if !(_data isEqualTo GVAR(OldZeusDisplayIsOpen)) then {
|
||||
// Raise ACE event locally
|
||||
GVAR(OldZeusDisplayIsOpen) = _data;
|
||||
["zeusDisplayChanged", [ACE_player, _data]] call FUNC(localEvent);
|
||||
};
|
||||
|
||||
// "activeCameraChanged" event
|
||||
_data = call FUNC(isfeatureCameraActive);
|
||||
if !(_data isEqualTo GVAR(OldIsCamera)) then {
|
||||
@ -449,6 +467,7 @@ if (!isNil QGVAR(PreInit_playerChanged_PFHID)) then {
|
||||
{_unit != _target && {vehicle _unit == vehicle _target}}
|
||||
}] call FUNC(addCanInteractWithCondition);
|
||||
|
||||
["isNotInZeus", {isNull curatorCamera}] call FUNC(addCanInteractWithCondition);
|
||||
|
||||
//////////////////////////////////////////////////
|
||||
// Set up PlayerJIP eventhandler
|
||||
|
@ -74,6 +74,7 @@ PREP(getNumberFromMissionSQM);
|
||||
PREP(getNumberMagazinesIn);
|
||||
PREP(getPitchBankYaw);
|
||||
PREP(getSettingData);
|
||||
PREP(getStaminaBarControl);
|
||||
PREP(getStringFromMissionSQM);
|
||||
PREP(getTargetAzimuthAndInclination);
|
||||
PREP(getTargetDistance);
|
||||
|
@ -88,7 +88,7 @@ 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));
|
||||
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));
|
||||
};
|
||||
*/
|
||||
|
||||
|
@ -116,9 +116,9 @@ class ACE_gui_editBase
|
||||
};
|
||||
colorSelection[] =
|
||||
{
|
||||
"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.3843])",
|
||||
"(profilenamespace getvariable ['GUI_BCG_RGB_G',0.7019])",
|
||||
"(profilenamespace getvariable ['GUI_BCG_RGB_B',0.8862])",
|
||||
"(profilenamespace getVariable ['GUI_BCG_RGB_R',0.3843])",
|
||||
"(profilenamespace getVariable ['GUI_BCG_RGB_G',0.7019])",
|
||||
"(profilenamespace getVariable ['GUI_BCG_RGB_B',0.8862])",
|
||||
1
|
||||
};
|
||||
autocomplete = "";
|
||||
@ -249,7 +249,7 @@ class ACE_gui_listBoxBase : RscListBox{
|
||||
colorSelect2[] = {0.95, 0.95, 0.95, 1};
|
||||
colorSelectBackground[] = {0, 0, 0, 1};
|
||||
colorSelectBackground2[] = {0.543, 0.5742, 0.4102, 1.0};
|
||||
colorDisabled[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])", 0.25};
|
||||
colorDisabled[] = {"(profilenamespace getVariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getVariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getVariable ['GUI_BCG_RGB_B',0.5])", 0.25};
|
||||
period = 1.2;
|
||||
rowHeight = 0.03;
|
||||
colorBackground[] = {0, 0, 0, 1};
|
||||
@ -505,7 +505,7 @@ onMouseButtonDblClick = "";
|
||||
iconCanceled = "\A3\ui_f\data\map\mapcontrol\taskIconCanceled_CA.paa";
|
||||
iconDone = "\A3\ui_f\data\map\mapcontrol\taskIconDone_CA.paa";
|
||||
iconFailed = "\A3\ui_f\data\map\mapcontrol\taskIconFailed_CA.paa";
|
||||
color[] = {"(profilenamespace getvariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getvariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getvariable ['IGUI_TEXT_RGB_B',1])","(profilenamespace getvariable ['IGUI_TEXT_RGB_A',0.8])"};
|
||||
color[] = {"(profilenamespace getVariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getVariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getVariable ['IGUI_TEXT_RGB_B',1])","(profilenamespace getVariable ['IGUI_TEXT_RGB_A',0.8])"};
|
||||
colorCreated[] = {1,1,1,1};
|
||||
colorCanceled[] = {0.7,0.7,0.7,1};
|
||||
colorDone[] = {0.7,1,0.3,1};
|
||||
|
@ -32,7 +32,7 @@ if (isServer) then {
|
||||
|
||||
private "_eventLog";
|
||||
_eventLog = _internalData select 1;
|
||||
_eventLog pushback [ACE_diagTime, _args, _ttl];
|
||||
_eventLog pushBack [ACE_diagTime, _args, _ttl];
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -18,6 +18,6 @@ _dlg = ctrlParent _this;
|
||||
|
||||
_dlg displayAddEventHandler ["unload", {
|
||||
if (_this select 1 == 1) then {
|
||||
[missionnamespace getvariable ["BIS_fnc_initCuratorAttributes_target", objNull]] call FUNC(fixCrateContent);
|
||||
[missionnamespace getVariable ["BIS_fnc_initCuratorAttributes_target", objNull]] call FUNC(fixCrateContent);
|
||||
};
|
||||
}];
|
||||
|
@ -28,7 +28,7 @@ if (_show) then {
|
||||
GVAR(SHOW_BLUR_SCREEN_COLLECTION) pushBack _id;
|
||||
|
||||
// show blur
|
||||
if (isnil QGVAR(MENU_ppHandle_GUI_BLUR_SCREEN)) then {
|
||||
if (isNil QGVAR(MENU_ppHandle_GUI_BLUR_SCREEN)) then {
|
||||
GVAR(MENU_ppHandle_GUI_BLUR_SCREEN) = ppEffectCreate ["DynamicBlur", 102];
|
||||
GVAR(MENU_ppHandle_GUI_BLUR_SCREEN) ppEffectAdjust [0.9];
|
||||
GVAR(MENU_ppHandle_GUI_BLUR_SCREEN) ppEffectEnable true;
|
||||
|
@ -22,7 +22,7 @@ private ["_defaultLoglevel", "_defaultLogDisplayLevel"];
|
||||
|
||||
_defaultLoglevel = [GVAR(LOGLEVEL), DEFAULT_LOGGING_LEVEL] select isNil QGVAR(LOGLEVEL);
|
||||
|
||||
if (_defaultLoglevel < 0) exitwith {false};
|
||||
if (_defaultLoglevel < 0) exitWith {false};
|
||||
|
||||
_defaultLogDisplayLevel = [GVAR(LOGDISPLAY_LEVEL), DEFAULT_TEXT_DISPLAY] select isNil QGVAR(LOGDISPLAY_LEVEL);
|
||||
|
||||
|
@ -14,5 +14,5 @@
|
||||
|
||||
params ["_entity"];
|
||||
|
||||
GVAR(LOGDISPLAY_LEVEL) = call compile (_entity getvariable ["logDisplayLevel","4"]);
|
||||
GVAR(LOGLEVEL) = call compile (_entity getvariable ["logLevel","4"]);
|
||||
GVAR(LOGDISPLAY_LEVEL) = call compile (_entity getVariable ["logDisplayLevel","4"]);
|
||||
GVAR(LOGLEVEL) = call compile (_entity getVariable ["logLevel","4"]);
|
||||
|
@ -73,11 +73,11 @@ _refresh = {
|
||||
_ctrl = (findDisplay 46) ctrlCreate ["RscPicture", _forEachIndex + 19000];
|
||||
|
||||
_position = switch (_setting) do {
|
||||
case TOP_RIGHT_DOWN: {[X_POS_ICONS, Y_POS_ICONS + (_foreachIndex * DIFFERENCE_ICONS), ICON_WIDTH, ICON_WIDTH]};
|
||||
case TOP_RIGHT_LEFT: {[X_POS_ICONS_SECOND - ((_foreachIndex+3) * DIFFERENCE_ICONS), Y_POS_ICONS_SECOND - (ICON_WIDTH / 2), ICON_WIDTH, ICON_WIDTH]};
|
||||
case TOP_LEFT_DOWN: {[LEFT_SIDE + (0.5 * ICON_WIDTH), Y_POS_ICONS + (_foreachIndex * DIFFERENCE_ICONS), ICON_WIDTH, ICON_WIDTH]};
|
||||
case TOP_LEFT_RIGHT: {[LEFT_SIDE + (0.5 * ICON_WIDTH) - ((_foreachIndex+3) * DIFFERENCE_ICONS), Y_POS_ICONS_SECOND, ICON_WIDTH, ICON_WIDTH]};
|
||||
default {[X_POS_ICONS, Y_POS_ICONS + (_foreachIndex * DIFFERENCE_ICONS), ICON_WIDTH, ICON_WIDTH]};
|
||||
case TOP_RIGHT_DOWN: {[X_POS_ICONS, Y_POS_ICONS + (_forEachIndex * DIFFERENCE_ICONS), ICON_WIDTH, ICON_WIDTH]};
|
||||
case TOP_RIGHT_LEFT: {[X_POS_ICONS_SECOND - ((_forEachIndex+3) * DIFFERENCE_ICONS), Y_POS_ICONS_SECOND - (ICON_WIDTH / 2), ICON_WIDTH, ICON_WIDTH]};
|
||||
case TOP_LEFT_DOWN: {[LEFT_SIDE + (0.5 * ICON_WIDTH), Y_POS_ICONS + (_forEachIndex * DIFFERENCE_ICONS), ICON_WIDTH, ICON_WIDTH]};
|
||||
case TOP_LEFT_RIGHT: {[LEFT_SIDE + (0.5 * ICON_WIDTH) - ((_forEachIndex+3) * DIFFERENCE_ICONS), Y_POS_ICONS_SECOND, ICON_WIDTH, ICON_WIDTH]};
|
||||
default {[X_POS_ICONS, Y_POS_ICONS + (_forEachIndex * DIFFERENCE_ICONS), ICON_WIDTH, ICON_WIDTH]};
|
||||
};
|
||||
|
||||
_ctrl ctrlSetPosition _position;
|
||||
@ -97,7 +97,7 @@ if (_show) then {
|
||||
_list pushBack [_iconId, _icon, _color, ACE_time];
|
||||
} else {
|
||||
{
|
||||
if (_x select 0 == _iconId) exitwith {
|
||||
if (_x select 0 == _iconId) exitWith {
|
||||
_list set [_forEachIndex, [_iconId, _icon, _color, ACE_time]];
|
||||
};
|
||||
} forEach _list;
|
||||
|
@ -48,10 +48,10 @@ _ctrlHint ctrlSetBackgroundColor GVAR(displayTextColor);
|
||||
_ctrlHint ctrlSetTextColor GVAR(displayTextFontColor);
|
||||
/*
|
||||
// This does not function at the moment. Has been disabled until it fixed.
|
||||
_xPos = profilenamespace getvariable ["IGUI_GRID_ACE_displayText_X", ((safezoneX + safezoneW) - (10 *(((safezoneW / safezoneH) min 1.2) / 40)) - 2.9 *(((safezoneW / safezoneH) min 1.2) / 40))];
|
||||
_yPos = profilenamespace getvariable ["IGUI_GRID_ACE_displayText_Y", safeZoneY + 0.175 * safezoneH];
|
||||
_wPos = profilenamespace getvariable ["IGUI_GRID_ACE_displayText_W", (10 *(((safezoneW / safezoneH) min 1.2) / 40))];
|
||||
_hPos = profilenamespace getvariable ["IGUI_GRID_ACE_displayText_H", (2 *((((safezoneW / safezoneH) min 1.2) / 1.2) / 25))];
|
||||
_xPos = profilenamespace getVariable ["IGUI_GRID_ACE_displayText_X", ((safezoneX + safezoneW) - (10 *(((safezoneW / safezoneH) min 1.2) / 40)) - 2.9 *(((safezoneW / safezoneH) min 1.2) / 40))];
|
||||
_yPos = profilenamespace getVariable ["IGUI_GRID_ACE_displayText_Y", safeZoneY + 0.175 * safezoneH];
|
||||
_wPos = profilenamespace getVariable ["IGUI_GRID_ACE_displayText_W", (10 *(((safezoneW / safezoneH) min 1.2) / 40))];
|
||||
_hPos = profilenamespace getVariable ["IGUI_GRID_ACE_displayText_H", (2 *((((safezoneW / safezoneH) min 1.2) / 1.2) / 25))];
|
||||
*/
|
||||
|
||||
_xPos = ((safezoneX + safezoneW) - (10 *(((safezoneW / safezoneH) min 1.2) / 40)) - 2.9 *(((safezoneW / safezoneH) min 1.2) / 40));
|
||||
|
@ -92,7 +92,7 @@ _bottomPosY = (_ctrlBcgCommonPos select 1) + _ctrlTextPosH + (_marginY * 2) + _b
|
||||
_xPos set [1, _bottomPosY];
|
||||
_x ctrlSetPosition _xPos;
|
||||
_x ctrlCommit 0;
|
||||
} foreach [
|
||||
} forEach [
|
||||
_ctrlBackgroundButtonOK,
|
||||
_ctrlBackgroundButtonMiddle,
|
||||
_ctrlBackgroundButtonCancel,
|
||||
|
@ -24,7 +24,7 @@ _hitPointDamages = getAllHitPointsDamage _object;
|
||||
|
||||
// get correct format for objects without hitpoints
|
||||
if (_hitPointDamages isEqualTo []) then {
|
||||
_hitPointDamages = [[],[],[]];
|
||||
_hitPointDamages = [[],[],[]];
|
||||
};
|
||||
|
||||
// this prevents physx objects from floating when near other physx objects with allowDamage false
|
||||
|
@ -20,14 +20,14 @@
|
||||
|
||||
params ["_object", ["_category", ""]];
|
||||
|
||||
if (isNil QGVAR(OBJECT_VARIABLES_STORAGE)) exitwith {[]};
|
||||
if (isNil QGVAR(OBJECT_VARIABLES_STORAGE)) exitWith {[]};
|
||||
|
||||
private ["_return", "_val"];
|
||||
|
||||
_return = [];
|
||||
|
||||
{
|
||||
_val = _object getvariable (_x select 0);
|
||||
_val = _object getVariable (_x select 0);
|
||||
|
||||
if (!isNil "_val") then {
|
||||
if (_category == "" || _category == _x select 3) then {
|
||||
|
@ -16,7 +16,7 @@
|
||||
params ["_unit", "_variable", "_defaultValue"];
|
||||
|
||||
private "_value";
|
||||
_value = _unit getvariable _variable;
|
||||
_value = _unit getVariable _variable;
|
||||
|
||||
if (isNil "_value") then {
|
||||
if (!isNil "_defaultValue") then {
|
||||
|
@ -17,7 +17,7 @@ params ["_varName"];
|
||||
private "_variableDefinition";
|
||||
_variableDefinition = [_varName] call FUNC(getDefinedVariableInfo);
|
||||
|
||||
if !(_variableDefinition isEqualTo []) exitwith {
|
||||
if !(_variableDefinition isEqualTo []) exitWith {
|
||||
_variableDefinition select 1;
|
||||
};
|
||||
|
||||
|
@ -5,24 +5,27 @@
|
||||
* Arguments:
|
||||
* 0: Object <OBJECT>
|
||||
* 1: Use effective commander name when used on vehicles (default: false) <BOOL>
|
||||
* 2: Get Raw Name (Don't sanatize HTML tags `</>`) (default: false) <BOOL>
|
||||
*
|
||||
* Return Value:
|
||||
* Object Name <STRING>
|
||||
*
|
||||
* Example:
|
||||
* [player, false, true] call ace_common_fnc_getName;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
params ["_unit", ["_showEffective", false]];
|
||||
params ["_unit", ["_showEffective", false], ["_useRaw", false]];
|
||||
|
||||
private "_name";
|
||||
_name = "";
|
||||
private _name = "";
|
||||
|
||||
if (_unit isKindOf "CAManBase") then {
|
||||
_name = _unit getVariable ["ACE_Name", localize QUOTE(DOUBLES(STR,GVAR(Unknown)))];
|
||||
_name = _unit getVariable [(["ACE_Name", "ACE_NameRaw"] select _useRaw), localize QUOTE(DOUBLES(STR,GVAR(Unknown)))];
|
||||
} else {
|
||||
if (_showEffective) then {
|
||||
_name = [effectiveCommander _unit] call FUNC(getName);
|
||||
_name = [effectiveCommander _unit, false, _useRaw] call FUNC(getName);
|
||||
} else {
|
||||
_name = getText (configFile >> "CfgVehicles" >> typeOf _unit >> "displayName");
|
||||
};
|
||||
|
15
addons/common/functions/fnc_getStaminaBarControl.sqf
Normal file
15
addons/common/functions/fnc_getStaminaBarControl.sqf
Normal file
@ -0,0 +1,15 @@
|
||||
/*
|
||||
* Author: commy2
|
||||
* Returns the control of the Stamina Bar from Arma 1.54.
|
||||
*
|
||||
* Arguments:
|
||||
* None
|
||||
*
|
||||
* Return Value:
|
||||
* Stamina Bar control <CONTROL>
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
(uiNamespace getVariable [QGVAR(dlgStaminaBar), displayNull]) displayCtrl IDC_STAMINA_BAR
|
@ -14,4 +14,4 @@
|
||||
|
||||
params ["_unit"];
|
||||
|
||||
!(_unit getvariable ["ACE_isUnconscious", false]) && alive _unit && !(_unit getvariable ["ACE_isDead", false]) // return
|
||||
!(_unit getVariable ["ACE_isUnconscious", false]) && alive _unit && !(_unit getVariable ["ACE_isDead", false]) // return
|
||||
|
@ -14,4 +14,4 @@
|
||||
|
||||
params ["_modName"];
|
||||
|
||||
isClass (configFile >> "cfgPatches" >> _modName) // return
|
||||
isClass (configFile >> "CfgPatches" >> _modName) // return
|
||||
|
@ -1,7 +1,7 @@
|
||||
/*
|
||||
* Author: bux578, commy2, akalegman
|
||||
* Checks if a unit is a player / curator controlled unit.
|
||||
* Currently returns false for non-local remote controlled zeus units. (Remotes from another zeus machine)
|
||||
* This now includes both local and non-local remote controlled zeus units. (Remotes from another zeus machine)
|
||||
*
|
||||
* Arguments:
|
||||
* 0: unit to be checked <OBJECT>
|
||||
@ -10,10 +10,13 @@
|
||||
* Return Value:
|
||||
* Is unit a player? <BOOL>
|
||||
*
|
||||
* Example:
|
||||
* [cursorTarget, false] call ace_common_fnc_isPlayer;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
params ["_unit", ["_excludeRemoteControlled", false]];
|
||||
|
||||
isPlayer _unit || (!_excludeRemoteControlled && {_unit == call FUNC(player)}) // return
|
||||
(isPlayer _unit) || {(!_excludeRemoteControlled) && {!isNull (_unit getVariable ["bis_fnc_moduleRemoteControl_owner", objNull])}}
|
||||
|
@ -21,7 +21,7 @@ private ["_vehicle", "_loadcar", "_loadair", "_loadtank", "_loadboat"];
|
||||
|
||||
_vehicle = objNull;
|
||||
|
||||
if (!([_caller, _unit, ["isNotDragging", "isNotCarrying"]] call FUNC(canInteractWith)) || {_caller == _unit}) exitwith {_vehicle};
|
||||
if (!([_caller, _unit, ["isNotDragging", "isNotCarrying"]] call FUNC(canInteractWith)) || {_caller == _unit}) exitWith {_vehicle};
|
||||
|
||||
_loadcar = nearestObject [_unit, "Car"];
|
||||
|
||||
|
@ -16,7 +16,7 @@ private "_fnc_parseConfigForDisplayNames";
|
||||
_fnc_parseConfigForDisplayNames = {
|
||||
params ["_optionEntry"];
|
||||
|
||||
if !(isClass _optionEntry) exitwith {false};
|
||||
if !(isClass _optionEntry) exitWith {false};
|
||||
|
||||
private "_values";
|
||||
_values = getArray (_optionEntry >> "values");
|
||||
|
@ -16,9 +16,9 @@ params ["_unit", "_id", "_accepted"];
|
||||
|
||||
private ["_requestID", "_info", "_callBack", "_caller", "_replyParams", "_requestMessage", "_target"];
|
||||
|
||||
_info = _unit getvariable _id;
|
||||
_info = _unit getVariable _id;
|
||||
|
||||
if (!isnil "_info") then {
|
||||
if (!isNil "_info") then {
|
||||
_caller = _info select 0;
|
||||
_target = _info select 1;
|
||||
_requestID = _info select 2;
|
||||
@ -26,16 +26,16 @@ if (!isnil "_info") then {
|
||||
_callBack = _info select 4;
|
||||
_replyParams = [_info, _accepted];
|
||||
[_replyParams, QFUNC(requestCallback), _caller, false] call FUNC(execRemoteFnc);
|
||||
_unit setvariable [_id, nil];
|
||||
_unit setVariable [_id, nil];
|
||||
};
|
||||
|
||||
GVAR(RECIEVE_REQUEST_ID_KEY_BINDING) = nil;
|
||||
|
||||
if (!isnil QGVAR(RECIEVE_REQUEST_ADD_ACTION_ACCEPT)) then {
|
||||
if (!isNil QGVAR(RECIEVE_REQUEST_ADD_ACTION_ACCEPT)) then {
|
||||
_unit removeAction GVAR(RECIEVE_REQUEST_ADD_ACTION_ACCEPT);
|
||||
GVAR(RECIEVE_REQUEST_ADD_ACTION_ACCEPT) = nil;
|
||||
};
|
||||
if (!isnil QGVAR(RECIEVE_REQUEST_ADD_ACTION_DECLINE)) then {
|
||||
if (!isNil QGVAR(RECIEVE_REQUEST_ADD_ACTION_DECLINE)) then {
|
||||
_unit removeAction GVAR(RECIEVE_REQUEST_ADD_ACTION_DECLINE);
|
||||
GVAR(RECIEVE_REQUEST_ADD_ACTION_DECLINE) = nil;
|
||||
};
|
||||
|
@ -17,7 +17,7 @@
|
||||
#include "script_component.hpp"
|
||||
|
||||
//paramsArray is a normal variable not a command
|
||||
private _paramsArray = missionnamespace getvariable ["paramsArray", []];
|
||||
private _paramsArray = missionnamespace getVariable ["paramsArray", []];
|
||||
|
||||
TRACE_1("Reading missionConfigFile params",_paramsArray);
|
||||
|
||||
@ -60,4 +60,4 @@ TRACE_1("Reading missionConfigFile params",_paramsArray);
|
||||
// Update the variable globaly and Force
|
||||
[_settingName, _settingValue, true, true] call FUNC(setSetting);
|
||||
};
|
||||
} foreach _paramsArray;
|
||||
} forEach _paramsArray;
|
||||
|
@ -19,9 +19,9 @@ _requestID = ("ace_recieveRequest_f_id_"+_requestID);
|
||||
_target setVariable [_requestID, _this];
|
||||
|
||||
if (isLocalized _requestMessage) then {
|
||||
_requestMessage = format [localize _requestMessage, [_caller] call FUNC(getName)];
|
||||
_requestMessage = format [localize _requestMessage, [_caller, false, true] call FUNC(getName)];
|
||||
} else {
|
||||
_requestMessage = format [_requestMessage, [_caller] call FUNC(getName)];
|
||||
_requestMessage = format [_requestMessage, [_caller, false, true] call FUNC(getName)];
|
||||
};
|
||||
|
||||
hint format ["%1", _requestMessage]; // @todo ?
|
||||
@ -53,7 +53,7 @@ GVAR(RECIEVE_REQUEST_TIME_OUT_SCRIPT) = [ACE_time, _target, _requestID] spawn {
|
||||
private "_id";
|
||||
_id = _target getVariable _requestID;
|
||||
|
||||
waituntil {
|
||||
waitUntil {
|
||||
_id = _target getVariable _requestID;
|
||||
|
||||
(ACE_time > _time || isNil "_id")
|
||||
|
@ -26,5 +26,5 @@ _selectBinocular = currentWeapon _unit == _binocular;
|
||||
_unit addWeapon _binocular;
|
||||
|
||||
if (_selectBinocular) then {
|
||||
_unit selectWeapon _binocular;
|
||||
_unit selectWeapon _binocular;
|
||||
};
|
||||
|
@ -14,8 +14,8 @@
|
||||
|
||||
params ["_unit"];
|
||||
|
||||
_unit setvariable ["ACE_isDead", nil, true];
|
||||
_unit setvariable ["ACE_isUnconscious", nil, true];
|
||||
_unit setVariable ["ACE_isDead", nil, true];
|
||||
_unit setVariable ["ACE_isUnconscious", nil, true];
|
||||
|
||||
if (isPlayer _unit) then {
|
||||
[true] call FUNC(setVolume);
|
||||
@ -36,7 +36,7 @@ if (isPlayer _unit) then {
|
||||
|
||||
{
|
||||
if !(_x select 4) then {
|
||||
_unit setvariable [_x select 0, nil, _x select 3];
|
||||
_unit setVariable [_x select 0, nil, _x select 3];
|
||||
};
|
||||
false
|
||||
} count ([_unit] call FUNC(getAllDefinedSetVariables));
|
||||
|
@ -7,7 +7,10 @@
|
||||
* 1: Remove html tags (default: false) <BOOL>
|
||||
*
|
||||
* Return Value:
|
||||
* Sanitized string
|
||||
* Sanitized string <STRING>
|
||||
*
|
||||
* Example:
|
||||
* ["<CoolGroup>CoolGuy", true] call ace_common_fnc_sanitizeString;
|
||||
*
|
||||
* Public: Yes
|
||||
*/
|
||||
@ -20,14 +23,14 @@ _array = [];
|
||||
|
||||
{
|
||||
switch _x do {
|
||||
case 60 : {
|
||||
case 60 : { // less than symbol: `<`
|
||||
if (_removeTags) then {
|
||||
_array append toArray "<";
|
||||
} else {
|
||||
_array pushBack _x;
|
||||
};
|
||||
};
|
||||
case 62 : {
|
||||
case 62 : { // greater than symbol: `>`
|
||||
if (_removeTags) then {
|
||||
_array append toArray ">";
|
||||
} else {
|
||||
|
@ -1,19 +1,24 @@
|
||||
/*
|
||||
* Author: esteldunedain
|
||||
* ?
|
||||
* Log a RPT messaged on just the server
|
||||
*
|
||||
* Arguments:
|
||||
* ?
|
||||
* 0: Text to display <STRING>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* ["x happened"] call ace_common_fnc_serverLog;
|
||||
*
|
||||
* Public: no
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
params [["_msg", "", [""]]];
|
||||
|
||||
if (isServer) then {
|
||||
diag_log _this;
|
||||
diag_log text _msg;
|
||||
} else {
|
||||
[_this, QFUNC(serverLog), 1] call FUNC(execRemoteFnc);
|
||||
};
|
||||
|
@ -1,6 +1,6 @@
|
||||
/*
|
||||
* Author: Glowbal
|
||||
* Setvariable value
|
||||
* setVariable value
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Unit <OBJECT>
|
||||
@ -23,7 +23,7 @@ if (isNil "_global") then {
|
||||
_definedVariable params ["", "", ["_global", false]];
|
||||
};
|
||||
|
||||
if (!isNil "_value") exitwith {
|
||||
if (!isNil "_value") exitWith {
|
||||
_unit setVariable [_variable, _value, _global];
|
||||
};
|
||||
|
||||
|
@ -17,9 +17,15 @@ params ["_unit"];
|
||||
if (isNull _unit || {!alive _unit}) exitWith {};
|
||||
|
||||
if (_unit isKindOf "CAManBase") then {
|
||||
_name = [name _unit, true] call FUNC(sanitizeString);
|
||||
|
||||
private _sanitizedName = [name _unit, true] call FUNC(sanitizeString);
|
||||
private _rawName = [name _unit, false] call FUNC(sanitizeString);
|
||||
|
||||
//Debug Testing Code (with html tags):
|
||||
// private _sanitizedName = ["<TAG>Name", true] call FUNC(sanitizeString);
|
||||
// private _rawName = ["<TAG>Name", false] call FUNC(sanitizeString);
|
||||
|
||||
//if (_name != _unit getVariable ["ACE_Name", ""]) then {
|
||||
_unit setVariable ["ACE_Name", _name, true];
|
||||
_unit setVariable ["ACE_Name", _sanitizedName, true];
|
||||
_unit setVariable ["ACE_NameRaw", _rawName, true];
|
||||
//};
|
||||
};
|
||||
|
@ -25,8 +25,8 @@ _elements = [];
|
||||
|
||||
{
|
||||
_theElement = toArray (_x select _elementN);
|
||||
_indexes pushback _foreachIndex;
|
||||
_elements pushback _theElement;
|
||||
_indexes pushBack _forEachIndex;
|
||||
_elements pushBack _theElement;
|
||||
} forEach _array;
|
||||
|
||||
for "_i" from 1 to (count _elements) - 1 do {
|
||||
@ -45,7 +45,7 @@ for "_i" from 1 to (count _elements) - 1 do {
|
||||
_returnArray = [];
|
||||
|
||||
{
|
||||
_returnArray pushback (_array select _x);
|
||||
_returnArray pushBack (_array select _x);
|
||||
} forEach _indexes;
|
||||
|
||||
_returnArray
|
||||
|
@ -18,7 +18,7 @@
|
||||
params [["_unit", objNull], ["_switch", false], ["_id", ""], ["_side", side _unit]];
|
||||
|
||||
private "_previousGroupsList";
|
||||
_previousGroupsList = _unit getvariable [QGVAR(previousGroupSwitchTo), []];
|
||||
_previousGroupsList = _unit getVariable [QGVAR(previousGroupSwitchTo), []];
|
||||
|
||||
if (_switch) then {
|
||||
// go forward
|
||||
@ -27,7 +27,7 @@ if (_switch) then {
|
||||
_previousGroup = group _unit;
|
||||
_originalSide = side group _unit;
|
||||
|
||||
if (count units _previousGroup == 1 && _originalSide == _side) exitwith {
|
||||
if (count units _previousGroup == 1 && _originalSide == _side) exitWith {
|
||||
[format ["Current group has only 1 member and is of same side as switch. Not switching unit %1", _id]] call FUNC(debug);
|
||||
};
|
||||
|
||||
@ -41,7 +41,7 @@ if (_switch) then {
|
||||
private ["_currentGroup", "_newGroup"];
|
||||
|
||||
{
|
||||
if (_id == (_x select 2)) exitwith {
|
||||
if (_id == (_x select 2)) exitWith {
|
||||
_x set [ 3, false];
|
||||
_previousGroupsList set [_forEachIndex, _x];
|
||||
[format["found group with ID: %1", _id]] call FUNC(debug);
|
||||
@ -51,7 +51,7 @@ if (_switch) then {
|
||||
reverse _previousGroupsList;
|
||||
|
||||
{
|
||||
if (_x select 3) exitwith {}; // stop at first id set to true
|
||||
if (_x select 3) exitWith {}; // stop at first id set to true
|
||||
if !(_x select 3) then {
|
||||
_currentGroup = group _unit;
|
||||
if (!isNull (_x select 0)) then {
|
||||
|
@ -24,7 +24,7 @@ if (_vehicle == _unit) exitWith {false};
|
||||
if (speed _vehicle > 1 || getPos _vehicle select 2 > 2) exitWith {false};
|
||||
|
||||
private "_emptyPos";
|
||||
_emptyPos = (getPos _vehicle) findEmptyPosition [0, 10, typeof _unit]; // @todo to small?
|
||||
_emptyPos = (getPos _vehicle) findEmptyPosition [0, 10, typeOf _unit]; // @todo to small?
|
||||
|
||||
if (count _emptyPos == 0) exitWith {false};
|
||||
|
||||
|
@ -28,7 +28,7 @@ if (_vehicle isKindOf "Ship") then {
|
||||
|
||||
TRACE_1("SHIP Ground Check",getPos _vehicle);
|
||||
|
||||
_emptyPos = (ASLToAGL getPosASL _vehicle) findEmptyPosition [0, 13, typeof _unit]; // TODO: if spot is underwater pick another spot.
|
||||
_emptyPos = (ASLToAGL getPosASL _vehicle) findEmptyPosition [0, 13, typeOf _unit]; // TODO: if spot is underwater pick another spot.
|
||||
} else {
|
||||
if (_vehicle isKindOf "Air") then {
|
||||
if (speed _vehicle > 1 || {!isTouchingGround _vehicle}) then {
|
||||
@ -46,18 +46,18 @@ if (_vehicle isKindOf "Ship") then {
|
||||
|
||||
TRACE_1("Vehicle Ground Check", isTouchingGround _vehicle);
|
||||
|
||||
_emptyPos = (ASLToAGL getPosASL _vehicle) findEmptyPosition [0, 13, typeof _unit];
|
||||
_emptyPos = (ASLToAGL getPosASL _vehicle) findEmptyPosition [0, 13, typeOf _unit];
|
||||
};
|
||||
};
|
||||
|
||||
TRACE_1("getPosASL Vehicle Check", getPosASL _vehicle);
|
||||
|
||||
if !(_validVehiclestate) exitwith {
|
||||
if !(_validVehiclestate) exitWith {
|
||||
ACE_LOGWARNING_4("Unable to unload patient because invalid (%1) vehicle state. Either moving or Not close enough on the ground. position: %2 isTouchingGround: %3 Speed: %4",_vehicle,getPos _vehicle,isTouchingGround _vehicle,speed _vehicle);
|
||||
false
|
||||
};
|
||||
|
||||
if (count _emptyPos == 0) exitwith {
|
||||
if (count _emptyPos == 0) exitWith {
|
||||
ACE_LOGWARNING_1("No safe empty spots to unload patient. %1",_emptyPos);
|
||||
false
|
||||
}; //consider displaying text saying there are no safe places to exit the vehicle
|
||||
@ -96,9 +96,9 @@ _unit action ["Eject", vehicle _unit];
|
||||
|
||||
[_unit, false, GROUP_SWITCH_ID, side group _unit] call FUNC(switchToGroupSide);
|
||||
|
||||
_loaded = _vehicle getvariable [QGVAR(loaded_persons),[]];
|
||||
_loaded = _vehicle getVariable [QGVAR(loaded_persons),[]];
|
||||
_loaded deleteAt (_loaded find _unit);
|
||||
|
||||
_vehicle setvariable [QGVAR(loaded_persons), _loaded, true];
|
||||
_vehicle setVariable [QGVAR(loaded_persons), _loaded, true];
|
||||
|
||||
true
|
||||
|
@ -15,7 +15,7 @@
|
||||
#include "script_component.hpp"
|
||||
|
||||
// If the cursorMenu is open, the loading bar will fail. If we execute the function one frame later, it will work fine
|
||||
if (uiNamespace getVariable [QEGVAR(interact_menu,cursorMenuOpened),false]) exitwith {
|
||||
if (uiNamespace getVariable [QEGVAR(interact_menu,cursorMenuOpened),false]) exitWith {
|
||||
[{
|
||||
_this call FUNC(dismount);
|
||||
}, _this] call EFUNC(common,execNextFrame);
|
||||
|
@ -52,12 +52,12 @@ if (_mode == 0) then {
|
||||
];
|
||||
{
|
||||
_found = false;
|
||||
_no = nearestObjects [_x, [typeOf _wire], 3]; //diag_log _no; diag_log ".....";
|
||||
_no = _no - [_wire]; //diag_log _no;
|
||||
_no = nearestObjects [_x, [typeOf _wire], 3]; //diag_log _no; diag_log ".....";
|
||||
_no = _no - [_wire]; //diag_log _no;
|
||||
if (count _no > 0) exitWith {
|
||||
_found = true; //diag_log "found";
|
||||
_found = true; //diag_log "found";
|
||||
};
|
||||
} foreach _wireCheckPosAr;
|
||||
} forEach _wireCheckPosAr;
|
||||
// Double coil found!
|
||||
if (_found) then {
|
||||
_mode = 1;
|
||||
|
@ -29,7 +29,7 @@ private ["_xGrid", "_yGrid", "_dagrGrid", "_bearing", "_dagrDist", "_dagrElevati
|
||||
|
||||
__background ctrlSetText QUOTE(PATHTOF(UI\dagr_vector.paa));
|
||||
|
||||
if (GVAR(noVectorData)) exitwith {};
|
||||
if (GVAR(noVectorData)) exitWith {};
|
||||
GVAR(LAZPOS) params ["_lazPosX", "_lazPosY", "_lazPosZ"];
|
||||
|
||||
// Incase grids go neg due to 99-00 boundry
|
||||
|
@ -14,7 +14,7 @@
|
||||
true
|
||||
},
|
||||
{false},
|
||||
[0, [false, true, false]], false] call cba_fnc_addKeybind; // (empty default key)
|
||||
[0, [false, true, false]], false] call CBA_fnc_addKeybind; // (empty default key)
|
||||
|
||||
["ACE3 Equipment", QGVAR(ToggleKey), "Toggle DAGR",
|
||||
{
|
||||
@ -27,7 +27,7 @@
|
||||
true
|
||||
},
|
||||
{false},
|
||||
[0, [false, false, false]], false] call cba_fnc_addKeybind; // (empty default key)
|
||||
[0, [false, false, false]], false] call CBA_fnc_addKeybind; // (empty default key)
|
||||
|
||||
//Add deviceKey entry:
|
||||
private ["_conditonCode", "_toggleCode", "_closeCode"];
|
||||
|
@ -3,6 +3,7 @@
|
||||
<Package name="DAGR">
|
||||
<Key ID="STR_ACE_DAGR_Name">
|
||||
<English>DAGR</English>
|
||||
<German>DAGR</German>
|
||||
<Polish>DAGR</Polish>
|
||||
<Spanish>DAGR</Spanish>
|
||||
<Russian>DAGR</Russian>
|
||||
@ -11,6 +12,7 @@
|
||||
</Key>
|
||||
<Key ID="STR_ACE_DAGR_ConfigureDAGR">
|
||||
<English>Configure DAGR</English>
|
||||
<German>DAGR konfigurien</German>
|
||||
<Polish>Konfiguruj DAGR</Polish>
|
||||
<Spanish>Configurar DAGR</Spanish>
|
||||
<Russian>Настроить DAGR</Russian>
|
||||
@ -19,6 +21,7 @@
|
||||
</Key>
|
||||
<Key ID="STR_ACE_DAGR_ToggleDAGR">
|
||||
<English>Toggle DAGR</English>
|
||||
<German>DAGR umschalten</German>
|
||||
<Polish>Przełącz DAGR</Polish>
|
||||
<Spanish>Mostrar DAGR</Spanish>
|
||||
<Russian>Вкл./выкл. DAGR</Russian>
|
||||
@ -27,6 +30,7 @@
|
||||
</Key>
|
||||
<Key ID="STR_ACE_DAGR_Description">
|
||||
<English>Defense Advanced GPS Receiver</English>
|
||||
<German>Defense Advanced GPS Receiver</German>
|
||||
<Polish>Defense Advanced GPS Receiver</Polish>
|
||||
<Spanish>Defense Advanced GPS Receiver</Spanish>
|
||||
<Russian>Военный многофункциональный GPS-приёмник</Russian>
|
||||
@ -34,4 +38,4 @@
|
||||
<Czech>Defense Advanced GPS Receiver</Czech>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
||||
</Project>
|
||||
|
@ -20,7 +20,7 @@ params ["_caller", "_target"];
|
||||
private "_display";
|
||||
#define DEFUALTPATH "\A3\Ui_f\data\GUI\Cfg\Ranks\%1_gs.paa"
|
||||
//Sanity Checks
|
||||
if (_caller != ACE_player) exitwith {ERROR("Player isn't caller?");};
|
||||
if (_caller != ACE_player) exitWith {ERROR("Player isn't caller?");};
|
||||
if (!([_player, _target] call FUNC(canPlayerDisarmUnit))) exitWith {ERROR("Can't Disarm Unit");};
|
||||
if (dialog) then {ERROR("Dialog open when trying to open disarm dialog"); closeDialog 0;};
|
||||
|
||||
@ -72,7 +72,7 @@ GVAR(disarmTarget) = _target;
|
||||
_icon = format [DEFUALTPATH, toLower (rank _target)];
|
||||
if (_icon isEqualTo DEFUALTPATH) then {_icon = ""};
|
||||
_rankPicture ctrlSetText _icon;
|
||||
_playerName ctrlSetText ([GVAR(disarmTarget)] call EFUNC(common,getName));
|
||||
_playerName ctrlSetText ([GVAR(disarmTarget), false, true] call EFUNC(common,getName));
|
||||
|
||||
//Clear both inventory lists:
|
||||
lbClear _groundContainer;
|
||||
|
@ -33,13 +33,13 @@ class GVAR(remoteInventory) {
|
||||
fadeout = 0;
|
||||
|
||||
class Colors {
|
||||
dragValidBgr[] = {"(profilenamespace getvariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getvariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getvariable ['IGUI_TEXT_RGB_B',1])",0.5};
|
||||
dragInvalidBgr[] = {"(profilenamespace getvariable ['IGUI_ERROR_RGB_R',0.8])","(profilenamespace getvariable ['IGUI_ERROR_RGB_G',0.0])","(profilenamespace getvariable ['IGUI_ERROR_RGB_B',0.0])",0.5};
|
||||
dragValidBar[] = {"(profilenamespace getvariable ['IGUI_WARNING_RGB_R',0.8])","(profilenamespace getvariable ['IGUI_WARNING_RGB_G',0.5])","(profilenamespace getvariable ['IGUI_WARNING_RGB_B',0.0])",0.5};
|
||||
dragInvalidBar[] = {"(profilenamespace getvariable ['IGUI_ERROR_RGB_R',0.8])","(profilenamespace getvariable ['IGUI_ERROR_RGB_G',0.0])","(profilenamespace getvariable ['IGUI_ERROR_RGB_B',0.0])",0.5};
|
||||
progressBar[] = {"(profilenamespace getvariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getvariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getvariable ['IGUI_TEXT_RGB_B',1])",1};
|
||||
progressBarBgr[] = {"(profilenamespace getvariable ['IGUI_BCG_RGB_R',0])","(profilenamespace getvariable ['IGUI_BCG_RGB_G',1])","(profilenamespace getvariable ['IGUI_BCG_RGB_B',1])",0.75};
|
||||
highlight[] = {"(profilenamespace getvariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getvariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getvariable ['IGUI_TEXT_RGB_B',1])",0.5};
|
||||
dragValidBgr[] = {"(profilenamespace getVariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getVariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getVariable ['IGUI_TEXT_RGB_B',1])",0.5};
|
||||
dragInvalidBgr[] = {"(profilenamespace getVariable ['IGUI_ERROR_RGB_R',0.8])","(profilenamespace getVariable ['IGUI_ERROR_RGB_G',0.0])","(profilenamespace getVariable ['IGUI_ERROR_RGB_B',0.0])",0.5};
|
||||
dragValidBar[] = {"(profilenamespace getVariable ['IGUI_WARNING_RGB_R',0.8])","(profilenamespace getVariable ['IGUI_WARNING_RGB_G',0.5])","(profilenamespace getVariable ['IGUI_WARNING_RGB_B',0.0])",0.5};
|
||||
dragInvalidBar[] = {"(profilenamespace getVariable ['IGUI_ERROR_RGB_R',0.8])","(profilenamespace getVariable ['IGUI_ERROR_RGB_G',0.0])","(profilenamespace getVariable ['IGUI_ERROR_RGB_B',0.0])",0.5};
|
||||
progressBar[] = {"(profilenamespace getVariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getVariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getVariable ['IGUI_TEXT_RGB_B',1])",1};
|
||||
progressBarBgr[] = {"(profilenamespace getVariable ['IGUI_BCG_RGB_R',0])","(profilenamespace getVariable ['IGUI_BCG_RGB_G',1])","(profilenamespace getVariable ['IGUI_BCG_RGB_B',1])",0.75};
|
||||
highlight[] = {"(profilenamespace getVariable ['IGUI_TEXT_RGB_R',0])","(profilenamespace getVariable ['IGUI_TEXT_RGB_G',1])","(profilenamespace getVariable ['IGUI_TEXT_RGB_B',1])",0.5};
|
||||
};
|
||||
|
||||
class controlsBackground {};
|
||||
|
@ -52,7 +52,7 @@ if !([_unit] call EFUNC(common,isPlayer)) then {
|
||||
//don't do anything until projectile is null (exploded/max range)
|
||||
if (isNull _projectile) then {
|
||||
//Remove PFEH:
|
||||
[_idPFH] call cba_fnc_removePerFrameHandler;
|
||||
[_idPFH] call CBA_fnc_removePerFrameHandler;
|
||||
|
||||
//If (tube is dropped) OR (is dead) OR (is player) just exit
|
||||
if (((secondaryWeapon _unit) != _tube) || {!alive _unit} || {([_unit] call EFUNC(common,isPlayer))}) exitWith {};
|
||||
|
@ -21,4 +21,4 @@ if !([_unit, _target, []] call EFUNC(common,canInteractWith)) exitWith {false};
|
||||
// a static weapon has to be empty for dragging (ignore UAV AI)
|
||||
if (((typeOf _target) isKindOf "StaticWeapon") && {{(getText (configFile >> "CfgVehicles" >> (typeOf _x) >> "simulation")) != "UAVPilot"} count crew _target > 0}) exitWith {false};
|
||||
|
||||
alive _target && {vehicle _target == _target} && {_target getVariable [QGVAR(canCarry), false]} && {animationState _target in ["", "unconscious"] || (_target getvariable ["ACE_isUnconscious", false]) || (_target isKindOf "CAManBase" && {(_target getHitPointDamage "HitLegs") > 0.4})}
|
||||
alive _target && {vehicle _target == _target} && {_target getVariable [QGVAR(canCarry), false]} && {animationState _target in ["", "unconscious"] || (_target getVariable ["ACE_isUnconscious", false]) || (_target isKindOf "CAManBase" && {(_target getHitPointDamage "HitLegs") > 0.4})}
|
||||
|
@ -24,4 +24,4 @@ if !([_unit, _target, []] call EFUNC(common,canInteractWith)) exitWith {false};
|
||||
// a static weapon has to be empty for dragging (ignore UAV AI)
|
||||
if ((typeOf _target) isKindOf "StaticWeapon" && {{(getText (configFile >> "CfgVehicles" >> (typeOf _x) >> "simulation")) != "UAVPilot"} count crew _target > 0}) exitWith {false};
|
||||
|
||||
alive _target && {vehicle _target == _target} && {_target getVariable [QGVAR(canDrag), false]} && {animationState _target in ["", "unconscious"] || (_target getvariable ["ACE_isUnconscious", false]) || (_target isKindOf "CAManBase" && {(_target getHitPointDamage "HitLegs") > 0.4})};
|
||||
alive _target && {vehicle _target == _target} && {_target getVariable [QGVAR(canDrag), false]} && {animationState _target in ["", "unconscious"] || (_target getVariable ["ACE_isUnconscious", false]) || (_target isKindOf "CAManBase" && {(_target getHitPointDamage "HitLegs") > 0.4})};
|
||||
|
@ -22,9 +22,9 @@ params ["_unit", "_target"];
|
||||
private "_inBuilding";
|
||||
_inBuilding = [_unit] call FUNC(isObjectOnObject);
|
||||
|
||||
if !(_unit getvariable ["ACE_isUnconscious", false]) then {
|
||||
// play release animation
|
||||
_unit playAction "released";
|
||||
if !(_unit getVariable ["ACE_isUnconscious", false]) then {
|
||||
// play release animation
|
||||
_unit playAction "released";
|
||||
};
|
||||
|
||||
// prevent collision damage
|
||||
@ -63,7 +63,7 @@ if !(_target isKindOf "CAManBase") then {
|
||||
["fixFloating", _target, _target] call EFUNC(common,targetEvent);
|
||||
};
|
||||
|
||||
if (_unit getvariable ["ACE_isUnconscious", false]) then {
|
||||
if (_unit getVariable ["ACE_isUnconscious", false]) then {
|
||||
[_unit, "unconscious", 2, true] call EFUNC(common,doAnimation);
|
||||
};
|
||||
|
||||
|
@ -31,7 +31,7 @@ detach _target;
|
||||
|
||||
// fix anim when aborting carrying persons
|
||||
if (_target isKindOf "CAManBase" || {animationState _unit in CARRY_ANIMATIONS}) then {
|
||||
if (vehicle _unit == _unit && {!(_unit getvariable ["ACE_isUnconscious", false])}) then {
|
||||
if (vehicle _unit == _unit && {!(_unit getVariable ["ACE_isUnconscious", false])}) then {
|
||||
[_unit, "", 2, true] call EFUNC(common,doAnimation);
|
||||
};
|
||||
|
||||
|
@ -39,7 +39,7 @@ _totalWeight = 0;
|
||||
];
|
||||
|
||||
// add Weight of create to totalWeight
|
||||
_totalWeight = _totalWeight + (getNumber (configFile >> "CfgVehicles" >> typeof _object >> "mass"));
|
||||
_totalWeight = _totalWeight + (getNumber (configFile >> "CfgVehicles" >> typeOf _object >> "mass"));
|
||||
|
||||
// Mass in Arma isn't an exact amount but rather a volume/weight value. This attempts to work around that by making it a usable value. (sort of).
|
||||
_totalWeight * 0.5
|
||||
|
@ -21,7 +21,6 @@ class CfgAmmo {
|
||||
|
||||
class DirectionalBombCore: TimeBombCore;
|
||||
class DirectionalBombBase: DirectionalBombCore;
|
||||
class APERSTripMine_Wire_Ammo: DirectionalBombBase;
|
||||
|
||||
class SLAMDirectionalMine_Wire_Ammo: DirectionalBombBase;
|
||||
|
||||
@ -31,11 +30,16 @@ class CfgAmmo {
|
||||
class DirectionalBombBase;
|
||||
class ClaymoreDirectionalMine_Remote_Ammo: DirectionalBombBase {
|
||||
ACE_Explosive = "ClaymoreDirectionalMine_Remote_Ammo_Scripted";
|
||||
GVAR(defuseObjectPosition[]) = {0, 0, 0.038};
|
||||
soundActivation[] = {"", 0, 0, 0};
|
||||
soundDeactivation[] = {"", 0, 0, 0};
|
||||
};
|
||||
//class ClaymoreDirectionalMine_Remote_Ammo_Scripted: ClaymoreDirectionalMine_Remote_Ammo;
|
||||
|
||||
class APERSTripMine_Wire_Ammo: DirectionalBombBase {
|
||||
GVAR(defuseObjectPosition[]) = {-1.415, 0, 0.12};
|
||||
};
|
||||
|
||||
class SLAMDirectionalMine_Wire_Ammo: DirectionalBombBase {
|
||||
indirectHitRange = 20;
|
||||
ACE_explodeOnDefuse = 1;
|
||||
@ -55,6 +59,7 @@ class CfgAmmo {
|
||||
class PipeBombBase;
|
||||
class DemoCharge_Remote_Ammo: PipeBombBase {
|
||||
ACE_Explosive = "DemoCharge_Remote_Ammo_Scripted";
|
||||
GVAR(defuseObjectPosition[]) = {0.07, 0, 0.055};
|
||||
soundActivation[] = {"", 0, 0, 0};
|
||||
soundDeactivation[] = {"", 0, 0, 0};
|
||||
hit = 500;
|
||||
@ -63,17 +68,18 @@ class CfgAmmo {
|
||||
};
|
||||
class SatchelCharge_Remote_Ammo: PipeBombBase {
|
||||
ACE_Explosive = "SatchelCharge_Remote_Ammo_Scripted";
|
||||
GVAR(defuseObjectPosition[]) = {0.1, 0.1, 0.05};
|
||||
soundActivation[] = {"", 0, 0, 0};
|
||||
soundDeactivation[] = {"", 0, 0, 0};
|
||||
};
|
||||
|
||||
|
||||
/*class DemoCharge_Remote_Ammo_Scripted: DemoCharge_Remote_Ammo;
|
||||
class SatchelCharge_Remote_Ammo_Scripted: SatchelCharge_Remote_Ammo;*/
|
||||
|
||||
|
||||
class IEDUrbanBig_Remote_Ammo: PipeBombBase {
|
||||
triggerWhenDestroyed = 1;
|
||||
ACE_explodeOnDefuse = 0.02;
|
||||
soundTrigger[] = {"A3\Sounds_F\weapons\mines\mech_trigger_1", 0.8, 1, 40};
|
||||
soundTrigger[] = {"A3\Sounds_F\weapons\mines\mech_trigger_1", 0.8, 1, 40};
|
||||
};
|
||||
class IEDUrbanBig_Command_Ammo: IEDUrbanBig_Remote_Ammo {
|
||||
mineTrigger = "RemoteTrigger";
|
||||
@ -81,19 +87,19 @@ class CfgAmmo {
|
||||
class IEDUrbanBig_Range_Ammo: IEDUrbanBig_Remote_Ammo {
|
||||
mineTrigger = "RangeTrigger";
|
||||
};
|
||||
|
||||
|
||||
class IEDUrbanSmall_Remote_Ammo: PipeBombBase {
|
||||
triggerWhenDestroyed = 1;
|
||||
ACE_explodeOnDefuse = 0.02;
|
||||
soundTrigger[] = {"A3\Sounds_F\weapons\mines\mech_trigger_1", 0.8, 1, 40};
|
||||
};
|
||||
class IEDUrbanSmall_Command_Ammo: IEDUrbanSmall_Remote_Ammo {
|
||||
};
|
||||
class IEDUrbanSmall_Command_Ammo: IEDUrbanSmall_Remote_Ammo {
|
||||
mineTrigger = "RemoteTrigger";
|
||||
};
|
||||
class IEDUrbanSmall_Range_Ammo: IEDUrbanSmall_Remote_Ammo {
|
||||
mineTrigger = "RangeTrigger";
|
||||
};
|
||||
|
||||
|
||||
class IEDLandBig_Remote_Ammo: PipeBombBase {
|
||||
triggerWhenDestroyed = 1;
|
||||
ACE_explodeOnDefuse = 0.02;
|
||||
@ -105,7 +111,7 @@ class CfgAmmo {
|
||||
class IEDLandBig_Range_Ammo: IEDLandBig_Remote_Ammo {
|
||||
mineTrigger = "RangeTrigger";
|
||||
};
|
||||
|
||||
|
||||
class IEDLandSmall_Remote_Ammo: PipeBombBase {
|
||||
triggerWhenDestroyed = 1;
|
||||
ACE_explodeOnDefuse = 0.02;
|
||||
|
@ -10,7 +10,6 @@ class CfgVehicles {
|
||||
showDisabled = 1;
|
||||
priority = 4;
|
||||
icon = PATHTOF(UI\Explosives_Menu_ca.paa);
|
||||
hotkey = "X";
|
||||
//Sub-menu items
|
||||
class ACE_Detonate {
|
||||
displayName = CSTRING(Detonate);
|
||||
@ -21,7 +20,6 @@ class CfgVehicles {
|
||||
showDisabled = 1;
|
||||
icon = PATHTOF(UI\Explosives_Menu_ca.paa);
|
||||
priority = 2;
|
||||
hotkey = "T";
|
||||
};
|
||||
class ACE_Place {
|
||||
displayName = CSTRING(Place);
|
||||
@ -32,7 +30,6 @@ class CfgVehicles {
|
||||
showDisabled = 1;
|
||||
icon = PATHTOF(UI\Place_Explosive_ca.paa);
|
||||
priority = 1;
|
||||
hotkey = "P";
|
||||
};
|
||||
class ACE_Cellphone {
|
||||
displayName = CSTRING(cellphone_displayName);
|
||||
@ -62,7 +59,7 @@ class CfgVehicles {
|
||||
class ACE_Actions {
|
||||
class ACE_MainActions {
|
||||
selection = "";
|
||||
distance = 5;
|
||||
distance = 1;
|
||||
condition = "true";
|
||||
class ACE_Defuse {
|
||||
displayName = CSTRING(Defuse);
|
||||
@ -72,8 +69,7 @@ class CfgVehicles {
|
||||
showDisabled = 0;
|
||||
icon = PATHTOF(UI\Defuse_ca.paa);
|
||||
priority = 0.8;
|
||||
hotkey = "F";
|
||||
distance = 5;
|
||||
distance = 1;
|
||||
};
|
||||
};
|
||||
};
|
||||
@ -89,16 +85,15 @@ class CfgVehicles {
|
||||
scope = 2;
|
||||
scopeCurator = 1;
|
||||
vehicleClass = "Cargo";
|
||||
ACE_offset[] = {0,0,0};
|
||||
class ACE_Actions {
|
||||
class ACE_MainActions {
|
||||
selection = "";
|
||||
distance = 5;
|
||||
distance = 1;
|
||||
condition = "true";
|
||||
class ACE_SetTrigger {
|
||||
selection = "";
|
||||
displayName = CSTRING(TriggerMenu);
|
||||
distance = 4;
|
||||
distance = 1;
|
||||
condition = "true";
|
||||
statement = "";
|
||||
insertChildren = QUOTE([ARR_3(_target getVariable QUOTE(QGVAR(class)),_target,_player)] call FUNC(addTriggerActions););
|
||||
@ -110,7 +105,7 @@ class CfgVehicles {
|
||||
class ACE_PickUp {
|
||||
selection = "";
|
||||
displayName = CSTRING(Pickup);
|
||||
distance = 4;
|
||||
distance = 1;
|
||||
condition = "true";
|
||||
statement = QUOTE([ARR_2(_player,_target getVariable QUOTE(QGVAR(class)))] call EFUNC(common,addToInventory);deleteVehicle _target;);
|
||||
showDisabled = 0;
|
||||
@ -125,6 +120,11 @@ class CfgVehicles {
|
||||
class ACE_Explosives_Place_DemoCharge:ACE_Explosives_Place {
|
||||
displayName = "Demo Charge";
|
||||
model = "\A3\Weapons_F\explosives\c4_charge_small_d";
|
||||
class ACE_Actions: ACE_Actions {
|
||||
class ACE_MainActions: ACE_MainActions {
|
||||
position = "[-0.07,0,0.055]";
|
||||
};
|
||||
};
|
||||
};
|
||||
class ACE_Explosives_Place_APERSBoundingMine:ACE_Explosives_Place {
|
||||
displayName = "APERS Bounding Mine";
|
||||
@ -137,7 +137,11 @@ class CfgVehicles {
|
||||
class ACE_Explosives_Place_APERSTripwireMine:ACE_Explosives_Place {
|
||||
displayName = "APERS Tripwire Mine";
|
||||
model = "\A3\Weapons_F\explosives\mine_AP_tripwire";
|
||||
ACE_offset[] = {1,0,0};
|
||||
class ACE_Actions: ACE_Actions {
|
||||
class ACE_MainActions: ACE_MainActions {
|
||||
position = "[1.415,0,0.12]";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
class ACE_Explosives_Place_ATMine:ACE_Explosives_Place {
|
||||
@ -148,11 +152,21 @@ class CfgVehicles {
|
||||
class ACE_Explosives_Place_Claymore:ACE_Explosives_Place {
|
||||
displayName = "Claymore";
|
||||
model = "\A3\Weapons_F\explosives\mine_AP_miniclaymore";
|
||||
class ACE_Actions: ACE_Actions {
|
||||
class ACE_MainActions: ACE_MainActions {
|
||||
position = "[0,0,0.038]";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
class ACE_Explosives_Place_SatchelCharge:ACE_Explosives_Place {
|
||||
displayName = "Satchel Charge";
|
||||
model = "\A3\Weapons_F\Explosives\satchel";
|
||||
class ACE_Actions: ACE_Actions {
|
||||
class ACE_MainActions: ACE_MainActions {
|
||||
position = "[-0.1,-0.1,0.05]";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
class ACE_Explosives_Place_SLAM:ACE_Explosives_Place {
|
||||
|
@ -19,9 +19,9 @@ class Rsc_ACE_CallScreen_Edit:RscEdit {
|
||||
colorText[] = {0,0,0,1};
|
||||
colorDisabled[] = {1,1,1,0.25};
|
||||
colorSelection[] = {
|
||||
"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])",
|
||||
"(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])",
|
||||
"(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])",
|
||||
"(profilenamespace getVariable ['GUI_BCG_RGB_R',0.69])",
|
||||
"(profilenamespace getVariable ['GUI_BCG_RGB_G',0.75])",
|
||||
"(profilenamespace getVariable ['GUI_BCG_RGB_B',0.5])",
|
||||
1
|
||||
};
|
||||
text = "";
|
||||
|
@ -43,7 +43,7 @@ GVAR(CurrentSpeedDial) = 0;
|
||||
GVAR(placeAction) = PLACE_CANCEL;
|
||||
};
|
||||
|
||||
//Show defuse actions on cfgAmmos (allMines):
|
||||
//Show defuse actions on CfgAmmos (allMines):
|
||||
_this call FUNC(interactEH);
|
||||
|
||||
}] call EFUNC(common,addEventHandler);
|
||||
|
@ -29,7 +29,7 @@ if ((_code) == "") exitWith {
|
||||
};
|
||||
{
|
||||
if ((_x select 0) == _name) exitWith {
|
||||
_speedDial set [_foreachindex, _this];
|
||||
_speedDial set [_forEachIndex, _this];
|
||||
_found = true;
|
||||
};
|
||||
} forEach _speedDial;
|
||||
|
@ -30,10 +30,10 @@ _result = true;
|
||||
|
||||
if (!_ignoreRange && {(_unit distance (_item select 0)) > _range}) exitWith {TRACE_1("out of range",_range); false};
|
||||
|
||||
if (getNumber (ConfigFile >> "CfgAmmo" >> typeof (_item select 0) >> "TriggerWhenDestroyed") == 0) then {
|
||||
if (getNumber (ConfigFile >> "CfgAmmo" >> typeOf (_item select 0) >> "TriggerWhenDestroyed") == 0) then {
|
||||
private ["_exp", "_previousExp"];
|
||||
_previousExp = _item select 0;
|
||||
_exp = getText (ConfigFile >> "CfgAmmo" >> typeof (_previousExp) >> "ACE_Explosive");
|
||||
_exp = getText (ConfigFile >> "CfgAmmo" >> typeOf (_previousExp) >> "ACE_Explosive");
|
||||
if (_exp != "") then {
|
||||
_exp = createVehicle [_exp, [0,0,15001], [], 0, "NONE"];
|
||||
_exp setDir (getDir _previousExp);
|
||||
|
@ -30,7 +30,7 @@ private "_explosive";
|
||||
_explosive = [_code] call FUNC(getSpeedDialExplosive);
|
||||
|
||||
if (_i >= (count _arr + 2)) then {
|
||||
[_pfID] call CALLSTACK(cba_fnc_removePerFrameHandler);
|
||||
[_pfID] call CALLSTACK(CBA_fnc_removePerFrameHandler);
|
||||
if ((count _explosive) > 0) then {
|
||||
[_unit, -1, [_explosive select 0, _explosive select 2]] call FUNC(detonateExplosive);
|
||||
};
|
||||
|
@ -44,9 +44,9 @@ _list = [];
|
||||
if (_adjustedList) then {
|
||||
_clackerList = _clackerList - ["X"];
|
||||
if (count _clackerList == 0) then {
|
||||
_unit SetVariable [QGVAR(Clackers), nil, true];
|
||||
_unit setVariable [QGVAR(Clackers), nil, true];
|
||||
} else {
|
||||
_unit SetVariable [QGVAR(Clackers), _clackerList, true];
|
||||
_unit setVariable [QGVAR(Clackers), _clackerList, true];
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -45,7 +45,17 @@ if (!("ACE_DefusalKit" in (items ACE_player))) exitWith {};
|
||||
if (((_x distance ACE_player) < 15) && {!(_x in _minesHelped)}) then {
|
||||
TRACE_2("Making Defuse Helper",(_x),(typeOf _x));
|
||||
_defuseHelper = "ACE_DefuseObject" createVehicleLocal (getPos _x);
|
||||
_defuseHelper attachTo [_x, [0,0,0]];
|
||||
|
||||
private _config = configFile >> "CfgAmmo" >> typeOf _x;
|
||||
|
||||
private _defuseObjectPosition = getArray (_config >> QGVAR(defuseObjectPosition));
|
||||
if (_defuseObjectPosition isEqualTo []) then {
|
||||
_defuseObjectPosition = [0,0,0];
|
||||
};
|
||||
|
||||
TRACE_1("DefuseObjectPosition",(_defuseObjectPosition));
|
||||
|
||||
_defuseHelper attachTo [_x, _defuseObjectPosition];
|
||||
_defuseHelper setVariable [QGVAR(Explosive),_x];
|
||||
_addedDefuseHelpers pushBack _defuseHelper;
|
||||
_minesHelped pushBack _x;
|
||||
|
@ -29,7 +29,7 @@ _config = ConfigFile >> "CfgWeapons" >> _item;
|
||||
if (isClass _config && {getNumber(_config >> "ACE_Detonator") == 1}) then {
|
||||
private ["_clackerItems"];
|
||||
_clackerItems = _giver getVariable [QGVAR(Clackers), []];
|
||||
_receiver SetVariable [QGVAR(Clackers), (_receiver getVariable [QGVAR(Clackers), []]) + _clackerItems, true];
|
||||
_receiver setVariable [QGVAR(Clackers), (_receiver getVariable [QGVAR(Clackers), []]) + _clackerItems, true];
|
||||
|
||||
_detonators = [_giver] call FUNC(getDetonators);
|
||||
if (count _detonators == 0) then {
|
||||
|
@ -62,8 +62,8 @@ if (isNumber (_magazineTrigger >> "digDistance")) then {
|
||||
_canDigDown = true;
|
||||
_surfaceType = surfaceType _pos;
|
||||
if ((_surfaceType select [0,1]) == "#") then {_surfaceType = _surfaceType select [1, 99];};
|
||||
if ((_surfaceType != "") || {isClass (configfile >> "CfgSurfaces" >> _surfaceType >> "soundEnviron")}) then {
|
||||
_soundEnviron = getText (configfile >> "CfgSurfaces" >> _surfaceType >> "soundEnviron");
|
||||
if ((_surfaceType != "") || {isClass (configFile >> "CfgSurfaces" >> _surfaceType >> "soundEnviron")}) then {
|
||||
_soundEnviron = getText (configFile >> "CfgSurfaces" >> _surfaceType >> "soundEnviron");
|
||||
TRACE_2("Dig Down Surface",_surfaceType,_soundEnviron);
|
||||
_canDigDown = !(_soundEnviron in ["road", "tarmac", "concrete", "concrete_int", "int_concrete", "concrete_ext"]);
|
||||
};
|
||||
|
@ -582,6 +582,7 @@
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Explosives_ExplodeOnDefuse_DisplayName">
|
||||
<English>Explode on defusal?</English>
|
||||
<German>Explodieren beim Entschärfen?</German>
|
||||
<Portuguese>Explosão no desarmamento?</Portuguese>
|
||||
<Polish>Eksplozja przy rozbrajaniu?</Polish>
|
||||
<Czech>Explodovat při zneškodňování?</Czech>
|
||||
@ -592,6 +593,7 @@
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Explosives_ExplodeOnDefuse_Description">
|
||||
<English>Enable certain explosives to explode on defusal? Default: Yes</English>
|
||||
<German>Sollen bestimmte Sprengladungen beim Entschärfen explodieren? Standard: Ja</German>
|
||||
<Portuguese>Ativa certos explosivos para detonar no desarmamento? Padrão: Sim</Portuguese>
|
||||
<Polish>Spraw, aby niektóre ładunki wybuchowe eksplodowały przy próbie ich rozbrojenia? Domyślnie:Tak</Polish>
|
||||
<Czech>Umožnit u některých výbušnin explozi při pokusu je zneškodnit? Výchozí: Ano</Czech>
|
||||
|
@ -19,5 +19,5 @@ GVAR(pfeh_id) = -1;
|
||||
_this call FUNC(keyPress);
|
||||
},
|
||||
{false},
|
||||
[41, [true, false, false]], true] call cba_fnc_addKeybind; // Shift + Tilda (hold)
|
||||
[41, [true, false, false]], true] call CBA_fnc_addKeybind; // Shift + Tilda (hold)
|
||||
}] call EFUNC(common,addEventHandler);
|
||||
|
@ -27,7 +27,7 @@ _fingerPos = if (_sourceUnit == ACE_player) then {
|
||||
_fingerPosPrecise vectorAdd [random (2*FP_RANDOMIZATION_X) - FP_RANDOMIZATION_X, random (2*FP_RANDOMIZATION_X) - FP_RANDOMIZATION_X, random (2*FP_RANDOMIZATION_Y) - FP_RANDOMIZATION_Y]
|
||||
};
|
||||
|
||||
_data = [ACE_diagTime, _fingerPos, ([_sourceUnit] call EFUNC(common,getName))];
|
||||
_data = [ACE_diagTime, _fingerPos, ([_sourceUnit, false, true] call EFUNC(common,getName))];
|
||||
HASH_SET(GVAR(fingersHash), _sourceUnit, _data);
|
||||
|
||||
if (GVAR(pfeh_id) == -1) then {
|
||||
|
@ -1,7 +1,7 @@
|
||||
//fnc_doExplosions.sqf
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_params", "_explosions", "_index", "_i", "_exp", "_refExp", "_bpos", "_hit", "_distance", "_indirectHitRange", "_depth"];
|
||||
//fnc_doExplosions.sqf
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_params", "_explosions", "_index", "_i", "_exp", "_refExp", "_bpos", "_hit", "_distance", "_indirectHitRange", "_depth"];
|
||||
_params = _this select 0;
|
||||
_explosions = _params select 0;
|
||||
_index = _params select 1;
|
||||
@ -20,7 +20,7 @@ for "_i" from _index to ((_index+2) min (count _explosions)) do {
|
||||
};
|
||||
_index = _index + 2;
|
||||
if(_index >= (count _explosions)) then {
|
||||
[(_this select 1)] call cba_fnc_removePerFrameHandler;
|
||||
[(_this select 1)] call CBA_fnc_removePerFrameHandler;
|
||||
} else {
|
||||
_params set[1, _index];
|
||||
};
|
||||
|
@ -1,7 +1,7 @@
|
||||
//fnc_doReflections.sqf
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_pos", "_ammo", "_depth", "_hit", "_range", "_hitFactor", "_indirectHitRange", "_indirectHit", "_testParams"];
|
||||
//fnc_doReflections.sqf
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_pos", "_ammo", "_depth", "_hit", "_range", "_hitFactor", "_indirectHitRange", "_indirectHit", "_testParams"];
|
||||
|
||||
_pos = _this select 0;
|
||||
_ammo = _this select 1;
|
||||
|
@ -1,6 +1,6 @@
|
||||
//fnc_findReflections.sqf
|
||||
#include "script_component.hpp"
|
||||
|
||||
//fnc_findReflections.sqf
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_split", "_radi", "_params", "_pos", "_explosiveInfo", "_los", "_nlos", "_zIndex", "_depth", "_indirectHitRange", "_indirectHit", "_distanceCount", "_lastPos", "_test", "_vec", "_testPos", "_buckets", "_excludes", "_bucketIndex", "_bucketPos", "_bucketList", "_c", "_index", "_blist", "_avgX", "_avgY", "_avgZ", "_bpos", "_distance", "_hitFactor", "_hit", "_range", "_refExp", "_rand", "_i", "_x", "_res", "_forEachIndex", "_explosions", "_can", "_dirvec", "_zAng"];
|
||||
|
||||
_params = _this select 0;
|
||||
@ -21,15 +21,15 @@ _indirectHit = _explosiveInfo select 1;
|
||||
_distanceCount = (floor _indirectHitRange*4) min 100;
|
||||
|
||||
if(_zIndex < 5) then {
|
||||
_lastPos = _pos;
|
||||
_zAng = _zIndex*20+2;
|
||||
if(_zAng > 80) then {
|
||||
_radi = 1;
|
||||
_zAng = 90;
|
||||
_lastPos = _pos;
|
||||
_zAng = _zIndex*20+2;
|
||||
if(_zAng > 80) then {
|
||||
_radi = 1;
|
||||
_zAng = 90;
|
||||
};
|
||||
for "_i" from 0 to _radi do {
|
||||
_test = true;
|
||||
_vec = [1, ((_i*_split)+_rand) mod 360, _zAng] call cba_fnc_polar2vect;
|
||||
_vec = [1, ((_i*_split)+_rand) mod 360, _zAng] call CBA_fnc_polar2vect;
|
||||
for "_x" from 1 to _distanceCount do {
|
||||
_testPos = _pos vectorAdd (_vec vectorMultiply _x);
|
||||
// drop ["\a3\data_f\Cl_basic","","Billboard",1,15,ASLtoATL _testPos,[0,0,0],1,1.275,1.0,0.0,[1],[[1,0,0,1]],[0],0.0,2.0,"","",""];
|
||||
@ -43,7 +43,7 @@ if(_zIndex < 5) then {
|
||||
// drop ["\a3\data_f\Cl_basic","","Billboard",1,15,ASLtoATL _testPos,[0,0,0],1,1.275,1.0,0.0,[1],[[1,0,0,1]],[0],0.0,2.0,"","",""];
|
||||
// TEST_PAIRS pushBack [_pos, _lastPos, [1,0,0,1]];
|
||||
|
||||
};
|
||||
};
|
||||
// if(terrainIntersectASL [_pos, _testPos]) exitWith {};
|
||||
_lastPos = _testPos;
|
||||
};
|
||||
@ -106,7 +106,7 @@ if(_zIndex < 5) then {
|
||||
_range = _range - (_range%2);
|
||||
|
||||
if(_hit >= 10 && _range > 0) then {
|
||||
// TEST_ICONS pushBack [_bpos, format["h: %1, r: %2, hf: %3 d: %4 ihr: %5", _hit, _range, _hitFactor, _distance, _indirectHitRange*4]];
|
||||
// TEST_ICONS pushBack [_bpos, format["h: %1, r: %2, hf: %3 d: %4 ihr: %5", _hit, _range, _hitFactor, _distance, _indirectHitRange*4]];
|
||||
// TEST_PAIRS pushBack [_pos, _bpos, [1,0,0,1]];
|
||||
_refExp = format["ace_explosion_reflection_%1_%2", _range, _hit];
|
||||
// _refExp createVehicle (ASLtoATL _bpos);
|
||||
@ -122,5 +122,5 @@ if(_zIndex < 5) then {
|
||||
// _dirvec = _dirvec vectorMultiply 100;
|
||||
// _can setVelocity _dirvec;
|
||||
[DFUNC(doExplosions), 0, [_explosions, 0]] call CBA_fnc_addPerFrameHandler;
|
||||
[(_this select 1)] call cba_fnc_removePerFrameHandler;
|
||||
[(_this select 1)] call CBA_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
@ -1,5 +1,5 @@
|
||||
#include "script_component.hpp"
|
||||
if(GVAR(tracesStarted)) then {
|
||||
GVAR(tracesStarted) = false;
|
||||
[GVAR(traceID)] call cba_fnc_removePerFrameHandler;
|
||||
[GVAR(traceID)] call CBA_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
@ -10,5 +10,5 @@ if (alive _tracerObj && (count GVAR(traces)) > 0) then {
|
||||
_positions = _data select 4;
|
||||
_positions set [(count _positions), [(getPos _tracerObj), vectorMagnitude (velocity _tracerObj)]];
|
||||
} else {
|
||||
[(_this select 1)] call cba_fnc_removePerFrameHandler;
|
||||
[(_this select 1)] call CBA_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
@ -10,7 +10,7 @@ class CfgVehicles {
|
||||
showDisabled = 1;
|
||||
priority = 3.5;
|
||||
icon = PATHTOF(UI\gestures_ca.paa);
|
||||
|
||||
|
||||
class GVAR(Advance) {
|
||||
displayName = CSTRING(BIgestureAdvance);
|
||||
condition = QUOTE(canStand _target);
|
||||
@ -116,7 +116,6 @@ class CfgVehicles {
|
||||
statement = QUOTE(_target playActionNow ([ARR_2('gestureYes','gestureNod')] select floor random 2););
|
||||
showDisabled = 1;
|
||||
priority = 1.1;
|
||||
hotkey = "8";
|
||||
};
|
||||
|
||||
class class GVAR(No) {
|
||||
@ -125,7 +124,6 @@ class CfgVehicles {
|
||||
statement = QUOTE(_target playActionNow 'gestureNo';);
|
||||
showDisabled = 1;
|
||||
priority = 1.0;
|
||||
hotkey = "9";
|
||||
};
|
||||
|
||||
class class GVAR(Hi) {
|
||||
@ -134,7 +132,6 @@ class CfgVehicles {
|
||||
statement = QUOTE(_target playActionNow ([ARR_3('gestureHi','gestureHiB','gestureHiC')] select floor random 3););
|
||||
showDisabled = 1;
|
||||
priority = 0.9;
|
||||
hotkey = "0";
|
||||
};
|
||||
*/
|
||||
|
||||
|
@ -92,7 +92,7 @@
|
||||
<Polish>Wskazać</Polish>
|
||||
<Czech>Ukázat</Czech>
|
||||
<French>Pointer</French>
|
||||
<Russian>Точка</Russian>
|
||||
<Russian>Показать направление</Russian>
|
||||
<Hungarian>Mutat</Hungarian>
|
||||
<Portuguese>Apontar</Portuguese>
|
||||
<Italian>Puntare a</Italian>
|
||||
@ -115,6 +115,8 @@
|
||||
<French>Stop</French>
|
||||
<German>Stop</German>
|
||||
<Polish>Stop</Polish>
|
||||
<Russian>Стоп</Russian>
|
||||
<Portuguese>Parar</Portuguese>
|
||||
</Key>
|
||||
<!-- COVER -->
|
||||
<Key ID="STR_ACE_Gestures_cover">
|
||||
@ -135,6 +137,8 @@
|
||||
<French>Regroupement</French>
|
||||
<German>Sammeln</German>
|
||||
<Polish>Zbiórka</Polish>
|
||||
<Russian>Собраться</Russian>
|
||||
<Portuguese>Reagrupar</Portuguese>
|
||||
</Key>
|
||||
<!-- FORWARD -->
|
||||
<Key ID="STR_ACE_Gestures_forward">
|
||||
@ -142,12 +146,16 @@
|
||||
<French>En avant</French>
|
||||
<German>Vorwärts Bewegen</German>
|
||||
<Polish>Naprzód</Polish>
|
||||
<Russian>Вперед</Russian>
|
||||
<Portuguese>Mover em frente</Portuguese>
|
||||
</Key>
|
||||
<!-- ENGAGE -->
|
||||
<Key ID="STR_ACE_Gestures_engage">
|
||||
<English>Engage</English>
|
||||
<French>Engager</French>
|
||||
<Polish>Atak</Polish>
|
||||
<Russian>Открыть огонь</Russian>
|
||||
<Portuguese>Engajar</Portuguese>
|
||||
</Key>
|
||||
<!-- POINT -->
|
||||
<Key ID="STR_ACE_Gestures_point">
|
||||
@ -155,6 +163,8 @@
|
||||
<French>Pointer</French>
|
||||
<German>Zeigen</German>
|
||||
<Polish>Wskaż</Polish>
|
||||
<Russian>Показать направление</Russian>
|
||||
<Portuguese>Ponta</Portuguese>
|
||||
</Key>
|
||||
<!-- HOLD -->
|
||||
<Key ID="STR_ACE_Gestures_hold">
|
||||
@ -162,6 +172,8 @@
|
||||
<French>Tenir</French>
|
||||
<German>Anhalten</German>
|
||||
<Polish>Wstrzymać</Polish>
|
||||
<Russian>Ждать</Russian>
|
||||
<Portuguese>Esperar</Portuguese>
|
||||
</Key>
|
||||
<!-- WARNING -->
|
||||
<Key ID="STR_ACE_Gestures_warning">
|
||||
@ -169,6 +181,8 @@
|
||||
<French>Attention</French>
|
||||
<German>Achtung</German>
|
||||
<Polish>Uwaga</Polish>
|
||||
<Russian>Внимание</Russian>
|
||||
<Portuguese>Aviso</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Gestures_Hi">
|
||||
<English>Hi</English>
|
||||
|
@ -114,16 +114,20 @@ private _fnc_checkGoggles = {
|
||||
|
||||
// goggles effects main PFH
|
||||
[{
|
||||
BEGIN_COUNTER(goggles);
|
||||
|
||||
// rain
|
||||
call FUNC(applyRainEffect);
|
||||
|
||||
// auto remove effects under water
|
||||
if (GVAR(EffectsActive) && {[goggles ACE_player] call FUNC(isDivingGoggles) && {underwater ACE_player}}) then {
|
||||
if (GVAR(EffectsActive) && {underwater ACE_player} && {[goggles ACE_player] call FUNC(isDivingGoggles)}) then {
|
||||
call FUNC(removeRainEffect);
|
||||
call FUNC(removeDirtEffect);
|
||||
call FUNC(removeDustEffect);
|
||||
};
|
||||
|
||||
// rotor wash effect
|
||||
call FUNC(applyRotorWashEffect)
|
||||
}, 0.5, _fnc_checkGoggles] call CBA_fnc_addPerFrameHandler;
|
||||
call FUNC(applyRotorWashEffect);
|
||||
|
||||
END_COUNTER(goggles);
|
||||
}, 0.5, []] call CBA_fnc_addPerFrameHandler;
|
||||
|
@ -15,7 +15,6 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
if (GVAR(showInThirdPerson)) exitWith {false};
|
||||
if (call FUNC(externalCamera)) exitWith {false};
|
||||
|
||||
private ["_unit", "_effects"];
|
||||
|
@ -15,7 +15,6 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
if (GVAR(showInThirdPerson)) exitWith {};
|
||||
if (call FUNC(ExternalCamera)) exitWith {};
|
||||
|
||||
private ["_unit", "_amount"];
|
||||
|
@ -15,4 +15,8 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
cameraView in ["EXTERNAL", "GROUP"] || EFUNC(common,isFeatureCameraActive) // return
|
||||
if (GVAR(showInThirdPerson)) then {
|
||||
cameraView in ["GROUP"] || EFUNC(common,isFeatureCameraActive)
|
||||
} else {
|
||||
cameraView in ["EXTERNAL", "GROUP"] || EFUNC(common,isFeatureCameraActive)
|
||||
};
|
||||
|
@ -37,7 +37,6 @@ _effects set [BROKEN, true];
|
||||
SETGLASSES(_unit,_effects);
|
||||
|
||||
if (getText (_config >> "ACE_OverlayCracked") != "") then {
|
||||
if (GVAR(showInThirdPerson)) exitWith {};
|
||||
if (call FUNC(ExternalCamera)) exitWith {};
|
||||
|
||||
if (isNull (GLASSDISPLAY)) then {
|
||||
|
@ -20,8 +20,7 @@ params ["_projectile"];
|
||||
if (alive _projectile) then {
|
||||
playSound3D ["A3\Sounds_F\weapons\Explosion\explosion_mine_1.wss", _projectile, false, getPosASL _projectile, 5, 1.2, 400];
|
||||
|
||||
private "_affected";
|
||||
_affected = _projectile nearEntities ["CAManBase", 50];
|
||||
private _affected = _projectile nearEntities ["CAManBase", 20];
|
||||
|
||||
["flashbangExplosion", _affected, [_projectile]] call EFUNC(common,targetEvent);
|
||||
};
|
||||
|
@ -11,7 +11,6 @@ class CfgVehicles {
|
||||
showDisabled = 0;
|
||||
priority = 2.5;
|
||||
icon = PATHTOF(UI\ACE_earplugs_x_ca.paa);
|
||||
hotkey = "E";
|
||||
};
|
||||
class ACE_RemoveEarplugs {
|
||||
displayName = CSTRING(EarPlugs_Off);
|
||||
@ -21,7 +20,6 @@ class CfgVehicles {
|
||||
showDisabled = 0;
|
||||
priority = 2.5;
|
||||
icon = PATHTOF(UI\ACE_earplugs_x_ca.paa);
|
||||
hotkey = "E";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -26,7 +26,7 @@ GVAR(time4) = 0;
|
||||
["playerChanged", {
|
||||
GVAR(deafnessDV) = 0;
|
||||
GVAR(deafnessPrior) = 0;
|
||||
ACE_player setvariable [QGVAR(deaf), false];
|
||||
ACE_player setVariable [QGVAR(deaf), false];
|
||||
|
||||
GVAR(beep) = false;
|
||||
GVAR(beep2) = false;
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user