Page MenuHomeFeedback Tracker

InventoryOpened crashes game when referencing the weapon holder with action "Gear"
Closed, ResolvedPublic

Description

EDIT: Seems that the cause was referencing the weapon holder that is created when you open your inventory the client will crash.

Details

Legacy ID
2149976277
Severity
None
Resolution
Not A Bug
Reproducibility
Always
Category
Game Crash
Steps To Reproduce

player addEventHandler ["InventoryOpened", {_this call EPOCH_startInteract; true}];

EPOCH_startInteract = { player action ["Gear", (_this select 1)]};

OR

player addEventHandler ["InventoryOpened", {call EPOCH_startInteract}];

EPOCH_startInteract = {
_handled = false;
_targets = nearestObjects[getPosATL player, ["WeaponHolder","WeaponHolderSimulated"], 2];
if ((count _targets) > 0) then {

		_target = _targets select 0;
		if (!isNull _target) then {
			player action ["Gear", _target];
			_handled = true;
		};

};
_handled
};

Event Timeline

vbawol edited Steps To Reproduce. (Show Details)Jun 19 2014, 1:09 AM
vbawol edited Additional Information. (Show Details)
vbawol set Category to Game Crash.
vbawol set Reproducibility to Always.
vbawol set Severity to None.
vbawol set Resolution to Not A Bug.
vbawol set Legacy ID to 2149976277.May 7 2016, 6:46 PM

Doesnt crash on todays dev

vbawol added a subscriber: vbawol.May 7 2016, 6:46 PM

Ya I should have waited to post this, it seems that its the code that I am passing that is causing the crash.

Revised steps to reproduce, crashes 100% of the time on 1.22

This is not a bug, you are creating infinite loop by opening gear from eh code which triggers eh again. Action gear triggers inventoryopened. You have to remove eh, check example on wiki.

Hello,
thank you for reporting. As Killzone Kid states, this is not a bug. However, on Steam Dev version it should not be crashing the game anymore.
Thank you.

@Iceman What did you do, added it to 10,000 iteration limit?

I understand that it creates a infinite loop now, I was under the impression that the opened handler was able to act before the actual opening hence the ability to suppress the inventory dialog entirely.

I guess it does what is says, opens the inventory first then closes it when passed true.

MadDogX added a subscriber: MadDogX.May 7 2016, 6:46 PM

Mass closing tickets marked as resolved more than 1 month ago.

If the issue is in fact not resolved, please create a new ticket referencing this one and ask for it to be re-opened.