mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
More work
This commit is contained in:
parent
4c727fbff5
commit
24ab11a1e2
@ -1,90 +1,90 @@
|
|||||||
class CfgMovesBasic {
|
class CfgMovesBasic {
|
||||||
class Actions {
|
class Actions {
|
||||||
class CivilStandActions;
|
class CivilStandActions;
|
||||||
class ACE_CivilStandCaptiveActions: CivilStandActions {
|
class ACE_CivilStandCaptiveActions: CivilStandActions {
|
||||||
turnL = "";
|
turnL = "";
|
||||||
turnR = "";
|
turnR = "";
|
||||||
stop = "ACE_AmovPercMstpScapWnonDnon";
|
stop = "ACE_AmovPercMstpScapWnonDnon";
|
||||||
StopRelaxed = "ACE_AmovPercMstpScapWnonDnon";
|
StopRelaxed = "ACE_AmovPercMstpScapWnonDnon";
|
||||||
default = "ACE_AmovPercMstpScapWnonDnon";
|
default = "ACE_AmovPercMstpScapWnonDnon";
|
||||||
getOver = "";
|
getOver = "";
|
||||||
throwPrepare = "";
|
throwPrepare = "";
|
||||||
throwGrenade[] = {"","Gesture"};
|
throwGrenade[] = {"","Gesture"};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
class CfgMovesMaleSdr: CfgMovesBasic {
|
class CfgMovesMaleSdr: CfgMovesBasic {
|
||||||
class StandBase;
|
class StandBase;
|
||||||
class States {
|
class States {
|
||||||
class AmovPercMstpSnonWnonDnon: StandBase {
|
class AmovPercMstpSnonWnonDnon: StandBase {
|
||||||
ConnectTo[] += {"ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon",0.1};
|
ConnectTo[] += {"ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon",0.1};
|
||||||
};
|
};
|
||||||
|
|
||||||
class CutSceneAnimationBase;
|
class CutSceneAnimationBase;
|
||||||
class ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon: CutSceneAnimationBase {
|
class ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon: CutSceneAnimationBase {
|
||||||
actions = "ACE_CivilStandCaptiveActions";
|
actions = "ACE_CivilStandCaptiveActions";
|
||||||
file = "\A3\anims_f\Data\Anim\Sdr\mov\erc\stp\non\non\AmovPercMstpSnonWnonDnon_EaseIn";
|
file = "\A3\anims_f\Data\Anim\Sdr\mov\erc\stp\non\non\AmovPercMstpSnonWnonDnon_EaseIn";
|
||||||
speed = 1;
|
speed = 1;
|
||||||
looped = 0;
|
looped = 0;
|
||||||
interpolationRestart = 2;
|
interpolationRestart = 2;
|
||||||
ConnectTo[] = {"ACE_AmovPercMstpScapWnonDnon",0.1};
|
ConnectTo[] = {"ACE_AmovPercMstpScapWnonDnon",0.1};
|
||||||
InterpolateTo[] = {"Unconscious",0.01,"ACE_AmovPercMstpScapWnonDnon_AmovPercMstpSnonWnonDnon",0.1};
|
InterpolateTo[] = {"Unconscious",0.01,"ACE_AmovPercMstpScapWnonDnon_AmovPercMstpSnonWnonDnon",0.1};
|
||||||
};
|
};
|
||||||
|
|
||||||
class ACE_AmovPercMstpScapWnonDnon: ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon {
|
class ACE_AmovPercMstpScapWnonDnon: ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon {
|
||||||
file = "\A3\anims_f\Data\Anim\Sdr\mov\erc\stp\non\non\AmovPercMstpSnonWnonDnon_Ease";
|
file = "\A3\anims_f\Data\Anim\Sdr\mov\erc\stp\non\non\AmovPercMstpSnonWnonDnon_Ease";
|
||||||
speed = 0;
|
speed = 0;
|
||||||
ConnectTo[] = {"ACE_AmovPercMstpScapWnonDnon_AmovPercMstpSnonWnonDnon",0.1};
|
ConnectTo[] = {"ACE_AmovPercMstpScapWnonDnon_AmovPercMstpSnonWnonDnon",0.1};
|
||||||
InterpolateTo[] = {"Unconscious",0.01};
|
InterpolateTo[] = {"Unconscious",0.01};
|
||||||
looped = 1;
|
looped = 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
class ACE_AmovPercMstpScapWnonDnon_AmovPercMstpSnonWnonDnon: ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon {
|
class ACE_AmovPercMstpScapWnonDnon_AmovPercMstpSnonWnonDnon: ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon {
|
||||||
actions = "CivilStandActions";
|
actions = "CivilStandActions";
|
||||||
file = "\A3\anims_f\Data\Anim\Sdr\mov\erc\stp\non\non\amovpercmstpsnonwnondnon_easeout";
|
file = "\A3\anims_f\Data\Anim\Sdr\mov\erc\stp\non\non\amovpercmstpsnonwnondnon_easeout";
|
||||||
ConnectTo[] = {"AmovPercMstpSnonWnonDnon",0.1};
|
ConnectTo[] = {"AmovPercMstpSnonWnonDnon",0.1};
|
||||||
InterpolateTo[] = {"Unconscious",0.01,"ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon",0.1};
|
InterpolateTo[] = {"Unconscious",0.01,"ACE_AmovPercMstpSnonWnonDnon_AmovPercMstpScapWnonDnon",0.1};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
player playMove "ACE_AmovPercMstpScapWnonDnon";
|
player playMove "ACE_AmovPercMstpScapWnonDnon";
|
||||||
player switchMove "ACE_AmovPercMstpScapWnonDnon_AmovPercMstpSnonWnonDnon";
|
player switchMove "ACE_AmovPercMstpScapWnonDnon_AmovPercMstpSnonWnonDnon";
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*class CfgMovesBasic;
|
/*class CfgMovesBasic;
|
||||||
class CfgMovesMaleSdr: CfgMovesBasic {
|
class CfgMovesMaleSdr: CfgMovesBasic {
|
||||||
class States {
|
class States {
|
||||||
class CutSceneAnimationBase;
|
class CutSceneAnimationBase;
|
||||||
class AmovPercMstpSnonWnonDnon_EaseIn: CutSceneAnimationBase {
|
class AmovPercMstpSnonWnonDnon_EaseIn: CutSceneAnimationBase {
|
||||||
head = "headDefault";
|
head = "headDefault";
|
||||||
static = 1;
|
static = 1;
|
||||||
disableWeapons = 0;
|
disableWeapons = 0;
|
||||||
forceAim = 0;
|
forceAim = 0;
|
||||||
InterpolateTo[] = {"AmovPercMstpSnonWnonDnon_EaseOut",0.02,"Unconscious",0.1};
|
InterpolateTo[] = {"AmovPercMstpSnonWnonDnon_EaseOut",0.02,"Unconscious",0.1};
|
||||||
};
|
};
|
||||||
class AmovPercMstpSnonWnonDnon_Ease: AmovPercMstpSnonWnonDnon_EaseIn {
|
class AmovPercMstpSnonWnonDnon_Ease: AmovPercMstpSnonWnonDnon_EaseIn {
|
||||||
looped = 1;
|
looped = 1;
|
||||||
InterpolateTo[] = {"Unconscious",0.1};
|
InterpolateTo[] = {"Unconscious",0.1};
|
||||||
};
|
};
|
||||||
class AmovPercMstpSnonWnonDnon_EaseOut: AmovPercMstpSnonWnonDnon_EaseIn {
|
class AmovPercMstpSnonWnonDnon_EaseOut: AmovPercMstpSnonWnonDnon_EaseIn {
|
||||||
InterpolateTo[] = {"AmovPercMstpSnonWnonDnon_EaseIn",0.02,"Unconscious",0.1};
|
InterpolateTo[] = {"AmovPercMstpSnonWnonDnon_EaseIn",0.02,"Unconscious",0.1};
|
||||||
};
|
};
|
||||||
|
|
||||||
class AmovPercMstpSnonWnonDnon_AmovPercMstpSsurWnonDnon: CutSceneAnimationBase {
|
class AmovPercMstpSnonWnonDnon_AmovPercMstpSsurWnonDnon: CutSceneAnimationBase {
|
||||||
InterpolateTo[] = {"Unconscious",0.01,"AmovPercMstpSsurWnonDnon_AmovPercMstpSnonWnonDnon",0.1};
|
InterpolateTo[] = {"Unconscious",0.01,"AmovPercMstpSsurWnonDnon_AmovPercMstpSnonWnonDnon",0.1};
|
||||||
};
|
};
|
||||||
|
|
||||||
class AmovPercMstpSsurWnonDnon: AmovPercMstpSnonWnonDnon_AmovPercMstpSsurWnonDnon {
|
class AmovPercMstpSsurWnonDnon: AmovPercMstpSnonWnonDnon_AmovPercMstpSsurWnonDnon {
|
||||||
looped = 1;
|
looped = 1;
|
||||||
InterpolateTo[] = {"Unconscious",0.01};
|
InterpolateTo[] = {"Unconscious",0.01};
|
||||||
};
|
};
|
||||||
|
|
||||||
class AmovPercMstpSsurWnonDnon_AmovPercMstpSnonWnonDnon: AmovPercMstpSnonWnonDnon_AmovPercMstpSsurWnonDnon {
|
class AmovPercMstpSsurWnonDnon_AmovPercMstpSnonWnonDnon: AmovPercMstpSnonWnonDnon_AmovPercMstpSsurWnonDnon {
|
||||||
InterpolateTo[] = {"Unconscious",0.01,"AmovPercMstpSnonWnonDnon_AmovPercMstpSsurWnonDnon",0.1};
|
InterpolateTo[] = {"Unconscious",0.01,"AmovPercMstpSnonWnonDnon_AmovPercMstpSsurWnonDnon",0.1};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};*/
|
};*/
|
||||||
|
|
||||||
|
@ -5,8 +5,8 @@ class CfgVehicles {
|
|||||||
class ACE_SetCaptive {
|
class ACE_SetCaptive {
|
||||||
displayName = "$STR_ACE_Captives_SetCaptive";
|
displayName = "$STR_ACE_Captives_SetCaptive";
|
||||||
distance = 4;
|
distance = 4;
|
||||||
condition = QUOTE(('ACE_CableTie' in (items _player)) && {alive _target} && {!(_target getVariable ['ACE_isCaptive', false])});
|
condition = QUOTE(('ACE_CableTie' in (items _player)) && {alive _target} && {!(_target getVariable [ARR_2('ACE_isCaptive', false)])});
|
||||||
statement = QUOTE(_player removeItem 'ACE_CableTie'; [ARR_3(QGVAR(SetCaptive), [_target], [ARR_2(_target, true)])] call EFUNC(common,targetEvent););
|
statement = QUOTE(_player removeItem 'ACE_CableTie'; [ARR_3('SetCaptive', [_target], [ARR_2(_target, true)])] call EFUNC(common,targetEvent););
|
||||||
showDisabled = 0;
|
showDisabled = 0;
|
||||||
priority = 2.4;
|
priority = 2.4;
|
||||||
icon = QUOTE(PATHTOF(UI\handcuff_ca.paa));
|
icon = QUOTE(PATHTOF(UI\handcuff_ca.paa));
|
||||||
@ -15,8 +15,8 @@ class CfgVehicles {
|
|||||||
class ACE_ReleaseCaptive {
|
class ACE_ReleaseCaptive {
|
||||||
displayName = "$STR_ACE_Captives_ReleaseCaptive";
|
displayName = "$STR_ACE_Captives_ReleaseCaptive";
|
||||||
distance = 4;
|
distance = 4;
|
||||||
condition = QUOTE(_target getVariable ['ACE_isCaptive', false] && {isNull (attachedTo _target)});
|
condition = QUOTE(_target getVariable [ARR_2('ACE_isCaptive', false)] && {isNull (attachedTo _target)});
|
||||||
statement = QUOTE([ARR_2(_target, false)] call FUNC(setCaptive));
|
statement = QUOTE([ARR_3('SetCaptive', [_target], [ARR_2(_target, false)])] call EFUNC(common,targetEvent););
|
||||||
exceptions[] = {"ACE_Interaction_isNotEscorting"};
|
exceptions[] = {"ACE_Interaction_isNotEscorting"};
|
||||||
showDisabled = 0;
|
showDisabled = 0;
|
||||||
priority = 2.4;
|
priority = 2.4;
|
||||||
@ -26,7 +26,7 @@ class CfgVehicles {
|
|||||||
class ACE_EscortCaptive {
|
class ACE_EscortCaptive {
|
||||||
displayName = "$STR_ACE_Captives_EscortCaptive";
|
displayName = "$STR_ACE_Captives_EscortCaptive";
|
||||||
distance = 4;
|
distance = 4;
|
||||||
condition = QUOTE((_target getVariable ['ACE_isCaptive', false]) && {isNull (attachedTo _target)} && {alive _target} && {!(_target getVariable ['ACE_isUnconscious', false])});
|
condition = QUOTE((_target getVariable [ARR_2('ACE_isCaptive', false)]) && {isNull (attachedTo _target)} && {alive _target} && {!(_target getVariable [ARR_2('ACE_isUnconscious', false)])});
|
||||||
statement = QUOTE([ARR_2(_target, true)] call FUNC(escortCaptive));
|
statement = QUOTE([ARR_2(_target, true)] call FUNC(escortCaptive));
|
||||||
exceptions[] = {"ACE_Interaction_isNotEscorting"};
|
exceptions[] = {"ACE_Interaction_isNotEscorting"};
|
||||||
showDisabled = 0;
|
showDisabled = 0;
|
||||||
@ -37,7 +37,7 @@ class CfgVehicles {
|
|||||||
class ACE_StopEscorting {
|
class ACE_StopEscorting {
|
||||||
displayName = "$STR_ACE_Captives_StopEscorting";
|
displayName = "$STR_ACE_Captives_StopEscorting";
|
||||||
distance = 4;
|
distance = 4;
|
||||||
condition = QUOTE((_target getVariable ['ACE_isCaptive', false]) && {_target in (attachedObjects _player)});
|
condition = QUOTE((_target getVariable [ARR_2('ACE_isCaptive', false)]) && {_target in (attachedObjects _player)});
|
||||||
statement = QUOTE([ARR_2(_target, false)] call FUNC(escortCaptive));
|
statement = QUOTE([ARR_2(_target, false)] call FUNC(escortCaptive));
|
||||||
exceptions[] = {"ACE_Interaction_isNotEscorting"};
|
exceptions[] = {"ACE_Interaction_isNotEscorting"};
|
||||||
showDisabled = 0;
|
showDisabled = 0;
|
||||||
@ -71,8 +71,8 @@ class CfgVehicles {
|
|||||||
class ACE_SelfActions {
|
class ACE_SelfActions {
|
||||||
class ACE_StopEscortingSelf {
|
class ACE_StopEscortingSelf {
|
||||||
displayName = "$STR_ACE_Captives_StopEscorting";
|
displayName = "$STR_ACE_Captives_StopEscorting";
|
||||||
condition = QUOTE(((_player getVariable ['ACE_escortedUnit', objNull]) getVariable ['ACE_isCaptive', false]) && {(_player getVariable ['ACE_escortedUnit', objNull]) in attachedObjects _player});
|
condition = QUOTE(((_player getVariable [ARR_2('ACE_escortedUnit', objNull)]) getVariable ['ACE_isCaptive', false]) && {(_player getVariable [ARR_2('ACE_escortedUnit', objNull)]) in attachedObjects _player});
|
||||||
statement = QUOTE([ARR_2((_player getVariable ['ACE_escortedUnit', objNull]), false)] call FUNC(_escortCaptive););
|
statement = QUOTE([ARR_2((_player getVariable [ARR_2('ACE_escortedUnit', objNull)]), false)] call FUNC(_escortCaptive););
|
||||||
exceptions[] = {"ACE_Interaction_isNotEscorting"};
|
exceptions[] = {"ACE_Interaction_isNotEscorting"};
|
||||||
showDisabled = 0;
|
showDisabled = 0;
|
||||||
priority = 2.3;
|
priority = 2.3;
|
||||||
|
@ -1,15 +1,15 @@
|
|||||||
class CfgWeapons {
|
class CfgWeapons {
|
||||||
class ACE_ItemCore;
|
class ACE_ItemCore;
|
||||||
class InventoryItem_Base_F;
|
class InventoryItem_Base_F;
|
||||||
|
|
||||||
class ACE_CableTie: ACE_ItemCore {
|
class ACE_CableTie: ACE_ItemCore {
|
||||||
displayName = "$STR_ACE_Captives_CableTie";
|
displayName = "$STR_ACE_Captives_CableTie";
|
||||||
descriptionShort = "$STR_ACE_Captives_CableTieDescription";
|
descriptionShort = "$STR_ACE_Captives_CableTieDescription";
|
||||||
model = QUOTE(PATHTOF(models\ace_cabletie.p3d));
|
model = QUOTE(PATHTOF(models\ace_cabletie.p3d));
|
||||||
picture = QUOTE(PATHTOF(UI\ace_cabletie_ca.paa));
|
picture = QUOTE(PATHTOF(UI\ace_cabletie_ca.paa));
|
||||||
scope = 2;
|
scope = 2;
|
||||||
class ItemInfo: InventoryItem_Base_F {
|
class ItemInfo: InventoryItem_Base_F {
|
||||||
mass = 1;
|
mass = 1;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
14
addons/captives/README.md
Normal file
14
addons/captives/README.md
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
ace_captives
|
||||||
|
============
|
||||||
|
|
||||||
|
Allows taking people captive/handcuffed
|
||||||
|
|
||||||
|
####Items:
|
||||||
|
`ACE_CableTie` - adds ability to take someone captive
|
||||||
|
|
||||||
|
|
||||||
|
## Maintainers
|
||||||
|
|
||||||
|
The people responsible for merging changes to this component or answering potential questions.
|
||||||
|
|
||||||
|
- [PabstMirror](https://github.com/PabstMirror)
|
@ -1,9 +1,19 @@
|
|||||||
// by commy2
|
#include "script_component.hpp"
|
||||||
|
|
||||||
[missionNamespace, "playerChanged", {_this call ACE_Captives_fnc_handlePlayerChanged}] call ACE_Core_fnc_addCustomEventhandler;
|
[missionNamespace, "playerChanged", {_this call ACE_Captives_fnc_handlePlayerChanged}] call ACE_Core_fnc_addCustomEventhandler;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
[QGVAR(MoveIn), {_this call FUNC(vehicleCaptiveMoveIn)}] call EFUNC(common,addEventHandler);
|
["MoveInCaptive", {_this call FUNC(vehicleCaptiveMoveIn)}] call EFUNC(common,addEventHandler);
|
||||||
[QGVAR(MoveOut), {_this call FUNC(vehicleCaptiveMoveOut)}] call EFUNC(common,addEventHandler);
|
["MoveOutCaptive", {_this call FUNC(vehicleCaptiveMoveOut)}] call EFUNC(common,addEventHandler);
|
||||||
[QGVAR(SetCaptive), {_this call FUNC(vehicleCaptiveMoveOut)}] call EFUNC(common,addEventHandler);
|
["SetCaptive", {_this call FUNC(vehicleCaptiveMoveOut)}] call EFUNC(common,addEventHandler);
|
||||||
|
|
||||||
|
//TODO: Medical Integration Events???
|
||||||
|
|
||||||
|
// [_unit, "knockedOut", {
|
||||||
|
// if (local (_this select 0)) then {_this call ACE_Captives_fnc_handleKnockedOut};
|
||||||
|
// }] call ACE_Core_fnc_addCustomEventhandler;
|
||||||
|
|
||||||
|
// [_unit, "wokeUp", {
|
||||||
|
// if (local (_this select 0)) then {_this call ACE_Captives_fnc_handleWokeUp};
|
||||||
|
// }] call ACE_Core_fnc_addCustomEventhandler;
|
||||||
|
@ -17,5 +17,7 @@ PREP(openFriskMenu);
|
|||||||
PREP(setCaptive);
|
PREP(setCaptive);
|
||||||
PREP(surrender);
|
PREP(surrender);
|
||||||
PREP(unloadCaptive);
|
PREP(unloadCaptive);
|
||||||
|
PREP(vehicleCaptiveMoveIn);
|
||||||
|
PREP(vehicleCaptiveMoveOut);
|
||||||
|
|
||||||
ADDON = true;
|
ADDON = true;
|
||||||
|
@ -19,7 +19,7 @@
|
|||||||
PARAMS_2(_unit,_oldUnit);
|
PARAMS_2(_unit,_oldUnit);
|
||||||
|
|
||||||
if (_unit getVariable ["ACE_isCaptive", false]) then {
|
if (_unit getVariable ["ACE_isCaptive", false]) then {
|
||||||
showHUD false;
|
showHUD false;
|
||||||
} else {
|
} else {
|
||||||
showHUD true;
|
showHUD true;
|
||||||
};
|
};
|
||||||
|
@ -18,6 +18,6 @@
|
|||||||
PARAMS_1(_unit);
|
PARAMS_1(_unit);
|
||||||
|
|
||||||
if (_unit getVariable ["ACE_isCaptive", false] && {vehicle _unit == _unit}) then {
|
if (_unit getVariable ["ACE_isCaptive", false] && {vehicle _unit == _unit}) then {
|
||||||
[_unit] call EFUNC(common,fixLoweredRifleAnimation);
|
[_unit] call EFUNC(common,fixLoweredRifleAnimation);
|
||||||
[_unit, "ACE_AmovPercMstpScapWnonDnon", 0] call EFUNC(common,doAnimation);
|
[_unit, "ACE_AmovPercMstpScapWnonDnon", 0] call EFUNC(common,doAnimation);
|
||||||
};
|
};
|
||||||
|
@ -19,6 +19,6 @@ PARAMS_1(_unit);
|
|||||||
|
|
||||||
// reset status on mission start
|
// reset status on mission start
|
||||||
if (_unit getVariable ["ACE_isCaptive", false]) then {
|
if (_unit getVariable ["ACE_isCaptive", false]) then {
|
||||||
_unit setVariable ["ACE_isCaptive", false];
|
_unit setVariable ["ACE_isCaptive", false];
|
||||||
[_unit, true] call ACE_Captives_fnc_setCaptive;
|
[_unit, true] call ACE_Captives_fnc_setCaptive;
|
||||||
};
|
};
|
||||||
|
@ -17,13 +17,6 @@
|
|||||||
|
|
||||||
PARAMS_1(_unit);
|
PARAMS_1(_unit);
|
||||||
|
|
||||||
[_unit, "knockedOut", {
|
|
||||||
if (local (_this select 0)) then {_this call ACE_Captives_fnc_handleKnockedOut};
|
|
||||||
}] call ACE_Core_fnc_addCustomEventhandler;
|
|
||||||
|
|
||||||
[_unit, "wokeUp", {
|
|
||||||
if (local (_this select 0)) then {_this call ACE_Captives_fnc_handleWokeUp};
|
|
||||||
}] call ACE_Core_fnc_addCustomEventhandler;
|
|
||||||
|
|
||||||
// prevent players from throwing grenades
|
// prevent players from throwing grenades
|
||||||
[_unit, "Throw", {(_this select 1) getVariable ["ACE_isCaptive", false]}, {}] call ACE_Core_fnc_addActionEventhandler;
|
[_unit, "Throw", {(_this select 1) getVariable ["ACE_isCaptive", false]}, {}] call EFUNC(common,addActionEventhandler);
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
*/
|
*/
|
||||||
#include "script_component.hpp"
|
#include "script_component.hpp"
|
||||||
|
|
||||||
PARAMS_1(_unit,_target,_vehicle);
|
PARAMS_3(_unit,_target,_vehicle);
|
||||||
|
|
||||||
if (isNull _target) then {
|
if (isNull _target) then {
|
||||||
_objects = attachedObjects _unit;
|
_objects = attachedObjects _unit;
|
||||||
@ -32,5 +32,5 @@ if (isNull _vehicle) then {
|
|||||||
|
|
||||||
if ((!isNil "_target") && {!isNil "_vehicle"}) then {
|
if ((!isNil "_target") && {!isNil "_vehicle"}) then {
|
||||||
_unit setVariable ["ACE_isEscorting", false];
|
_unit setVariable ["ACE_isEscorting", false];
|
||||||
[QGVAR(MoveIn), [_target], [_target, _vehicle]] call EFUNC(common,targetEvent);
|
["MoveInCaptive", [_target], [_target, _vehicle]] call EFUNC(common,targetEvent);
|
||||||
};
|
};
|
||||||
|
@ -22,7 +22,7 @@ PARAMS_2(_player,_unit);
|
|||||||
|
|
||||||
_weapon = currentWeapon _player;
|
_weapon = currentWeapon _player;
|
||||||
if (_weapon == primaryWeapon _player && {_weapon != ""}) then {
|
if (_weapon == primaryWeapon _player && {_weapon != ""}) then {
|
||||||
[_player, "AmovPercMstpSlowWrflDnon", 0] call EFUNC(common,doAnimation);
|
[_player, "AmovPercMstpSlowWrflDnon", 0] call EFUNC(common,doAnimation);
|
||||||
};
|
};
|
||||||
|
|
||||||
_listedItemClasses = [];
|
_listedItemClasses = [];
|
||||||
@ -32,19 +32,19 @@ _actions = [localize "STR_ACE_Captives_FriskMenuHeader", localize "STR_ACE_Capti
|
|||||||
_allGear = [];
|
_allGear = [];
|
||||||
|
|
||||||
if ((handgunWeapon _unit) != "") then {
|
if ((handgunWeapon _unit) != "") then {
|
||||||
_allGear pushBack (handgunWeapon _unit);
|
_allGear pushBack (handgunWeapon _unit);
|
||||||
};
|
};
|
||||||
if (count (uniformItems _unit) > 0) then {
|
if (count (uniformItems _unit) > 0) then {
|
||||||
_allGear = _allGear + (uniformItems _unit);
|
_allGear = _allGear + (uniformItems _unit);
|
||||||
};
|
};
|
||||||
if (count (vestItems _unit) > 0) then {
|
if (count (vestItems _unit) > 0) then {
|
||||||
_allGear = _allGear + (vestItems _unit);
|
_allGear = _allGear + (vestItems _unit);
|
||||||
};
|
};
|
||||||
if (count (backpackItems _unit) > 0) then {
|
if (count (backpackItems _unit) > 0) then {
|
||||||
_allGear = _allGear + (backpackItems _unit);
|
_allGear = _allGear + (backpackItems _unit);
|
||||||
};
|
};
|
||||||
if (count (assignedItems _unit) > 0) then {
|
if (count (assignedItems _unit) > 0) then {
|
||||||
_allGear = _allGear + (assignedItems _unit);
|
_allGear = _allGear + (assignedItems _unit);
|
||||||
};
|
};
|
||||||
|
|
||||||
// Handgun
|
// Handgun
|
||||||
@ -53,15 +53,15 @@ if (count (assignedItems _unit) > 0) then {
|
|||||||
// Backpack Items
|
// Backpack Items
|
||||||
// Assigned Items
|
// Assigned Items
|
||||||
{
|
{
|
||||||
if (!(_x in _listedItemClasses)) then {
|
if (!(_x in _listedItemClasses)) then {
|
||||||
private "_item";
|
private "_item";
|
||||||
_item = configFile >> "CfgMagazines" >> _x;
|
_item = configFile >> "CfgMagazines" >> _x;
|
||||||
if (isNil "_item" || str _item == "") then { //str _item ?
|
if (isNil "_item" || str _item == "") then { //str _item ?
|
||||||
_item = configFile >> "CfgWeapons" >> _x;
|
_item = configFile >> "CfgWeapons" >> _x;
|
||||||
|
};
|
||||||
|
_actions = [_actions, getText(_item >> "displayName"), getText(_item >> "picture"), _x] call ACE_Interaction_fnc_addSelectableItem;
|
||||||
|
_listedItemClasses pushBack _x;
|
||||||
};
|
};
|
||||||
_actions = [_actions, getText(_item >> "displayName"), getText(_item >> "picture"), _x] call ACE_Interaction_fnc_addSelectableItem;
|
|
||||||
_listedItemClasses pushBack _x;
|
|
||||||
};
|
|
||||||
} forEach (_allGear);
|
} forEach (_allGear);
|
||||||
|
|
||||||
[_actions, {call ACE_Interaction_fnc_hideMenu;}, {call ACE_Interaction_fnc_hideMenu;}] call ACE_Interaction_fnc_openSelectMenu;
|
[_actions, {call ACE_Interaction_fnc_hideMenu;}, {call ACE_Interaction_fnc_hideMenu;}] call ACE_Interaction_fnc_openSelectMenu;
|
||||||
|
@ -21,43 +21,43 @@ PARAMS_2(_unit,_state);
|
|||||||
if (!local _unit) exitWith {[_this, _fnc_scriptName, _unit] call ACE_Core_fnc_execRemoteFnc};
|
if (!local _unit) exitWith {[_this, _fnc_scriptName, _unit] call ACE_Core_fnc_execRemoteFnc};
|
||||||
|
|
||||||
if (_state) then {
|
if (_state) then {
|
||||||
if (_unit getVariable ["ACE_isSurrender", false]) exitWith {};
|
if (_unit getVariable ["ACE_isSurrender", false]) exitWith {};
|
||||||
|
|
||||||
_unit setVariable ["ACE_isSurrender", true, true];
|
_unit setVariable ["ACE_isSurrender", true, true];
|
||||||
[_unit, "ACE_Surrendered", true] call ACE_Core_fnc_setCaptivityStatus;
|
[_unit, "ACE_Surrendered", true] call ACE_Core_fnc_setCaptivityStatus;
|
||||||
|
|
||||||
_unit spawn {
|
_unit spawn {
|
||||||
// fix for lowered rifle animation glitch
|
// fix for lowered rifle animation glitch
|
||||||
if (currentWeapon _this != "" && {currentWeapon _this == primaryWeapon _this} && {weaponLowered _this} && {stance _this == "STAND"}) then {
|
if (currentWeapon _this != "" && {currentWeapon _this == primaryWeapon _this} && {weaponLowered _this} && {stance _this == "STAND"}) then {
|
||||||
_this playMove "amovpercmstpsraswrfldnon";
|
_this playMove "amovpercmstpsraswrfldnon";
|
||||||
|
};
|
||||||
|
|
||||||
|
while {_this getVariable ["ACE_isSurrender", false]} do {
|
||||||
|
sleep 0.001; //sleep in UI
|
||||||
|
|
||||||
|
if (isPlayer _this) then {showHUD false};
|
||||||
|
|
||||||
|
if (!alive _this || {_this getVariable ["ACE_isUnconscious", false]}) then {
|
||||||
|
_this setVariable ["ACE_isSurrender", false, true];
|
||||||
|
} else {
|
||||||
|
_this playMove "amovpercmstpsnonwnondnon_amovpercmstpssurwnondnon";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
if !(_this getVariable ["ACE_isUnconscious", false]) then {
|
||||||
|
_this playMoveNow "AmovPercMstpSsurWnonDnon_AmovPercMstpSnonWnonDnon";
|
||||||
|
} else {
|
||||||
|
_this playMoveNow "unconscious";
|
||||||
|
};
|
||||||
|
|
||||||
|
[_this, "ACE_Surrendered", false] call ACE_Core_fnc_setCaptivityStatus;
|
||||||
|
|
||||||
|
if (isPlayer _this) then {showHUD true};
|
||||||
};
|
};
|
||||||
|
|
||||||
while {_this getVariable ["ACE_isSurrender", false]} do {
|
|
||||||
sleep 0.001; //sleep in UI
|
|
||||||
|
|
||||||
if (isPlayer _this) then {showHUD false};
|
|
||||||
|
|
||||||
if (!alive _this || {_this getVariable ["ACE_isUnconscious", false]}) then {
|
|
||||||
_this setVariable ["ACE_isSurrender", false, true];
|
|
||||||
} else {
|
|
||||||
_this playMove "amovpercmstpsnonwnondnon_amovpercmstpssurwnondnon";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
if !(_this getVariable ["ACE_isUnconscious", false]) then {
|
|
||||||
_this playMoveNow "AmovPercMstpSsurWnonDnon_AmovPercMstpSnonWnonDnon";
|
|
||||||
} else {
|
|
||||||
_this playMoveNow "unconscious";
|
|
||||||
};
|
|
||||||
|
|
||||||
[_this, "ACE_Surrendered", false] call ACE_Core_fnc_setCaptivityStatus;
|
|
||||||
|
|
||||||
if (isPlayer _this) then {showHUD true};
|
|
||||||
};
|
|
||||||
} else {
|
} else {
|
||||||
_unit setVariable ["ACE_isSurrender", false, true];
|
_unit setVariable ["ACE_isSurrender", false, true];
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
player playMove "AmovPercMstpSsurWnonDnon"
|
player playMove "AmovPercMstpSsurWnonDnon"
|
||||||
player switchMove "AmovPercMstpSsurWnonDnon_AmovPercMstpSnonWnonDnon"
|
player switchMove "AmovPercMstpSsurWnonDnon_AmovPercMstpSnonWnonDnon"
|
||||||
*/
|
*/
|
||||||
|
@ -26,7 +26,7 @@ _cargo = [_cargo, {_this getVariable ["ACE_isCaptive", false]}] call EFUNC(commo
|
|||||||
|
|
||||||
if ((count _cargo) > 0) then {
|
if ((count _cargo) > 0) then {
|
||||||
_target = _cargo select 0;
|
_target = _cargo select 0;
|
||||||
[QGVAR(MoveOut), [_target], [_target]] call EFUNC(common,targetEvent);
|
["MoveOutCaptive", [_target], [_target]] call EFUNC(common,targetEvent);
|
||||||
} else {
|
} else {
|
||||||
ERROR("No captive to unload");
|
ERROR("No captive to unload");
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user