So after installing the - I got thinking about what else I could add right-click menus to.
I decided that in order to test a few things, I'd make it so that only Admins could right-click that item.
I've modded the extra_rc.hpp file and think this looks right... mostly.
class ExtraRc { class ItemBloodbag { class Use { text = "Use Bloodbag"; script = "execVM 'custom\SelfBB.sqf'"; }; }; if ((getPlayerUID player) in ["ADMINUID1","ADMINUID2"]) then { class FoodSteakCooked { class Use { text = "Script 1 Test."; script = "execVM 'custom\customScript1.sqf'"; }; }; }; };
However, I'm a little concerned that's there's no "else" or "exit with".
I know that in other programming languages you don't always need those but the ArmA 2 Community/Dev Wiki isn't exactly clear on that.
Finally, is there a way to add right-click to a key? Checking for "ItemKeyGreen" etc doesn't seem like it would work due to the random 3/4 digits
after the item/class name.
Is there a wildcard type check the ArmA 2 engine lets us use? i.e ItemKeyGreen*
Thanks