Skip to content

Commit

Permalink
Rewrite rectify convert option (#6825)
Browse files Browse the repository at this point in the history
* Rewrite Rectify - Adding option to convert vanilla medical gear

* Oops
  • Loading branch information
TheMagnetar authored Mar 17, 2019
1 parent 54208a1 commit 99f5d2e
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 0 deletions.
8 changes: 8 additions & 0 deletions addons/medical_treatment/ACE_Settings.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,4 +135,12 @@ class ACE_Settings {
value = 0;
values[] = {"No", "Yes"};
};
class GVAR(convertItems) {
category = CSTRING(Category_Medical);
displayName = CSTRING(convertItems_DisplayName);
description = CSTRING(convertItems_Description);
typeName = "SCALAR";
value = 0;
values[] = {ECSTRING(common,Enabled), CSTRING(convertItems_remove), ECSTRING(common,Disabled)};
};
};
2 changes: 2 additions & 0 deletions addons/medical_treatment/functions/fnc_checkItems.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ _unit removeItems "FirstAidKit";
private _countMedikit = [_unit, "Medikit"] call EFUNC(common,getCountOfItem);
_unit removeItems "Medikit";

if (GVAR(convertItems) != 0) exitWith {};

for "_i" from 1 to _countFirstAidKit do {
_unit addItem "ACE_fieldDressing";
_unit addItem "ACE_packingBandage";
Expand Down
9 changes: 9 additions & 0 deletions addons/medical_treatment/stringtable.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3484,5 +3484,14 @@
<Chinesesimp>移除军用止血带中...</Chinesesimp>
<Chinese>移除軍用止血帶中...</Chinese>
</Key>
<Key ID="STR_ACE_Medical_treatment_convertItems_DisplayName">
<English>Convert vanilla items</English>
</Key>
<Key ID="STR_ACE_Medical_treatment_convertItems_Description">
<English>Enables or disables whether vanilla medical items are converted to ACE medical items or just removed</English>
</Key>
<Key ID="STR_ACE_Medical_treatment_convertItems_remove">
<English>Just remove vanilla medical</English>
</Key>
</Package>
</Project>

0 comments on commit 99f5d2e

Please sign in to comment.