Fix interactions with civilians

This commit is contained in:
Nicolás Badano 2015-03-02 23:30:11 -03:00
parent 83572921ae
commit cd00eda8c0
3 changed files with 14 additions and 2 deletions

View File

@ -122,7 +122,7 @@ class CfgVehicles {
class ACE_GetDown {
displayName = "$STR_ACE_Interaction_GetDown";
distance = 5;
condition = QUOTE([_target] call DFUNC(canInteractWith));
condition = QUOTE([_target] call DFUNC(canInteractWithCivilian));
statement = QUOTE([_target] call DFUNC(getDown));
showDisabled = 0;
priority = 2.2;
@ -130,7 +130,7 @@ class CfgVehicles {
class ACE_SendAway {
displayName = "$STR_ACE_Interaction_SendAway";
distance = 5;
condition = QUOTE([_target] call DFUNC(canInteractWith));
condition = QUOTE([_target] call DFUNC(canInteractWithCivilian));
statement = QUOTE([_target] call DFUNC(sendAway));
showDisabled = 0;
priority = 2.0;

View File

@ -4,6 +4,7 @@ ADDON = false;
PREP(addSelectableItem);
PREP(applyButtons);
PREP(canInteractWithCivilian);
PREP(canTapShoulder);
PREP(getDoor);
PREP(getDoorAnimations);

View File

@ -0,0 +1,11 @@
// by commy2
#include "script_component.hpp"
EXPLODE_2_PVT(_this,_unit,_isCivilian);
if (isNil "_isCivilian") then {_isCivilian = true};
alive _unit
&& [side _unit != side ACE_player, side group _unit == civilian] select _isCivilian
//&& {count (weapons _unit) == 0}