Merge pull request #2515 from acemod/340fixinventoryeh

fix playerInventoryChanged eventhandler triggers when current weapon is changed fix #2513
This commit is contained in:
bux578 2015-09-19 21:04:48 +02:00
commit 450ee98004
2 changed files with 3 additions and 5 deletions

View File

@ -18,7 +18,6 @@
* 14-16: pistol (String, Array, Array)
* 17: map, compass, watch, etc. (Array)
* 18: binocluar (String)
* 19: active weapon, active muzzle, active weaponMode (Array)
*
*/
#include "script_component.hpp"
@ -35,8 +34,7 @@ if (isNull _unit) exitWith {[
"", ["","","",""], [],
"", ["","","",""], [],
[],
"",
["","",""]
""
]};
[
@ -49,6 +47,5 @@ if (isNull _unit) exitWith {[
secondaryWeapon _unit, secondaryWeaponItems _unit, secondaryWeaponMagazine _unit,
handgunWeapon _unit, handgunItems _unit, handgunMagazine _unit,
assignedItems _unit,
binocular _unit,
[currentWeapon _unit, currentMuzzle _unit, currentWeaponMode _unit]
binocular _unit
]

View File

@ -25,6 +25,7 @@ if (ACE_player == _killedUnit) then {
if (GVAR(SavePreDeathGear)) then {
GVAR(unitGear) = [_killedUnit] call EFUNC(common,getAllGear);
GVAR(unitGear) pushBack [currentWeapon _killedUnit, currentMuzzle _killedUnit, currentWeaponMode _killedUnit];
};
};