Cleanup for branch release, picked from #2366

This commit is contained in:
jonpas 2015-09-11 19:57:21 +02:00
parent bda41f2cd1
commit 3de783d3a7
6 changed files with 13 additions and 42 deletions

View File

@ -118,7 +118,7 @@ class CfgVehicles {
author = ECSTRING(common,ACETeam);
class Arguments {
class EnableList {
displayName = CSTRING(AssignEngineerRole_EnableList_DisplayName);
displayName = CSTRING(EnableList_DisplayName);
description = CSTRING(AssignEngineerRole_EnableList_Description);
defaultValue = "";
typeName = "STRING";
@ -162,7 +162,7 @@ class CfgVehicles {
author = ECSTRING(common,ACETeam);
class Arguments {
class EnableList {
displayName = CSTRING(AssignRepairVehicle_EnableList_DisplayName);
displayName = CSTRING(EnableList_DisplayName);
description = CSTRING(AssignRepairVehicle_EnableList_Description);
defaultValue = "";
typeName = "STRING";
@ -194,7 +194,7 @@ class CfgVehicles {
function = QFUNC(moduleAssignRepairFacility);
class Arguments {
class EnableList {
displayName = CSTRING(AssignRepairFacility_EnableList_DisplayName);
displayName = CSTRING(EnableList_DisplayName);
description = CSTRING(AssignRepairFacility_EnableList_Description);
defaultValue = "";
typeName = "STRING";
@ -234,7 +234,7 @@ class CfgVehicles {
author = ECSTRING(common,ACETeam);
class Arguments {
class List {
displayName = CSTRING(AddSpareParts_List_DisplayName);
displayName = CSTRING(EnableList_DisplayName);
description = CSTRING(AddSpareParts_List_Description);
defaultValue = "";
typeName = "STRING";

View File

@ -10,3 +10,4 @@ The people responsible for merging changes to this component or answering potent
- [commy2](https://github.com/commy2)
- [Glowbal](https://github.com/Glowbal)
- [Jonpas](https://github.com/jonpas)

View File

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

View File

@ -18,7 +18,7 @@
params ["_vehicle"];
TRACE_1("params", _vehicle);
private ["_type", "_initializedClasses"];
private ["_type", "_initializedClasses", "_condition", "_statement", "_action"];
_type = typeOf _vehicle;
@ -44,28 +44,25 @@ _hitPointsAddedAmount = [];
if (_x in _wheelHitPoints) then {
// add wheel repair action
private ["_icon", "_selection"];
private ["_icon", "_selection", "_name", "_text"];
_icon = QUOTE(PATHTOF(ui\tire_ca.paa));
_icon = "A3\ui_f\data\igui\cfg\actions\repair_ca.paa";
// textDefault = "<img image='\A3\ui_f\data\igui\cfg\actions\repair_ca.paa' size='1.8' shadow=2 />";
_selection = _wheelHitPointSelections select (_wheelHitPoints find _x);
private ["_name", "_text", "_condition", "_statement"];
// remove wheel action
_name = format ["Remove_%1", _x];
_name = format ["Remove_%1", _x];
_text = localize LSTRING(RemoveWheel);
_condition = {[_this select 1, _this select 0, _this select 2 select 0, "RemoveWheel"] call DFUNC(canRepair)};
_statement = {[_this select 1, _this select 0, _this select 2 select 0, "RemoveWheel"] call DFUNC(repair)};
private "_action";
_action = [_name, _text, _icon, _statement, _condition, {}, [_x], _selection, 2] call EFUNC(interact_menu,createAction);
[_type, 0, [], _action] call EFUNC(interact_menu,addActionToClass);
// replace wheel action
_name = format ["Replace_%1", _x];
_name = format ["Replace_%1", _x];
_text = localize LSTRING(ReplaceWheel);
_condition = {[_this select 1, _this select 0, _this select 2 select 0, "ReplaceWheel"] call DFUNC(canRepair)};
@ -102,7 +99,7 @@ _hitPointsAddedAmount = [];
if (isText (configFile >> "CfgVehicles" >> _type >> "HitPoints" >> _x >> "depends")) exitWith {};
// add misc repair action
private ["_name", "_icon", "_selection", "_condition", "_statement"];
private ["_name", "_icon", "_selection", "_customSelectionsConfig"];
_name = format ["Repair_%1", _x];
@ -150,11 +147,9 @@ _hitPointsAddedAmount = [];
} else {
_selection = [1.75, 0, -1.75];
};
private "_action";
_action = [_name, _text, _icon, _statement, _condition, {}, [_x, "RepairTrack"], _selection, 4] call EFUNC(interact_menu,createAction);
[_type, 0, [], _action] call EFUNC(interact_menu,addActionToClass);
} else {
private "_action";
_action = [_name, _text, _icon, _statement, _condition, {}, [_x, "MiscRepair"], _selection, 4] call EFUNC(interact_menu,createAction);
// Put inside main actions if no other position was found above
if (_selection isEqualTo [0, 0, 0]) then {
@ -166,8 +161,6 @@ _hitPointsAddedAmount = [];
};
} forEach _hitPoints;
private ["_action", "_condition", "_statement"];
_condition = {[_this select 1, _this select 0, _this select 2 select 0, _this select 2 select 1] call DFUNC(canRepair)};
_statement = {[_this select 1, _this select 0, _this select 2 select 0, _this select 2 select 1] call DFUNC(repair)};
_action = [QGVAR(fullRepair), localize LSTRING(fullRepair), "A3\ui_f\data\igui\cfg\actions\repair_ca.paa", _statement, _condition, {}, ["", "fullRepair"], "", 4] call EFUNC(interact_menu,createAction);

View File

@ -47,8 +47,4 @@ _return = false;
};
} forEach _hitpointGroup;
if (typeOf _target == "B_MRAP_01_F") then {
diag_log format ["%1 - %2", _hitPoint, _hitpointGroup];
};
_return

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Project name="ACE">
<Package name="repair">
<Key ID="STR_ACE_Repair_SpareTrack">
@ -735,7 +735,7 @@
<Russian>Назначить инженером</Russian>
<Czech>Přiřadit Inženýra</Czech>
</Key>
<Key ID="STR_ACE_Repair_AssignEngineerRole_EnableList_DisplayName">
<Key ID="STR_ACE_Repair_EnableList_DisplayName">
<English>List</English>
<Polish>Lista</Polish>
<Portuguese>Lista</Portuguese>
@ -793,13 +793,6 @@
<Portuguese>Defina veículo de reparo</Portuguese>
<Russian>Назначить ремонтный транспорт</Russian>
</Key>
<Key ID="STR_ACE_Repair_AssignRepairVehicle_EnableList_DisplayName">
<English>List</English>
<Polish>Lista</Polish>
<Portuguese>Lista</Portuguese>
<Russian>Список</Russian>
<Czech>Seznam</Czech>
</Key>
<Key ID="STR_ACE_Repair_AssignRepairVehicle_EnableList_Description">
<English>List of vehicles that will be classified as repair vehicle, separated by commas.</English>
<Polish>Lista nazw pojazdów, które są sklasyfikowane jako pojazdy naprawcze, oddzielone przecinkami.</Polish>
@ -830,13 +823,6 @@
<Portuguese>Definir instalação de reparo</Portuguese>
<Russian>Назначить ремонтное сооружение</Russian>
</Key>
<Key ID="STR_ACE_Repair_AssignRepairFacility_EnableList_DisplayName">
<English>List</English>
<Polish>Lista</Polish>
<Portuguese>Lista</Portuguese>
<Russian>Список</Russian>
<Czech>Seznam</Czech>
</Key>
<Key ID="STR_ACE_Repair_AssignRepairFacility_EnableList_Description">
<English>List of objects that will be classified as repair Facility, separated by commas.</English>
<Polish>Lista nazw budynków, które są sklasyfikowane jako budynki naprawcze, oddzielone przecinkami.</Polish>
@ -871,11 +857,6 @@
<Polish>Dodaj części zamienne do jednego lub wielu obiektów.</Polish>
<Portuguese>Adicionar partes sobressalentes para um ou mais objetos</Portuguese>
</Key>
<Key ID="STR_ACE_Repair_AddSpareParts_List_DisplayName">
<English>List</English>
<Polish>Lista</Polish>
<Portuguese>Lista</Portuguese>
</Key>
<Key ID="STR_ACE_Repair_AddSpareParts_List_Description">
<English>List of objects that will get spare parts added, separated by commas.</English>
<Polish>Lista obiektów, które otrzymają części zamienne, oddzielone przecinkiem.</Polish>