Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CBA_fnc_addItemContextMenuOption no longer displays the context menu item #1703

Closed
TheCannonFodder opened this issue Oct 12, 2024 · 2 comments
Labels
Milestone

Comments

@TheCannonFodder
Copy link

Mods (complete and add to the following information):

  • Arma 3: 2.18 [e.g. 1.00 stable, rc, dev]
  • CBA: 3.18.0 [e.g. 3.0.0 stable, commit hash]
    Make sure to reproduce the issue with only CBA on a newly created mission!

Description:
CBA_fnc_addItemContextMenuOption no longer displays the context menu item

Steps to reproduce:
Place unit in editor.
Enter this in init of unit:

["FirstAidKit", ["CONTAINER","CLOTHES"], "Open IFAK", nil, nil, [{
params ["_unit"];
private _freeMassVest = (1 - loadVest _unit) * getContainerMaxLoad vest _unit;
private _freeMassUniform = (1 - loadUniform _unit) * getContainerMaxLoad uniform _unit;
private _freeMassBackpack = (1 - loadBackpack _unit) * getContainerMaxLoad backpack _unit;
private _addedMass = 0;
{
  _x params ["_item", "_cnt"];
  _addedMass = _addedMass + _cnt * getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "mass");
} forEach [["ACE_morphine", 2], ["ACE_quikclot", 10],["ACE_tourniquet", 2],["ACE_bloodIV_500",1],["ACE_bloodIV_500",1], ["ACE_packingBandage", 10]];
(_freeMassVest >= _addedMass) || (_freeMassUniform >= _addedMass) || (_freeMassBackpack >= _addedMass)
},{params ["_unit"]; _unit isEqualTo vehicle _unit;}],
{
params ["_unit", "_container", "_item", "_slot", "_params"];
for "_i" from 1 to 2 do {_unit addItem "ACE_morphine";};
for "_i" from 1 to 10 do {_unit addItem "ACE_quikclot";};
for "_i" from 1 to 10 do {_unit addItem "ACE_packingBandage";};
for "_i" from 1 to 2 do {_unit addItem "ACE_tourniquet";};
_unit addItem "ACE_bloodIV_500";
_unit addItem "ACE_bloodIV_500";
true
}, true, [0,1,2]] call CBA_fnc_addItemContextMenuOption;

Play as unit.
Click first aid kit

Expected behavior:
Link: https://youtu.be/J2d3u5eQNiU
Context menu to open and convert items

Where did the issue occur?

  • Dedicated: Yes
  • Self-Hosted Multiplayer: Yes
  • Editor (Multiplayer): Yes
@PabstMirror
Copy link
Contributor

Should be fixed by #1704 (I will test)

@PabstMirror PabstMirror added this to the 3.18.1 milestone Oct 13, 2024
@PabstMirror
Copy link
Contributor

Will be fixed in 3.18.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants