mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Merge pull request #2053 from acemod/require-surrender-captive
Require surrender before arresting a unit
This commit is contained in:
commit
02fdbe6fc2
@ -5,6 +5,13 @@ class ACE_Settings {
|
||||
typeName = "BOOL";
|
||||
value = 1;
|
||||
};
|
||||
class GVAR(requireSurrender) {
|
||||
displayName = CSTRING(ModuleSettings_requireSurrender_name);
|
||||
description = CSTRING(ModuleSettings_requireSurrender_description);
|
||||
typeName = "SCALAR";
|
||||
values[] = {ECSTRING(common,Disabled), CSTRING(SurrenderOnly), CSTRING(SurrenderOrNoWeapon)};
|
||||
value = 1;
|
||||
};
|
||||
class GVAR(allowSurrender) {
|
||||
displayName = CSTRING(ModuleSettings_allowSurrender_name);
|
||||
description = CSTRING(ModuleSettings_allowSurrender_description);
|
||||
|
@ -189,6 +189,26 @@ class CfgVehicles {
|
||||
typeName = "BOOL";
|
||||
defaultValue = 1;
|
||||
};
|
||||
class requireSurrender {
|
||||
displayName = CSTRING(ModuleSettings_allowSurrender_name);
|
||||
description = CSTRING(ModuleSettings_allowSurrender_description);
|
||||
typeName = "NUMBER";
|
||||
class values {
|
||||
class disable {
|
||||
name = ECSTRING(common,No);
|
||||
value = 0;
|
||||
};
|
||||
class Surrender {
|
||||
name = CSTRING(SurrenderOnly);
|
||||
value = 1;
|
||||
default = 1;
|
||||
};
|
||||
class SurrenderOrNoWeapon {
|
||||
name = CSTRING(SurrenderOrNoWeapon);
|
||||
value = 2;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
class ModuleDescription: ModuleDescription {
|
||||
description = CSTRING(ModuleSettings_Description);
|
||||
|
@ -22,4 +22,5 @@ params ["_unit", "_target"];
|
||||
(GVAR(allowHandcuffOwnSide) || {(side _unit) != (side _target)}) &&
|
||||
("ACE_CableTie" in (items _unit)) &&
|
||||
{alive _target} &&
|
||||
{!(_target getVariable [QGVAR(isHandcuffed), false])}
|
||||
{!(_target getVariable [QGVAR(isHandcuffed), false])} &&
|
||||
(GVAR(requireSurrender) == 0 || ((_target getVariable [QGVAR(isSurrendering), false]) || (currentWeapon _target == "" && GVAR(requireSurrender) == 2)))
|
||||
|
@ -17,3 +17,4 @@ params ["_logic"];
|
||||
|
||||
[_logic, QGVAR(allowHandcuffOwnSide), "allowHandcuffOwnSide"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(allowSurrender), "allowSurrender"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(requireSurrender), "requireSurrender"] call EFUNC(common,readSettingFromModule);
|
||||
|
@ -221,5 +221,17 @@
|
||||
<German>Spieler können kapitulieren, nachdem sie ihre Waffe geholstert haben</German>
|
||||
<Portuguese>Jogadores podem se render depois de guardar sua arma</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Captives_ModuleSettings_requireSurrender_name">
|
||||
<English>Require surrendering</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Captives_ModuleSettings_requireSurrender_description">
|
||||
<English>Require Players to surrender before they can be arrested</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Captives_SurrenderOnly">
|
||||
<English>Surrendering only</English>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Captives_SurrenderOrNoWeapon">
|
||||
<English>Surrendering or No weapon</English>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
||||
|
Loading…
Reference in New Issue
Block a user