Tova 130 Posted September 30, 2018 Hello ! I already know that I can create a custom inventory item through a config.cpp this way thanks to@R3vo: class CfgWeapons { class ItemCore; class InventoryItem_Base_F; class MyItem: ItemCore { displayName = "Tova's cool item"; model = "\A3\structures_f_epa\Items\medical\antibiotic_F"; scope = 2; scopeArsenal = 2; scopeCurator = 2; picture = ""; descriptionShort = "This item is very cool"; class ItemInfo: InventoryItem_Base_F { mass=5; }; }; }; But I'd also like to execute a script when this I double click on that item in the inventory, however I don't know how I could do that... NB : I believe it may have something to do with the "LBDblClick" eventhandler, but I have to say that I am clueless. 1 Share this post Link to post Share on other sites
Spatsiba 89 Posted September 30, 2018 waituntil {!(isnull (finddisplay 602))}; { ((findDisplay 602) displayCtrl _x) ctrlSetEventHandler ["LBDblClick", "if (""<ITEM>"" == lbText [ctrlIDC (_this select 0), _this select 1]) then {execVM ""script.sqf""};"]; } count [633, 638, 619]; I think that should work. Found it on some skethcy forum and slightly modified it. 3 Share this post Link to post Share on other sites
BRPVP 69 Posted August 19, 2019 @Tova This worked for you? @Spatsiba <ITEM> is the classname of the clicked item? Share this post Link to post Share on other sites
Larrow 2823 Posted August 20, 2019 Inventory interaction Selecting Inventory Items (this is the code as shown by @Spatsiba) 5 Share this post Link to post Share on other sites