Merge branch 'master' into trackToTrackedVehicles

Conflicts:
	addons/repair/stringtable.xml
This commit is contained in:
jonpas 2015-08-21 21:04:50 +02:00
commit ccd0a7bd88
118 changed files with 591 additions and 215 deletions

View File

@ -3,8 +3,9 @@ ace_advanced_ballistics
The Advanced Ballistics module introduces advanced external- and internal ballistics to the game. The Advanced Ballistics module introduces advanced external- and internal ballistics to the game.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)

View File

@ -1,9 +1,10 @@
ace_aircraft ace_aircraft
============ ============
Changes to air weaponry, flightmodels and HUDs. Changes to air weaponry, flight models and HUDs.
- Contributions by Kimi (geraldbolso1899) for HUD updates
* Contributations by Kimi (geraldbolso1899) for HUD updates
## Maintainers ## Maintainers
@ -11,4 +12,4 @@ The people responsible for merging changes to this component or answering potent
- [KoffeinFlummi](https://github.com/KoffeinFlummi) - [KoffeinFlummi](https://github.com/KoffeinFlummi)
- [commy2](https://github.com/commy2) - [commy2](https://github.com/commy2)
- [jaynus](https://github.com/walterpearce) - [jaynus](https://github.com/walterpearce)

11
addons/apl/README.md Normal file
View File

@ -0,0 +1,11 @@
ace_apl
============
Assets licensed under Arma Public License (APL).
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- None

View File

@ -3,8 +3,9 @@ ace_atragmx
ATragMX - Handheld ballistics calculator ATragMX - Handheld ballistics calculator
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)

View File

@ -2,7 +2,9 @@ ace_attach
========== ==========
Introducing the ability to attach various throwables to yourself or vehicles, to mark your position and assist in IFF. Introducing the ability to attach various throwables to yourself or vehicles, to mark your position and assist in IFF.
Adds item `ACE_IR_Strobe_Item`.
#### Items Added:
`ACE_IR_Strobe_Item`
## Maintainers ## Maintainers

View File

@ -1,7 +1,8 @@
ace_backpacks ace_backpacks
================= =================
Adds indication when someone else opens your backpack (soundeffect / camShake). Adds indication when someone else opens your backpack (sound effect and camera shake).
## Maintainers ## Maintainers

View File

@ -3,10 +3,11 @@ ace_ballistics
Changes to weapon, magazine and ammunition values. Changes to weapon, magazine and ammunition values.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)
- [KoffeinFlummi](https://github.com/KoffeinFlummi) - [KoffeinFlummi](https://github.com/KoffeinFlummi)
- [commy2](https://github.com/commy2) - [commy2](https://github.com/commy2)

View File

@ -1,10 +1,10 @@
ace_captives ace_captives
============ ============
Allows taking people captive/handcuffed Adds ability to handcuff and surrender.
####Items: #### Items Added:
`ACE_CableTie` - adds ability to take someone captive `ACE_CableTie`
## Maintainers ## Maintainers

View File

@ -4,6 +4,6 @@ class ACE_Settings {
description = CSTRING(ModuleSettings_enable_Description); description = CSTRING(ModuleSettings_enable_Description);
typeName = "BOOL"; typeName = "BOOL";
value = 1; value = 1;
category = CSTRING(settingsCategory); category = ECSTRING(OptionsMenu,CategoryLogistics);
}; };
}; };

View File

@ -76,4 +76,22 @@ class Extended_Init_EventHandlers {
init = QUOTE(_this call DFUNC(initVehicle)); init = QUOTE(_this call DFUNC(initVehicle));
}; };
}; };
class ACE_RepairItem_Base {
class ADDON {
init = QUOTE(_this call DFUNC(initObject));
};
};
class ACE_bodyBagObject {
class ADDON {
init = QUOTE(_this call DFUNC(initObject));
};
};
class ACE_ConcertinaWireCoil {
class ADDON {
init = QUOTE(_this call DFUNC(initObject));
};
};
}; };

View File

@ -4,7 +4,7 @@ class CfgVehicles {
scope = 2; scope = 2;
displayName = CSTRING(SettingsModule_DisplayName); displayName = CSTRING(SettingsModule_DisplayName);
icon = QUOTE(PATHTOF(UI\Icon_Module_Cargo_ca.paa)); icon = QUOTE(PATHTOF(UI\Icon_Module_Cargo_ca.paa));
category = "ACE"; category = "ACE_Logistics";
function = QFUNC(moduleSettings); function = QFUNC(moduleSettings);
functionPriority = 1; functionPriority = 1;
isGlobal = 1; isGlobal = 1;

12
addons/cargo/README.md Normal file
View File

@ -0,0 +1,12 @@
ace_cargo
============
Adds cargo menu to vehicles and allows loading and unloading of cargo items.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [commy2](https://github.com/commy2)
- [Glowbal](https://github.com/Glowbal)

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project name="ACE"> <Project name="ACE">
<Package name="Cargo"> <Package name="Cargo">
<Key ID="STR_ACE_Cargo_loadObject"> <Key ID="STR_ACE_Cargo_loadObject">
@ -16,9 +16,6 @@
<Key ID="STR_ACE_Cargo_labelSpace"> <Key ID="STR_ACE_Cargo_labelSpace">
<English>Cargo space left: %1</English> <English>Cargo space left: %1</English>
</Key> </Key>
<Key ID="STR_ACE_Cargo_settingsCategory">
<English>Cargo</English>
</Key>
<Key ID="STR_ACE_Cargo_ModuleSettings_enable"> <Key ID="STR_ACE_Cargo_ModuleSettings_enable">
<English>Enable Cargo</English> <English>Enable Cargo</English>
</Key> </Key>

View File

@ -84,7 +84,7 @@ if (_state) then {
openMap true; 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 (isServer || {serverCommandAvailable "#kick"} || {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 { if (!(_key in (actionKeys "DefaultAction" + actionKeys "Throw")) && {_key in (actionKeys "Chat" + actionKeys "PrevChannel" + actionKeys "NextChannel")}) then {
_key = 0; _key = 0;
}; };

View File

@ -1,31 +1,35 @@
/* /*
* Author: Sniperwolf572 * Author: Sniperwolf572
* Checks if one of the following common feature cameras is active:
* *
* Checks if one of the following BI feature cameras are active: * - Curator
* * - ACE Spectator
* - Classic camera (BIS_fnc_cameraOld)
* - Splendid camera (BIS_fnc_camera)
* - Arsenal camera (BIS_fnc_arsenal) * - Arsenal camera (BIS_fnc_arsenal)
* - Animation viewer (BIS_fnc_animViewer)
* - Establishing shot (BIS_fnc_establishingShot) * - Establishing shot (BIS_fnc_establishingShot)
* - Splendid camera (BIS_fnc_camera)
* - Animation viewer (BIS_fnc_animViewer)
* - Classic camera (BIS_fnc_cameraOld)
* *
* Arguments: * Arguments:
* None * 0: None <NIL>
* *
* Return value: * Return Value:
* Is BI feature camera active (bool) * A feature camera is active <BOOL>
* *
* Example: * Example:
* call ace_common_fnc_isFeatureCameraActive; * [] call ace_common_fnc_isFeatureCameraActive
* *
* Public: No
*/ */
#include "script_component.hpp" #include "script_component.hpp"
( !(
!isNull (missionNamespace getVariable ["BIS_DEBUG_CAM", objNull]) || // Classic camera isNull curatorCamera && // Curator
{!isNull (missionNamespace getVariable ["BIS_fnc_camera_cam", objNull])} || // Splendid camera {isNull (GETMVAR(EGVAR(spectator,camera),objNull))} && // ACE Spectator
{!isNull (uiNamespace getVariable ["BIS_fnc_arsenal_cam", objNull])} || // Arsenal camera {isNull (GETUVAR(BIS_fnc_arsenal_cam, objNull))} && // Arsenal camera
{!isNull (uiNamespace getVariable ["BIS_fnc_animViewer_cam", objNull])} || // Animation viewer camera {isNull (GETMVAR(BIS_fnc_establishingShot_fakeUAV, objNull))} && // Establishing shot camera
{!isNull (missionNamespace getVariable ["BIS_fnc_establishingShot_fakeUAV", objNull])} // Establishing shot camera {isNull (GETMVAR(BIS_fnc_camera_cam, objNull))} && // Splendid camera
) {isNull (GETUVAR(BIS_fnc_animViewer_cam, objNull))} && // Animation viewer camera
{isNull (GETMVAR(BIS_DEBUG_CAM, objNull))} // Classic camera
)

View File

@ -3,7 +3,7 @@ class CfgVehicles {
class Fence; class Fence;
class thingX; class thingX;
class NonStrategic; class NonStrategic;
class ACE_ConcertinaWireNoGeo: Fence { class ACE_ConcertinaWireNoGeo: Fence {
XEH_ENABLED; XEH_ENABLED;
scope = 1; scope = 1;
@ -48,7 +48,7 @@ class CfgVehicles {
class wire_16: wire_2{}; class wire_16: wire_2{};
class wire_17: wire_2{}; class wire_17: wire_2{};
class wire_18: wire_2{}; class wire_18: wire_2{};
class wire_2_1: wire_2 { class wire_2_1: wire_2 {
animPeriod = 8; animPeriod = 8;
}; };
@ -67,7 +67,7 @@ class CfgVehicles {
class wire_15_1: wire_2_1 {}; class wire_15_1: wire_2_1 {};
class wire_16_1: wire_2_1 {}; class wire_16_1: wire_2_1 {};
class wire_17_1: wire_2_1 {}; class wire_17_1: wire_2_1 {};
class wire_18_1: wire_2_1 {}; class wire_18_1: wire_2_1 {};
}; };
}; };
class ACE_ConcertinaWire: ACE_ConcertinaWireNoGeo { class ACE_ConcertinaWire: ACE_ConcertinaWireNoGeo {
@ -113,6 +113,8 @@ class CfgVehicles {
EGVAR(dragging,canDrag) = 1; EGVAR(dragging,canDrag) = 1;
EGVAR(dragging,dragPosition[]) = {0,0.5,0.5}; EGVAR(dragging,dragPosition[]) = {0,0.5,0.5};
EGVAR(dragging,dragDirection) = 0; EGVAR(dragging,dragDirection) = 0;
EGVAR(cargo,size) = 1;
EGVAR(cargo,canLoad) = 1;
class ACE_Actions { class ACE_Actions {
class ACE_MainActions { class ACE_MainActions {
selection = ""; selection = "";
@ -133,7 +135,7 @@ class CfgVehicles {
}; };
}; };
}; };
class Land_Razorwire_F: NonStrategic { class Land_Razorwire_F: NonStrategic {
XEH_ENABLED; XEH_ENABLED;
}; };

View File

@ -3,8 +3,9 @@ ace_concertina_wire
Adds concertina wire. Adds concertina wire.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)

View File

@ -1,10 +1,11 @@
ace_dagr ace_dagr
=============== ===============
Defense Advanced GPS Receiver Adds Defense Advanced GPS Receiver.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)

View File

@ -1,7 +1,7 @@
ace_disposable ace_disposable
============== ==============
Makes the NLAW a disposable one-shot weapon. Makes the NLAW a disposable one-shot weapon and provides disposable launchers framework for use by other mods.
## Maintainers ## Maintainers

12
addons/dragging/README.md Normal file
View File

@ -0,0 +1,12 @@
ace_dragging
==============
Adds ability to drag and carry objects.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [Garth "L-H" de Wet](https://github.com/CorruptedHeart)
- [commy2](https://github.com/commy2)

View File

@ -6,7 +6,7 @@ class CfgPatches {
weapons[] = {}; weapons[] = {};
requiredVersion = REQUIRED_VERSION; requiredVersion = REQUIRED_VERSION;
requiredAddons[] = {"ace_interaction"}; requiredAddons[] = {"ace_interaction"};
author[] = {"Garth 'L-H' de Wet","commy2"}; author[] = {"Garth 'L-H' de Wet", "commy2"};
authorUrl = "https://github.com/commy2/"; authorUrl = "https://github.com/commy2/";
VERSION_CONFIG; VERSION_CONFIG;
}; };

View File

@ -1,7 +1,7 @@
ace_fcs ace_fcs
======= =======
Adds a fire control system to armoured vehicles and helicoters, allowing the precise engagement of stationary and moving targets. Adds a fire control system to armoured vehicles and helicopters, allowing precise engagement of stationary and moving targets.
## Maintainers ## Maintainers

11
addons/fonts/README.md Normal file
View File

@ -0,0 +1,11 @@
ace_fonts
========
Custom fonts including fixed-width font.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [jaynus](https://github.com/jaynus/)

View File

@ -0,0 +1,11 @@
ace_hitreactions
===========
Adds reactions when getting shot.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [commy2](https://github.com/commy2)

11
addons/huntir/README.md Normal file
View File

@ -0,0 +1,11 @@
ace_huntir
===========
Adds High-altitude Unit Navigated Tactical Imaging Round and its Monitor.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg](http://github.com/Ulteq)

View File

@ -0,0 +1,12 @@
ace_interact_menu
===========
Base framework for interaction menu.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [NouberNou](https://github.com/NouberNou)
- [esteldunedain](https://github.com/esteldunedain)

View File

@ -3,6 +3,7 @@ ace_interaction
Provides interaction options between units. Provides interaction options between units.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.

View File

@ -1,7 +1,7 @@
ace_inventory ace_inventory
============= =============
Increases the size of the inventory dialog. Adds options to increase the size of the inventory dialog.
## Maintainers ## Maintainers

View File

@ -1,10 +1,11 @@
ace_kestrel4500 ace_kestrel4500
=============== ===============
Kestrel 4500 Pocket Weather Tracker Adds Kestrel 4500 Pocket Weather Tracker.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)

View File

@ -1,7 +1,10 @@
ace_logistics_uavbattery ace_logistics_uavbattery
=========== ===========
Adds an item `ACE_UAVBattery` that allows refueling/recharging of the "Dartar" quadcopter UAVs. Adds an item that allows refueling/recharging of the Darter quadcopter UAVs.
#### Items Added:
`ACE_UAVBattery`
## Maintainers ## Maintainers

View File

@ -1,7 +1,10 @@
ace_logistics_wirecutter ace_logistics_wirecutter
=========== ===========
Adds an item `ACE_wirecutter` that allows cutting of fences in A3 and AiA maps. Adds an item that allows cutting of fences in Aarma 3 and AiA/CUP maps.
#### Items Added:
`ACE_wirecutter`
## Maintainers ## Maintainers

View File

@ -1,7 +1,8 @@
ace_magazinerepack ace_magazinerepack
================== ==================
Adds the ability to consolidate multiple half-empty magazines. Adds the ability to consolidate multiple unfull magazines.
## Maintainers ## Maintainers

View File

@ -7,7 +7,7 @@
* 1: Player <OBJECT> * 1: Player <OBJECT>
* *
* Return value: * Return value:
* ChildActiosn<ARRAY> * ChildActions <ARRAY>
* *
* Example: * Example:
* [player, player] call ace_magazinerepack_fnc_getMagazineChildren * [player, player] call ace_magazinerepack_fnc_getMagazineChildren
@ -16,15 +16,17 @@
*/ */
#include "script_component.hpp" #include "script_component.hpp"
private ["_unitMagazines", "_unitMagCounts", "_xFullMagazineCount", "_index", "_actions", "_displayName", "_picture", "_action"]; private ["_unitMagazines", "_unitMagCounts", "_index", "_actions", "_displayName", "_picture", "_action"];
PARAMS_2(_target,_player); params ["_target", "_player"];
// get all mags and ammo count // get all mags and ammo count
_unitMagazines = []; _unitMagazines = [];
_unitMagCounts = []; _unitMagCounts = [];
{ {
EXPLODE_4_PVT(_x,_xClassname,_xCount,_xLoaded,_xType); private "_xFullMagazineCount";
_x params ["_xClassname", "_xCount", "_xLoaded", "_xType"];
_xFullMagazineCount = getNumber (configfile >> "CfgMagazines" >> _xClassname >> "count"); _xFullMagazineCount = getNumber (configfile >> "CfgMagazines" >> _xClassname >> "count");
//for every partial magazine, that is either in inventory or can be moved there //for every partial magazine, that is either in inventory or can be moved there

View File

@ -10,7 +10,7 @@
* 3: Error Code <NUMBER> * 3: Error Code <NUMBER>
* *
* Return Value: * Return Value:
* Nothing * None
* *
* Example: * Example:
* (args from progressBar) call ace_magazinerepack_fnc_magazineRepackFinish * (args from progressBar) call ace_magazinerepack_fnc_magazineRepackFinish
@ -21,8 +21,9 @@
private ["_structuredOutputText", "_picture", "_fullMags", "_partialMags", "_fullMagazineCount"]; private ["_structuredOutputText", "_picture", "_fullMags", "_partialMags", "_fullMagazineCount"];
PARAMS_4(_args,_elapsedTime,_totalTime,_errorCode); params ["_args", "_elapsedTime", "_totalTime", "_errorCode"];
EXPLODE_2_PVT(_args,_magazineClassname,_lastAmmoCount); _args params ["_magazineClassname", "_lastAmmoCount"];
_fullMagazineCount = getNumber (configfile >> "CfgMagazines" >> _magazineClassname >> "count"); _fullMagazineCount = getNumber (configfile >> "CfgMagazines" >> _magazineClassname >> "count");
//Don't show anything if player can't interact: //Don't show anything if player can't interact:

View File

@ -20,17 +20,19 @@
private ["_currentAmmoCount", "_addedMagazines", "_missingAmmo", "_index", "_updateMagazinesOnPlayerFnc"]; private ["_currentAmmoCount", "_addedMagazines", "_missingAmmo", "_index", "_updateMagazinesOnPlayerFnc"];
PARAMS_3(_args,_elapsedTime,_totalTime); params ["_ars", "_elapsedTime", "_totalTime"];
EXPLODE_3_PVT(_args,_magazineClassname,_lastAmmoCount,_simEvents); _args params ["_magazineClassname", "_lastAmmoCount", "_simEvents"];
if ((count _simEvents) == 0) exitWith {ERROR("No Event"); false};
EXPLODE_3_PVT((_simEvents select 0),_nextEventTime,_nextEventIsBullet,_nextEventMags);
if (_nextEventTime > _elapsedTime) exitWith {true};//waiting on next event if !((_simEvents select 0) params ["_nextEventTime", "_nextEventIsBullet", "_nextEventMags"]) exitWith { ERROR("No Event"); false };
if (_nextEventTime > _elapsedTime) exitWith { true };//waiting on next event
//Verify we aren't missing any ammo //Verify we aren't missing any ammo
_currentAmmoCount = []; _currentAmmoCount = [];
{ {
EXPLODE_2_PVT(_x,_xClassname,_xCount); _x params ["_xClassname", "_xCount"];
if (_xClassname == _magazineClassname) then { if (_xClassname == _magazineClassname) then {
_currentAmmoCount pushBack _xCount; _currentAmmoCount pushBack _xCount;
}; };
@ -50,7 +52,7 @@ _missingAmmo = false;
}; };
} forEach _lastAmmoCount; } forEach _lastAmmoCount;
if (_missingAmmo) exitWith {false}; //something removed ammo that was being repacked (could be other players or scripts) if (_missingAmmo) exitWith { false }; //something removed ammo that was being repacked (could be other players or scripts)
_updateMagazinesOnPlayerFnc = { _updateMagazinesOnPlayerFnc = {
ACE_player removeMagazines _magazineClassname; //remove inventory magazines ACE_player removeMagazines _magazineClassname; //remove inventory magazines
@ -75,4 +77,4 @@ if (_nextEventIsBullet) then {
_simEvents deleteAt 0; //pop off the event _simEvents deleteAt 0; //pop off the event
true; true

View File

@ -19,20 +19,20 @@
*/ */
#include "script_component.hpp" #include "script_component.hpp"
private ["_newMagFnc", "_time", "_events", "_swapAmmoFnc", "_ammoSwaped", "_lowIndex", "_highIndex", "_ammoToTransfer", "_ammoAvailable", "_ammoNeeded", "_swapProgress"]; private ["_fnc_newMag", "_time", "_events", "_fnc_swapAmmo", "_ammoSwaped", "_lowIndex", "_highIndex", "_ammoToTransfer", "_ammoAvailable", "_ammoNeeded", "_swapProgress"];
PARAMS_3(_fullMagazineCount,_arrayOfAmmoCounts,_isBelt); params ["_fullMagazineCount", "_arrayOfAmmoCounts", "_isBelt"];
// Sort Ascending - Don't modify original // Sort Ascending - Don't modify original
_arrayOfAmmoCounts = +_arrayOfAmmoCounts; _arrayOfAmmoCounts = +_arrayOfAmmoCounts;
_arrayOfAmmoCounts sort true; _arrayOfAmmoCounts sort true;
_newMagFnc = { _fnc_newMag = {
_time = _time + GVAR(TimePerMagazine); _time = _time + GVAR(TimePerMagazine);
_events pushBack [_time, false, +_arrayOfAmmoCounts]; _events pushBack [_time, false, +_arrayOfAmmoCounts];
}; };
_swapAmmoFnc = if (_isBelt) then { _fnc_swapAmmo = if (_isBelt) then {
{ {
_time = _time + GVAR(TimePerBeltLink); _time = _time + GVAR(TimePerBeltLink);
_arrayOfAmmoCounts set [_lowIndex, ((_arrayOfAmmoCounts select _lowIndex) - _ammoSwaped)]; _arrayOfAmmoCounts set [_lowIndex, ((_arrayOfAmmoCounts select _lowIndex) - _ammoSwaped)];
@ -64,14 +64,14 @@ while {_lowIndex < _highIndex} do {
if (_ammoAvailable == 0) then { if (_ammoAvailable == 0) then {
_lowIndex = _lowIndex + 1; _lowIndex = _lowIndex + 1;
call _newMagFnc; call _fnc_newMag;
} else { } else {
if (_ammoNeeded == 0) then { if (_ammoNeeded == 0) then {
_highIndex = _highIndex - 1; _highIndex = _highIndex - 1;
call _newMagFnc; call _fnc_newMag;
} else { } else {
_ammoSwaped = _ammoAvailable min _ammoNeeded; _ammoSwaped = _ammoAvailable min _ammoNeeded;
call _swapAmmoFnc; call _fnc_swapAmmo;
}; };
}; };
}; };

View File

@ -21,7 +21,7 @@
private ["_magazineCfg", "_fullMagazineCount", "_isBelt", "_startingAmmoCounts", "_simEvents", "_totalTime"]; private ["_magazineCfg", "_fullMagazineCount", "_isBelt", "_startingAmmoCounts", "_simEvents", "_totalTime"];
PARAMS_3(_target,_player,_magazineClassname); params ["_target", "_player", "_magazineClassname"];
if (isNil "_magazineClassname" || {_magazineClassname == ""}) exitWith {ERROR("Bad Mag Classname");}; if (isNil "_magazineClassname" || {_magazineClassname == ""}) exitWith {ERROR("Bad Mag Classname");};
_magazineCfg = configfile >> "CfgMagazines" >> _magazineClassname; _magazineCfg = configfile >> "CfgMagazines" >> _magazineClassname;
@ -63,11 +63,11 @@ _simEvents = [_fullMagazineCount, _startingAmmoCounts, _isBelt] call FUNC(simula
_totalTime = (_simEvents select ((count _simEvents) - 1) select 0); _totalTime = (_simEvents select ((count _simEvents) - 1) select 0);
[ [
_totalTime, _totalTime,
[_magazineClassname, _startingAmmoCounts, _simEvents], [_magazineClassname, _startingAmmoCounts, _simEvents],
{_this call FUNC(magazineRepackFinish)}, {_this call FUNC(magazineRepackFinish)},
{_this call FUNC(magazineRepackFinish)}, {_this call FUNC(magazineRepackFinish)},
(localize LSTRING(RepackingMagazine)), (localize LSTRING(RepackingMagazine)),
{_this call FUNC(magazineRepackProgress)}, {_this call FUNC(magazineRepackProgress)},
["isNotInside", "isNotSitting"] ["isNotInside", "isNotSitting"]
] call EFUNC(common,progressBar); ] call EFUNC(common,progressBar);

View File

@ -5,4 +5,7 @@ class CfgFactionClasses {
priority = 2; priority = 2;
side = 7; side = 7;
}; };
class ACE_Logistics: ACE {
displayName = CSTRING(Category_Logistics);
};
}; };

View File

@ -0,0 +1,5 @@
class CfgVehicleClasses {
class ACE_Logistics_Items {
displayName = CSTRING(Category_Logistics);
};
};

View File

@ -1,4 +1,4 @@
#include "script_component.hpp" #include "script_component.hpp"
class CfgPatches { class CfgPatches {
class ADDON { class ADDON {
@ -587,3 +587,4 @@ class CfgSettings {
}; };
#include "CfgModuleCategories.hpp" #include "CfgModuleCategories.hpp"
#include "CfgVehicleClasses.hpp"

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<Project name="ACE">
<Package name="Main">
<Key ID="STR_ACE_Main_Category_Logistics">
<English>ACE Logistics</English>
</Key>
</Package>
</Project>

View File

@ -1,12 +1,12 @@
ace_map ace_map
======= =======
Various tweaks to the in-game map. Including: Various tweaks to the in-game map, including:
- Better map styling (countours, legend, hiding bushes and trees, etc). - Better map styling (countours, legend, hiding bushes and trees, etc).
- Max zoom level (optional) - Max zoom level (optional)
- Map shaking while walking (optional) - Map shaking while walking (optional)
- Map illumination (optional) - Map illumination (optional)
- Blufor tracker (optional) - Blue Force Tracker (optional)
## Maintainers ## Maintainers

View File

@ -1,11 +1,12 @@
ace_maptools ace_maptools
============ ============
Map tools: Adds the following map tools:
- Roamer - Roamer
- Map drawing - Map drawing
- Showing GPS on map - Showing GPS on map
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.

View File

@ -697,6 +697,8 @@ class CfgVehicles {
EGVAR(dragging,canDrag) = 1; EGVAR(dragging,canDrag) = 1;
EGVAR(dragging,dragPosition[]) = {0,1.2,0}; EGVAR(dragging,dragPosition[]) = {0,1.2,0};
EGVAR(dragging,dragDirection) = 0; EGVAR(dragging,dragDirection) = 0;
EGVAR(cargo,size) = 1;
EGVAR(cargo,canLoad) = 1;
class ACE_Actions { class ACE_Actions {
class ACE_MainActions { class ACE_MainActions {
displayName = ECSTRING(interaction,MainAction); displayName = ECSTRING(interaction,MainAction);

View File

@ -3,6 +3,7 @@ ace_medical
Provides a basic and advanced medical system. Provides a basic and advanced medical system.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -13,6 +13,7 @@
*/ */
#include "script_component.hpp" #include "script_component.hpp"
#define MAX_DISTANCE 10
// Exit for basic medical // Exit for basic medical
if (GVAR(level) < 2) exitWith {}; if (GVAR(level) < 2) exitWith {};
@ -39,6 +40,11 @@ if (_show) then {
if (GVAR(displayPatientInformationTarget) != _target || GVAR(currentSelectedSelectionN) != _selectionN) exitwith { if (GVAR(displayPatientInformationTarget) != _target || GVAR(currentSelectedSelectionN) != _selectionN) exitwith {
[_this select 1] call CBA_fnc_removePerFrameHandler; [_this select 1] call CBA_fnc_removePerFrameHandler;
}; };
if (ACE_player distance _target > MAX_DISTANCE) exitwith {
("ACE_MedicalRscDisplayInformation" call BIS_fnc_rscLayer) cutText ["","PLAIN"];
[_this select 1] call CBA_fnc_removePerFrameHandler;
["displayTextStructured", [ACE_player], [[LSTRING(DistanceToFar), [_target] call EFUNC(common,getName)], 1.75, ACE_player]] call EFUNC(common,targetEvent);
};
disableSerialization; disableSerialization;
_display = uiNamespace getvariable QGVAR(DisplayInformation); _display = uiNamespace getvariable QGVAR(DisplayInformation);

View File

@ -176,8 +176,17 @@ if (vehicle _caller == _caller && {_callerAnim != ""}) then {
_caller selectWeapon (primaryWeapon _caller); // unit always has a primary weapon here _caller selectWeapon (primaryWeapon _caller); // unit always has a primary weapon here
}; };
if (stance _caller == "STAND") then { if (isWeaponDeployed _caller) then {
_caller setvariable [QGVAR(treatmentPrevAnimCaller), "amovpknlmstpsraswrfldnon"]; TRACE_1("Weapon Deployed, breaking out first",(stance _caller));
[_caller, "", 0] call EFUNC(common,doAnimation);
};
if ((stance _caller) == "STAND") then {
switch (_wpn) do {//If standing, end in a crouched animation based on their current weapon
case ("rfl"): {_caller setvariable [QGVAR(treatmentPrevAnimCaller), "AmovPknlMstpSrasWrflDnon"];};
case ("pst"): {_caller setvariable [QGVAR(treatmentPrevAnimCaller), "AmovPknlMstpSrasWpstDnon"];};
case ("non"): {_caller setvariable [QGVAR(treatmentPrevAnimCaller), "AmovPknlMstpSnonWnonDnon"];};
};
} else { } else {
_caller setvariable [QGVAR(treatmentPrevAnimCaller), animationState _caller]; _caller setvariable [QGVAR(treatmentPrevAnimCaller), animationState _caller];
}; };

View File

@ -18,20 +18,20 @@ private ["_caller","_target", "_reviveStartTime"];
_caller = _this select 0; _caller = _this select 0;
_target = _this select 1; _target = _this select 1;
if (_target getvariable [QGVAR(inReviveState), false]) exitwith { if (_target getvariable [QGVAR(inReviveState), false]) then {
_reviveStartTime = _target getvariable [QGVAR(reviveStartTime),0]; _reviveStartTime = _target getvariable [QGVAR(reviveStartTime),0];
if (_reviveStartTime > 0) then { if (_reviveStartTime > 0) then {
_target setvariable [QGVAR(reviveStartTime), (_reviveStartTime + random(20)) min ACE_time]; _target setvariable [QGVAR(reviveStartTime), (_reviveStartTime + random(20)) min ACE_time];
}; };
}; };
if (random(1)>= 0.6) exitwith { if ((random 1) >= 0.6) then {
_target setvariable [QGVAR(inCardiacArrest), nil,true]; _target setvariable [QGVAR(inCardiacArrest), nil,true];
_target setvariable [QGVAR(heartRate), 40]; _target setvariable [QGVAR(heartRate), 40];
_target setvariable [QGVAR(bloodPressure), [50,70]]; _target setvariable [QGVAR(bloodPressure), [50,70]];
}; };
[_target, "activity", LSTRING(Activity_fullHeal), [[_caller] call EFUNC(common,getName)]] call FUNC(addToLog); [_target, "activity", LSTRING(Activity_CPR), [[_caller] call EFUNC(common,getName)]] call FUNC(addToLog);
[_target, "activity_view", LSTRING(Activity_fullHeal), [[_caller] call EFUNC(common,getName)]] call FUNC(addToLog); // TODO expand message [_target, "activity_view", LSTRING(Activity_CPR), [[_caller] call EFUNC(common,getName)]] call FUNC(addToLog); // TODO expand message
true; true;

View File

@ -2098,6 +2098,9 @@
<Portuguese>%1 aplicou um torniquete</Portuguese> <Portuguese>%1 aplicou um torniquete</Portuguese>
<Czech>%1 použil škrtidlo</Czech> <Czech>%1 použil škrtidlo</Czech>
</Key> </Key>
<Key ID="STR_ACE_Medical_Activity_CPR">
<English>%1 performed CPR</English>
</Key>
<Key ID="STR_ACE_Medical_HeavilyWounded"> <Key ID="STR_ACE_Medical_HeavilyWounded">
<English>Heavily wounded</English> <English>Heavily wounded</English>
<German>Schwer verwundet:</German> <German>Schwer verwundet:</German>
@ -3609,5 +3612,8 @@
<Spanish>Médico</Spanish> <Spanish>Médico</Spanish>
<Hungarian>Orvosi</Hungarian> <Hungarian>Orvosi</Hungarian>
</Key> </Key>
<Key ID="STR_ACE_Medical_DistanceToFar">
<English>Distance to %1 has become to far for treatment</English>
</Key>
</Package> </Package>
</Project> </Project>

View File

@ -3,6 +3,7 @@ ace_medical_menu
Provides the CSE medical menu for the advanced medical system. Provides the CSE medical menu for the advanced medical system.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.

View File

@ -26,9 +26,10 @@ if (!hasInterface) exitwith {};
false false
}, },
{ {
if (ACE_time - GVAR(lastOpenedOn) > 0.5) then { if (ACE_time - GVAR(lastOpenedOn) > 0.5) exitWith {
[ObjNull] call FUNC(openMenu); [ObjNull] call FUNC(openMenu);
}; };
false
}, },
[35, [false, false, false]], false, 0] call CBA_fnc_addKeybind; [35, [false, false, false]], false, 0] call CBA_fnc_addKeybind;

View File

@ -14,6 +14,7 @@
* Public: No * Public: No
*/ */
#include "script_component.hpp" #include "script_component.hpp"
#define MAX_DISTANCE 10
private "_target"; private "_target";
@ -72,6 +73,12 @@ setMousePosition [0.4, 0.4];
_status = [GVAR(INTERACTION_TARGET)] call FUNC(getTriageStatus); _status = [GVAR(INTERACTION_TARGET)] call FUNC(getTriageStatus);
(_display displayCtrl 2000) ctrlSetText (_status select 0); (_display displayCtrl 2000) ctrlSetText (_status select 0);
(_display displayCtrl 2000) ctrlSetBackgroundColor (_status select 2); (_display displayCtrl 2000) ctrlSetBackgroundColor (_status select 2);
if (ACE_player distance _target > MAX_DISTANCE) exitwith {
closeDialog 314412;
["displayTextStructured", [ACE_player], [[ELSTRING(medical,DistanceToFar), [_target] call EFUNC(common,getName)], 1.75, ACE_player]] call EFUNC(common,targetEvent);
};
}, [_display]] call BIS_fnc_addStackedEventHandler; }, [_display]] call BIS_fnc_addStackedEventHandler;
["Medical_onMenuOpen", [ACE_player, _interactionTarget]] call EFUNC(common,localEvent); ["Medical_onMenuOpen", [ACE_player, _interactionTarget]] call EFUNC(common,localEvent);

View File

@ -6,7 +6,7 @@
* 0: Target <OBJECT> * 0: Target <OBJECT>
* *
* Return Value: * Return Value:
* None * If action was taken <BOOL>
* *
* Example: * Example:
* [some_player] call ace_medical_menu_openMenu * [some_player] call ace_medical_menu_openMenu
@ -18,16 +18,22 @@
params ["_interactionTarget"]; params ["_interactionTarget"];
if (dialog || isNull _interactionTarget) exitwith { if (dialog || isNull _interactionTarget) exitwith {
disableSerialization; disableSerialization;
private "_display"; private ["_display", "_handled"];
_display = uiNamespace getVariable QGVAR(medicalMenu); _handled = false;
if (!isNil "_display") then { _display = uiNamespace getVariable QGVAR(medicalMenu);
closeDialog 314412; if (!isNil "_display") then {
}; closeDialog 314412;
_handled = true;
};
_handled
}; };
GVAR(INTERACTION_TARGET) = _interactionTarget; GVAR(INTERACTION_TARGET) = _interactionTarget;
createDialog QGVAR(medicalMenu); createDialog QGVAR(medicalMenu);
GVAR(lastOpenedOn) = ACE_time; GVAR(lastOpenedOn) = ACE_time;
true

View File

@ -1,7 +1,7 @@
ace_microdagr ace_microdagr
=============== ===============
Adds a microDAGR infentry GPS device. Adds a MicroDAGR infantry GPS device.
Press home to open. Then home again to toggle an interactive version. Press CTRL+Home to close. Press home to open. Then home again to toggle an interactive version. Press CTRL+Home to close.
Info/Compass/Minimap modes are selectable by the bottom buttons. Tap the top bar to open the menu and access Mark/Waypoints/Connect To/Settings modes. Info/Compass/Minimap modes are selectable by the bottom buttons. Tap the top bar to open the menu and access Mark/Waypoints/Connect To/Settings modes.
Tap the minimap button again to toggle map modes (if available). Tap the minimap button again to toggle map modes (if available).
@ -9,13 +9,14 @@ Enter waypoints from the menu or double tapping on the minimap.
Can interface with the `ace_vector`. Hold Azimuth+Range and release (see page 14 of vector's manual) Can interface with the `ace_vector`. Hold Azimuth+Range and release (see page 14 of vector's manual)
#### Items Added: #### Items Added:
`ACE_microDAGR` `ACE_microDAGR`
## For Mission Makers: ## For Mission Makers:
#### Modules: #### Modules:
* MicroDAGR Map Fill - Controls the amount of map data avaialbe for the minimap. Can limit to just roads/topographical or disable entirely. - MicroDAGR Map Fill - Controls the amount of map data available for the minimap. Can limit to just roads/topographical or disable entirely.
## Maintainers ## Maintainers

View File

@ -0,0 +1,11 @@
ace_missionmodules
===========
Adds mission modules.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [Glowbal](https://github.com/Glowbal)

View File

@ -1,7 +1,8 @@
ace_mk6mortar ace_mk6mortar
========== ==========
Tweaks the mk6 mortar from Arma3 Tweaks the Nk6 Mortar system.
## Maintainers ## Maintainers

11
addons/modules/README.md Normal file
View File

@ -0,0 +1,11 @@
ace_modules
===========
Provides framework for module handling.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [Glowbal](https://github.com/Glowbal)

View File

@ -3,8 +3,9 @@ ace_mx2a
Adds the MX-2A thermal imaging device. Adds the MX-2A thermal imaging device.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)

11
addons/noidle/README.md Normal file
View File

@ -0,0 +1,11 @@
ace_noidle
===========
Removes idle animations.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [commy2](https://github.com/commy2)

11
addons/norearm/README.md Normal file
View File

@ -0,0 +1,11 @@
ace_norearm
===========
Removes rearm action.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [commy2](https://github.com/commy2)

View File

@ -1,7 +1,7 @@
ace_optics ace_optics
=============== ===============
Adds animated 2D optics. Some of them use picture in picture. Adds animated 2D and PiP (picture-in-picture) optics.
## Maintainers ## Maintainers

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project name="ACE"> <Project name="ACE">
<Package name="OptionsMenu"> <Package name="OptionsMenu">
<Key ID="STR_ACE_OptionsMenu_OpenConfigMenu"> <Key ID="STR_ACE_OptionsMenu_OpenConfigMenu">
@ -349,5 +349,8 @@
<English>All Categories</English> <English>All Categories</English>
<Polish>Wszystkie kategorie</Polish> <Polish>Wszystkie kategorie</Polish>
</Key> </Key>
<Key ID="STR_ACE_OptionsMenu_CategoryLogistics">
<English>Logistics</English>
</Key>
</Package> </Package>
</Project> </Project>

View File

@ -1,7 +1,7 @@
ace_overpressure ace_overpressure
============= =============
Adds backblast to AT launchers and overpressure zones to tank cannons. Adds backblast area to AT launchers and overpressure zones to tank cannons.
## Maintainers ## Maintainers

View File

@ -3,6 +3,7 @@ ace_parachute
Improves parachutes and adds an altimeter. Improves parachutes and adds an altimeter.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.

View File

@ -1,7 +1,7 @@
ace_ragdolls ace_ragdolls
============ ============
Tweaks the ragdoll behaviour to be more resposive to bullet impacts and explosions. Tweaks the ragdoll behaviour to be more responsive to bullet impacts and explosions.
## Maintainers ## Maintainers

View File

@ -1,10 +1,11 @@
ace_rangecards ace_rangecards
=============== ===============
Adds range cards Adds range cards.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)

View File

@ -1,7 +1,7 @@
ace_realisticnames ace_realisticnames
================== ==================
Changes the names of various weapons and vehicles to those of their RL counterparts. Changes the names of various weapons and vehicles to those of their real life counterparts.
## Maintainers ## Maintainers

11
addons/recoil/README.md Normal file
View File

@ -0,0 +1,11 @@
ace_recoil
===========
Tweaks weapon recoils and adds camera shake.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [commy2](https://github.com/commy2)

View File

@ -0,0 +1,11 @@
ace_reloadlaunchers
===========
Add the ability to reload someone else's launcher.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [commy2](https://github.com/commy2)

View File

@ -6,8 +6,8 @@ class CfgPatches {
weapons[] = {}; weapons[] = {};
requiredVersion = REQUIRED_VERSION; requiredVersion = REQUIRED_VERSION;
requiredAddons[] = {"ace_interaction"}; requiredAddons[] = {"ace_interaction"};
author[] = {""}; author[] = {"commy2"};
authorUrl = ""; authorUrl = "https://github.com/commy2";
VERSION_CONFIG; VERSION_CONFIG;
}; };
}; };

View File

@ -5,7 +5,7 @@ class ACE_Settings {
typeName = "BOOL"; typeName = "BOOL";
isClientSettable = 1; isClientSettable = 1;
value = 1; value = 1;
category = CSTRING(categoryName); category = ECSTRING(OptionsMenu,CategoryLogistics);
}; };
class GVAR(engineerSetting_Repair) { class GVAR(engineerSetting_Repair) {
displayName = CSTRING(enginerSetting_Repair_name); displayName = CSTRING(enginerSetting_Repair_name);
@ -13,7 +13,7 @@ class ACE_Settings {
typeName = "SCALAR"; typeName = "SCALAR";
value = 1; value = 1;
values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)}; values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)};
category = CSTRING(categoryName); category = ECSTRING(OptionsMenu,CategoryLogistics);
}; };
class GVAR(engineerSetting_Wheel) { class GVAR(engineerSetting_Wheel) {
displayName = CSTRING(enginerSetting_Wheel_name); displayName = CSTRING(enginerSetting_Wheel_name);
@ -21,21 +21,21 @@ class ACE_Settings {
typeName = "SCALAR"; typeName = "SCALAR";
value = 0; value = 0;
values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)}; values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)};
category = CSTRING(categoryName); category = ECSTRING(OptionsMenu,CategoryLogistics);
}; };
class GVAR(repairDamageThreshold) { class GVAR(repairDamageThreshold) {
displayName = CSTRING(repairDamageThreshold_name); displayName = CSTRING(repairDamageThreshold_name);
description = CSTRING(repairDamageThreshold_description); description = CSTRING(repairDamageThreshold_description);
typeName = "SCALAR"; typeName = "SCALAR";
value = 0.6; value = 0.6;
category = CSTRING(categoryName); category = ECSTRING(OptionsMenu,CategoryLogistics);
}; };
class GVAR(repairDamageThreshold_Engineer) { class GVAR(repairDamageThreshold_Engineer) {
displayName = CSTRING(repairDamageThreshold_Engineer_name); displayName = CSTRING(repairDamageThreshold_Engineer_name);
description = CSTRING(repairDamageThreshold_Engineer_description); description = CSTRING(repairDamageThreshold_Engineer_description);
typeName = "SCALAR"; typeName = "SCALAR";
value = 0.4; value = 0.4;
category = CSTRING(categoryName); category = ECSTRING(OptionsMenu,CategoryLogistics);
}; };
class GVAR(consumeItem_ToolKit) { class GVAR(consumeItem_ToolKit) {
displayName = CSTRING(consumeItem_ToolKit_name); displayName = CSTRING(consumeItem_ToolKit_name);
@ -43,7 +43,7 @@ class ACE_Settings {
typeName = "SCALAR"; typeName = "SCALAR";
value = 1; value = 1;
values[] = {ECSTRING(common,No), ECSTRING(common,Yes)}; values[] = {ECSTRING(common,No), ECSTRING(common,Yes)};
category = CSTRING(categoryName); category = ECSTRING(OptionsMenu,CategoryLogistics);
}; };
class GVAR(fullRepairLocation) { class GVAR(fullRepairLocation) {
displayName = CSTRING(fullRepairLocation); displayName = CSTRING(fullRepairLocation);
@ -51,7 +51,7 @@ class ACE_Settings {
typeName = "SCALAR"; typeName = "SCALAR";
value = 2; value = 2;
values[] = {CSTRING(useAnywhere), CSTRING(repairVehicleOnly), CSTRING(repairFacilityOnly), CSTRING(vehicleAndFacility), ECSTRING(common,Disabled)}; values[] = {CSTRING(useAnywhere), CSTRING(repairVehicleOnly), CSTRING(repairFacilityOnly), CSTRING(vehicleAndFacility), ECSTRING(common,Disabled)};
category = CSTRING(categoryName); category = ECSTRING(OptionsMenu,CategoryLogistics);
}; };
class GVAR(engineerSetting_fullRepair) { class GVAR(engineerSetting_fullRepair) {
displayName = CSTRING(engineerSetting_fullRepair_name); displayName = CSTRING(engineerSetting_fullRepair_name);
@ -59,7 +59,7 @@ class ACE_Settings {
typeName = "SCALAR"; typeName = "SCALAR";
value = 3; value = 3;
values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)}; values[] = {CSTRING(engineerSetting_anyone), CSTRING(engineerSetting_EngineerOnly), CSTRING(engineerSetting_RepairSpecialistOnly)};
category = CSTRING(categoryName); category = ECSTRING(OptionsMenu,CategoryLogistics);
}; };
class GVAR(addSpareParts) { class GVAR(addSpareParts) {
displayName = CSTRING(addSpareParts_name); displayName = CSTRING(addSpareParts_name);

View File

@ -40,9 +40,4 @@ class Extended_Init_EventHandlers {
init = QUOTE(_this call DFUNC(addRepairActions); _this call DFUNC(addSpareParts)); init = QUOTE(_this call DFUNC(addRepairActions); _this call DFUNC(addSpareParts));
}; };
}; };
class ACE_RepairItem_Base {
class ADDON {
init = QUOTE(if (!isnil QUOTE(QEFUNC(cargo,initObject))) then {_this call EFUNC(cargo,initObject)});
};
};
}; };

View File

@ -1,5 +0,0 @@
class CfgVehicleClasses {
class GVAR(items) {
displayName = "ACE";
};
};

View File

@ -16,12 +16,11 @@
class CfgVehicles { class CfgVehicles {
class ACE_Module; class ACE_Module;
// @todo localization for all the modules
class ACE_moduleRepairSettings: ACE_Module { class ACE_moduleRepairSettings: ACE_Module {
scope = 2; scope = 2;
displayName = CSTRING(moduleName); displayName = CSTRING(moduleName);
icon = QUOTE(PATHTOF(ui\Icon_Module_Repair_ca.paa)); //@todo icon = QUOTE(PATHTOF(ui\Icon_Module_Repair_ca.paa));
category = "ACE"; category = "ACE_Logistics";
function = QFUNC(moduleRepairSettings); function = QFUNC(moduleRepairSettings);
functionPriority = 1; functionPriority = 1;
isGlobal = 1; isGlobal = 1;
@ -109,7 +108,7 @@ class CfgVehicles {
scope = 2; scope = 2;
displayName = CSTRING(AssignEngineerRole_Module_DisplayName); displayName = CSTRING(AssignEngineerRole_Module_DisplayName);
icon = QUOTE(PATHTOF(ui\Icon_Module_Repair_ca.paa)); icon = QUOTE(PATHTOF(ui\Icon_Module_Repair_ca.paa));
category = "ACE"; category = "ACE_Logistics";
function = QFUNC(moduleAssignEngineer); function = QFUNC(moduleAssignEngineer);
functionPriority = 10; functionPriority = 10;
isGlobal = 2; isGlobal = 2;
@ -153,7 +152,7 @@ class CfgVehicles {
scope = 2; scope = 2;
displayName = CSTRING(AssignRepairVehicle_Module_DisplayName); displayName = CSTRING(AssignRepairVehicle_Module_DisplayName);
icon = QUOTE(PATHTOF(ui\Icon_Module_Repair_ca.paa)); icon = QUOTE(PATHTOF(ui\Icon_Module_Repair_ca.paa));
category = "ACE"; category = "ACE_Logistics";
function = QFUNC(moduleAssignRepairVehicle); function = QFUNC(moduleAssignRepairVehicle);
functionPriority = 10; functionPriority = 10;
isGlobal = 2; isGlobal = 2;
@ -298,7 +297,7 @@ class CfgVehicles {
icon = "iconObject_circle"; icon = "iconObject_circle";
mapSize = 0.7; mapSize = 0.7;
accuracy = 0.2; accuracy = 0.2;
vehicleClass = QGVAR(items); vehicleClass = "ACE_Logistics_Items";
destrType = "DesturctNo"; destrType = "DesturctNo";
}; };
@ -308,7 +307,7 @@ class CfgVehicles {
author = "Hawkins"; author = "Hawkins";
scope = 2; scope = 2;
model = QUOTE(PATHTOF(data\ace_track.p3d)); model = QUOTE(PATHTOF(data\ace_track.p3d));
displayName = "$STR_ACE_Repair_SpareTrack"; displayName = CSTRING(SpareTrack);
}; };
class ACE_Wheel: ACE_RepairItem_Base { class ACE_Wheel: ACE_RepairItem_Base {
@ -317,7 +316,7 @@ class CfgVehicles {
author = "Hawkins"; author = "Hawkins";
scope = 2; scope = 2;
model = QUOTE(PATHTOF(data\ace_wheel.p3d)); model = QUOTE(PATHTOF(data\ace_wheel.p3d));
displayName = "$STR_ACE_Repair_SpareWheel"; displayName = CSTRING(SpareWheel);
picture = QUOTE(PATHTOF(ui\tire_ca.paa)); picture = QUOTE(PATHTOF(ui\tire_ca.paa));
}; };

12
addons/repair/README.md Normal file
View File

@ -0,0 +1,12 @@
ace_repair
===========
Adds repair system.
## Maintainers
The people responsible for merging changes to this component or answering potential questions.
- [commy2](https://github.com/commy2)
- [Glowbal](https://github.com/Glowbal)

View File

@ -12,11 +12,8 @@ class CfgPatches {
}; };
}; };
#include "CfgEventHandlers.hpp"
#include "CfgActions.hpp"
#include "CfgVehicleClasses.hpp"
#include "CfgVehicles.hpp"
#include "ACE_Settings.hpp"
#include "ACE_Repair.hpp" #include "ACE_Repair.hpp"
#include "ACE_Settings.hpp"
#include "CfgEventHandlers.hpp"
#include "CfgActions.hpp"
#include "CfgVehicles.hpp"

View File

@ -666,9 +666,5 @@
<Key ID="STR_ACE_Repair_AddSpareParts_Amount_Description"> <Key ID="STR_ACE_Repair_AddSpareParts_Amount_Description">
<English>Number of selected spare parts.</English> <English>Number of selected spare parts.</English>
</Key> </Key>
<Key ID="STR_ACE_Repair_categoryName">
<English>Vehicle Repair</English>
</Key>
</Package> </Package>
</Project> </Project>

View File

@ -2,7 +2,6 @@
ADDON = false; ADDON = false;
PREP(firstMode);
PREP(lockSafety); PREP(lockSafety);
PREP(playChangeFiremodeSound); PREP(playChangeFiremodeSound);
PREP(setSafeModeVisual); PREP(setSafeModeVisual);

View File

@ -1,9 +0,0 @@
// by commy2
#include "script_component.hpp"
PARAMS_1(_weapon);
private ["_mode"];
_mode = getArray (configFile >> "CfgWeapons" >> _weapon >> "modes") select 0;
[_mode, _weapon] select (_mode == "this")

View File

@ -1,12 +1,29 @@
// by commy2 /*
* Author: commy2
* Put weapon on safety, or take it off safety if safety is already put on.
*
* Arguments:
* 0: Unit <OBJECT>
* 1: Weapon <STRING>
* 2: Muzzle <STRING>
*
* Return Value:
* None
*
* Example:
* [ACE_player, currentWeapon ACE_player, currentMuzzle ACE_player] call ace_safemode_fnc_lockSafety
*
* Public: No
*/
#include "script_component.hpp" #include "script_component.hpp"
PARAMS_3(_unit,_weapon,_muzzle);
// don't immediately switch back // don't immediately switch back
if (inputAction "nextWeapon" > 0) exitWith {}; if (inputAction "nextWeapon" > 0) exitWith {};
private ["_safedWeapons"]; private ["_safedWeapons", "_condition", "_statement", "_id", "_picture"];
params ["_unit", "_weapon", "_muzzle"];
_safedWeapons = _unit getVariable [QGVAR(safedWeapons), []]; _safedWeapons = _unit getVariable [QGVAR(safedWeapons), []];
if (_weapon in _safedWeapons) exitWith { if (_weapon in _safedWeapons) exitWith {
@ -18,15 +35,14 @@ _safedWeapons pushBack _weapon;
_unit setVariable [QGVAR(safedWeapons), _safedWeapons]; _unit setVariable [QGVAR(safedWeapons), _safedWeapons];
if (_unit getVariable [QGVAR(actionID), -1] == -1) then { if (_unit getVariable [QGVAR(actionID), -1] == -1) then {
private ["_condition", "_statement", "_id"];
_condition = { _condition = {
params ["", "_caller"];
if ( if (
[_this select 1] call EFUNC(common,canUseWeapon) [_caller] call EFUNC(common,canUseWeapon)
&& { && {
if (currentMuzzle (_this select 1) in ((_this select 1) getVariable [QGVAR(safedWeapons), []])) then { if (currentMuzzle _caller in (_caller getVariable [QGVAR(safedWeapons), []])) then {
if (inputAction "nextWeapon" > 0) exitWith { if (inputAction "nextWeapon" > 0) exitWith {
[_this select 1, currentWeapon (_this select 1), currentMuzzle (_this select 1)] call FUNC(unlockSafety); [_this select 1, currentWeapon _caller, currentMuzzle _caller] call FUNC(unlockSafety);
false false
}; };
true true
@ -44,7 +60,8 @@ if (_unit getVariable [QGVAR(actionID), -1] == -1) then {
}; };
_statement = { _statement = {
[_this select 1, currentWeapon (_this select 1), currentMuzzle (_this select 1)] call FUNC(unlockSafety); params ["", "_caller"];
[_caller, currentWeapon _caller, currentMuzzle _caller] call FUNC(unlockSafety);
}; };
//_id = [_unit, format ["<t color=""#FFFF00"" >%1</t>", localize LSTRING(TakeOffSafety)], "DefaultAction", _condition, {}, {true}, _statement, 10] call EFUNC(common,addActionMenuEventHandler); //_id = [_unit, format ["<t color=""#FFFF00"" >%1</t>", localize LSTRING(TakeOffSafety)], "DefaultAction", _condition, {}, {true}, _statement, 10] call EFUNC(common,addActionMenuEventHandler);
@ -54,12 +71,11 @@ if (_unit getVariable [QGVAR(actionID), -1] == -1) then {
}; };
if ((typeName _muzzle) == (typeName "")) then { if ((typeName _muzzle) == (typeName "")) then {
_unit selectWeapon _muzzle;//_weapon _unit selectWeapon _muzzle; //_weapon
}; };
// play fire mode selector sound // play fire mode selector sound
[_unit, _weapon, _muzzle] call FUNC(playChangeFiremodeSound); [_unit, _weapon, _muzzle] call FUNC(playChangeFiremodeSound);
private "_picture";
_picture = getText (configFile >> "CfgWeapons" >> _weapon >> "picture"); _picture = getText (configFile >> "CfgWeapons" >> _weapon >> "picture");
[localize LSTRING(PutOnSafety), _picture] call EFUNC(common,displayTextPicture); [localize LSTRING(PutOnSafety), _picture] call EFUNC(common,displayTextPicture);

View File

@ -1,9 +1,25 @@
// by commy2 /*
* Author: commy2
* Play weapon firemode change sound.
*
* Arguments:
* 0: Unit <OBJECT>
* 1: Weapon <STRING>
*
* Return Value:
* None
*
* Example:
* [ACE_player, currentWeapon ACE_player] call ace_safemode_fnc_playChangeFiremodeSound
*
* Public: No
*/
#include "script_component.hpp" #include "script_component.hpp"
PARAMS_2(_unit,_weapon); private ["_sound", "_position"];
params ["_unit", "_weapon"];
private ["_sound"];
_sound = getArray (configFile >> "CfgWeapons" >> _weapon >> "changeFiremodeSound"); _sound = getArray (configFile >> "CfgWeapons" >> _weapon >> "changeFiremodeSound");
if (count _sound == 0) exitWith { if (count _sound == 0) exitWith {
@ -15,13 +31,8 @@ if ({(toLower (_sound select 0) find _x == (count toArray (_sound select 0) - co
_sound set [0, (_sound select 0) + ".wss"]; _sound set [0, (_sound select 0) + ".wss"];
}; };
// add default volume, pitch and distance
if (count _sound < 2) then {_sound pushBack 1};
if (count _sound < 3) then {_sound pushBack 1};
if (count _sound < 4) then {_sound pushBack 0};
private "_position";
_position = _unit modelToWorldVisual (_unit selectionPosition "RightHand"); _position = _unit modelToWorldVisual (_unit selectionPosition "RightHand");
_position set [2, (_position select 2) + ((getPosASLW _unit select 2) - (getPosATL _unit select 2) max 0)]; _position set [2, (_position select 2) + ((getPosASLW _unit select 2) - (getPosATL _unit select 2) max 0)];
playSound3D [_sound select 0, objNull, false, _position, _sound select 1, _sound select 2, _sound select 3]; _sound params ["_filename", ["_volume", 1], ["_soundPitch", 1], ["_distance", 0]];
playSound3D [_filename, objNull, false, _position, _volume, _soundPitch, _distance];

View File

@ -1,17 +1,31 @@
// by commy2 /*
* Author: commy2
* Show firemode indicator, representing safety lock
*
* Arguments:
* 0: Show firemode <BOOL>
*
* Return Value:
* None
*
* Example:
* [true] call ace_safemode_fnc_setSafeModeVisual
*
* Public: No
*/
#include "script_component.hpp" #include "script_component.hpp"
PARAMS_1(_show); private ["_control", "_config"];
params ["_show"];
disableSerialization; disableSerialization;
private ["_control"];
_control = (uiNamespace getVariable ["ACE_dlgSoldier", displayNull]) displayCtrl 187; _control = (uiNamespace getVariable ["ACE_dlgSoldier", displayNull]) displayCtrl 187;
if (isNull _control) exitWith {}; if (isNull _control) exitWith {};
if (_show) then { if (_show) then {
private "_config";
_config = configFile >> "RscInGameUI" >> "RscUnitInfoSoldier" >> "WeaponInfoControlsGroupLeft" >> "controls" >> "CA_ModeTexture"; _config = configFile >> "RscInGameUI" >> "RscUnitInfoSoldier" >> "WeaponInfoControlsGroupLeft" >> "controls" >> "CA_ModeTexture";
_control ctrlSetPosition [getNumber (_config >> "x"), getNumber (_config >> "y"), getNumber (_config >> "w"), getNumber (_config >> "h")]; _control ctrlSetPosition [getNumber (_config >> "x"), getNumber (_config >> "y"), getNumber (_config >> "w"), getNumber (_config >> "h")];

View File

@ -1,9 +1,26 @@
// by commy2 /*
* Author: commy2
* Take weapon of safety lock.
*
* Arguments:
* 0: Unit <OBJECT>
* 1: Weapon <STRING>
* 2: Muzzle <STRING>
*
* Return Value:
* None
*
* Example:
* [ACE_player, currentWeapon ACE_player, currentMuzzle ACE_player] call ace_safemode_fnc_unlockSafety
*
* Public: No
*/
#include "script_component.hpp" #include "script_component.hpp"
PARAMS_3(_unit,_weapon,_muzzle); private ["_safedWeapons", "_id", "_picture"];
params ["_unit", "_weapon", "_muzzle"];
private ["_safedWeapons"];
_safedWeapons = _unit getVariable [QGVAR(safedWeapons), []]; _safedWeapons = _unit getVariable [QGVAR(safedWeapons), []];
if (_weapon in _safedWeapons) then { if (_weapon in _safedWeapons) then {
@ -12,7 +29,6 @@ if (_weapon in _safedWeapons) then {
_unit setVariable [QGVAR(safedWeapons), _safedWeapons]; _unit setVariable [QGVAR(safedWeapons), _safedWeapons];
if (count _safedWeapons == 0) then { if (count _safedWeapons == 0) then {
private "_id";
_id = _unit getVariable [QGVAR(actionID), -1]; _id = _unit getVariable [QGVAR(actionID), -1];
//[_unit, "DefaultAction", _id] call EFUNC(common,removeActionMenuEventHandler); //[_unit, "DefaultAction", _id] call EFUNC(common,removeActionMenuEventHandler);
@ -36,7 +52,8 @@ if (inputAction "nextWeapon" > 0) then {
if (_x == "this") then { if (_x == "this") then {
_modes pushBack _weapon; _modes pushBack _weapon;
}; };
} forEach getArray (configfile >> "CfgWeapons" >> _weapon >> "modes"); nil
} count getArray (configfile >> "CfgWeapons" >> _weapon >> "modes");
// select last mode // select last mode
_mode = _modes select (count _modes - 1); _mode = _modes select (count _modes - 1);
@ -57,6 +74,5 @@ if (inputAction "nextWeapon" > 0) then {
// player hud // player hud
[true] call FUNC(setSafeModeVisual); [true] call FUNC(setSafeModeVisual);
private "_picture";
_picture = getText (configFile >> "CfgWeapons" >> _weapon >> "picture"); _picture = getText (configFile >> "CfgWeapons" >> _weapon >> "picture");
[localize LSTRING(TookOffSafety), _picture] call EFUNC(common,displayTextPicture); [localize LSTRING(TookOffSafety), _picture] call EFUNC(common,displayTextPicture);

View File

@ -1,10 +1,11 @@
ace_sandbag ace_sandbag
=============== ===============
Stackable sandbags. Adds stackable sandbags.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)

View File

@ -1,10 +1,11 @@
ace_sitting ace_sitting
=============== ===============
The Sitting module introduces ability to sit on different chairs and toilets. The Sitting module introduces ability to sit on chairs.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Jonpas] (https://github.com/jonpas) - [Jonpas](https://github.com/jonpas)

View File

@ -3,8 +3,9 @@ ace_slideshow
Adds ability to have slide-shows on them and control them with a controller (another object). Adds ability to have slide-shows on them and control them with a controller (another object).
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Jonpas] (https://github.com/jonpas) - [Jonpas](https://github.com/jonpas)

View File

@ -3,8 +3,9 @@ ace_spottingscope
Adds a spotting scope. Adds a spotting scope.
## Maintainers ## Maintainers
The people responsible for merging changes to this component or answering potential questions. The people responsible for merging changes to this component or answering potential questions.
- [Ruthberg] (http://github.com/Ulteq) - [Ruthberg](http://github.com/Ulteq)

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