Merge branch 'master' into medical-adjustments2

This commit is contained in:
Glowbal 2015-09-05 13:22:44 +02:00
commit 6405ef7d91
2 changed files with 7 additions and 4 deletions

View File

@ -41,7 +41,7 @@ if (getNumber (configFile >> "CfgVehicles" >> _type >> QGVAR(hasCargo)) != 1) ex
private ["_text", "_condition", "_statement", "_icon", "_action"];
_condition = {
params ["_target", "_player"];
GVAR(enable) && {[_player, _target, []] call EFUNC(common,canInteractWith)}
GVAR(enable) && {locked _target < 2} && {[_player, _target, []] call EFUNC(common,canInteractWith)}
};
_text = localize LSTRING(openMenu);
_statement = {GVAR(interactionVehicle) = _target; createDialog QGVAR(menu);};

View File

@ -182,15 +182,18 @@ _activeWeapon = _activeWeaponAndMuzzle select 0;
_activeMuzzle = _activeWeaponAndMuzzle select 1;
_activeWeaponMode = _activeWeaponAndMuzzle select 2;
if (_activeMuzzle != "" and _activeMuzzle != _activeWeapon) then {
if (!(_activeMuzzle isEqualTo "") and
!(_activeMuzzle isEqualTo _activeWeapon) and
(_activeMuzzle in getArray (configfile >> "CfgWeapons" >> _activeWeapon >> "muzzles"))) then {
_unit selectWeapon _activeMuzzle;
} else {
if (_activeWeapon != "") then {
if (!(_activeWeapon isEqualTo "")) then {
_unit selectWeapon _activeWeapon;
};
};
if (currentWeapon _unit != "") then {
if (!(currentWeapon _unit isEqualTo "")) then {
private ["_index"];
_index = 0;
while {