Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
no, blahblahblahblah is just a default if it cannot get the variable from the AI. So the switch statements gets blahblahblah and runs the default {}; otherwise it did get a variable and runs that code within the switch.
Make sure you have the setVariable command server side.
Then if you just walk up to the different AI, you should see the "Medical" or "Weapons" etc.
Once you click on that, it should go to the next step - showing the items for that category.
i have got it runngin fine on first attempt, thanks for the fast reply
only issue i have is being in just the right spot by a camp fire to get the menu up, otherwise its perfect
even added a few of my own items that we needed, all in all, great job on the script thanks
manatee_craft_menu_wea set [count manatee_craft_menu_wea, player addaction [("<t color=""#FFC726"">" + (" Satchel Charge") +"</t>"),"addons\oven.sqf",
[
[0,"Satchel Charge","PipeBomb",1], //what is being returned
[ //Ingredients
[0,"1Rnd_HE_M203",3,"M203 HE"], //1st requirement
[0,"HandGrenade_West",3,"M97 Hand Grenade"] //2nd requirement
]
],
92,false,false,"",_restriction]]; //action parameters
} else {
// the players gear does not match
_neededString = [];
{
_itemClass3 = _x select 1;
_itemQty3 = _x select 2;
_itemName3 = _x select 3;
_inUserInv3 = _itemQty3-({_x == _itemClass3} count magazines player);
_neededString set [count _neededString, format["%1/%2 %3",_inUserInv3,_itemQty3,_itemName3]];
} forEach _neededItems;
cutText [format ["To make a %1 you need: %2",_makeItemName, _neededString], "PLAIN DOWN",1];
};
To make a Satchel Charge you need 3/3 M203, 3/3 M97 Handgrenade
manatee_craft_menu_sur set [count manatee_craft_menu_sur, player addaction [("<t color=""#FFC726"">" + (" Grenade Tripwire") +"</t>"),"crafting\oven.sqf",[[0,"Grenade Tripwire","ItemTrapTripwireGrenade",1],[[0,"equip_string",1],[0,"equip_duct_tape",1],[0,"partwoodpile",1],[0,"HandGrenade_west",1]]],94,false,false,"",_restriction]];
manatee_craft_menu_sur set [count manatee_craft_menu_sur, player addaction [("<t color=""#FFC726"">" + (" Flare Tripwire") +"</t>"),"crafting\oven.sqf",[[0,"Flare Tripwire","ItemTrapTripwireFlare",1],[[0,"equip_string",1],[0,"equip_duct_tape",1],[0,"partwoodpile",1],[0,"HandRoadFlare",1]]],94,false,false,"",_restriction]];
manatee_craft_menu_sur set [count manatee_craft_menu_sur, player addaction [("<t color=""#FFC726"">" + (" Tin Can Tripwire") +"</t>"),"crafting\oven.sqf",[[0,"Tin Can Tripwire","ItemTrapTripwireCans",1],[[0,"equip_string",1],[0,"partwoodpile",1],[0,"TrashtinCan",1]]],94,false,false,"",_restriction]];