BEAKSBY 11 Posted May 28, 2014 HI Folkes, If anyone is familiar with https://community.bistudio.com/wiki/showCommandingMenu I need help with creating a // optional icon path: The path to the texture of the cursor, that should be used on this menuitem. I placed my "\SlammerUp2_ca.paa" in my mission folder and when I run the mission I get a message "Cannot load texture slammersp2_ca.paa." What are the maximum file size or other relevant parameters I need to obey? //This script will create a custom menu, and display it once. //This script will create a custom menu, and display it once. [url]https://community.bistudio.com/wiki/showCommandingMenu[/url] MY_SUBMENU_inCommunication = [ ["User submenu",true], ["Option-1", [2], "", -5, [["expression", "player sidechat ""-1"" "]], "0", "0", "\ca\ui\data\cursor_support_ca"], ["Option 0", [3], "", -5, [["expression", "player sidechat "" 0"" "]], "1", "0", "\ca\ui\data\cursor_support_ca"], ["Option 1", [4], "", -5, [["expression", "player sidechat "" 1"" "]], "1", "CursorOnGround", "\ca\ui\data\cursor_support_ca"] ]; MY_MENU_inCommunication = [ // First array: "User menu" This will be displayed under the menu, bool value: has Input Focus or not. // Note that as to version Arma2 1.05, if the bool value set to false, Custom Icons will not be displayed. ["MOTOR POOL",true], // Syntax and semantics for following array elements: // ["Title_in_menu", [assigned_key], "Submenu_name", CMD, [["expression",script-string]], "isVisible", "isActive" <, optional icon path> ] // Title_in_menu: string that will be displayed for the player // Assigned_key: 0 - no key, 1 - escape key, 2 - key-1, 3 - key-2, ... , 10 - key-9, 11 - key-0, 12 and up... the whole keyboard // Submenu_name: User menu name string (eg "#USER:MY_SUBMENU_NAME" ), "" for script to execute. // CMD: (for main menu:) CMD_SEPARATOR -1; CMD_NOTHING -2; CMD_HIDE_MENU -3; CMD_BACK -4; (for custom menu:) CMD_EXECUTE -5 // script-string: command to be executed on activation. (no arguments passed) // isVisible - Boolean 1 or 0 for yes or no, - or optional argument string, eg: "CursorOnGround" // isActive - Boolean 1 or 0 for yes or no - if item is not active, it appears gray. // optional icon path: The path to the texture of the cursor, that should be used on this menuitem. ["First", [0], "", -5, [["expression", "player sidechat ""First"" "]], "1", "0"], ["M2A4 Slammer UP $1200", [2], "", -5, [["expression", "player sidechat ""Second"" "]], "1", "1", "\SlammerUp2_ca.paa"], ["Submenu", [3], "#USER:MY_SUBMENU_inCommunication", -5, [["expression", "player sidechat ""Submenu"" "]], "1", "1"] ]; // "<img size='2' shadow='5' image='SlammerUp1_CA.paa'/> <t color='#00dd00'>M2A4 Slammer UP $1200</t>", showCommandingMenu "#USER:MY_MENU_inCommunication"; Share this post Link to post Share on other sites
f2k sel 164 Posted May 28, 2014 Is it actually possible? I know you can add custom map markers but they have to be in an addon, it may be the same for cursors. "SlammerUp2_ca.paa" works fine as an Icon so I suspect it's not possible unless you have some examples. Share this post Link to post Share on other sites
BEAKSBY 11 Posted May 28, 2014 I just want to add the icon beside the name in the custom menu list, similarly to what we had in the addAction command. player addAction ["<img size='2' shadow='5' image='SlammerUp1_CA.paa'/> <t color='#00dd00'>M2A4 Slammer UP $1200</t>", "ObjectPositionAndDirectionD.sqf",[],0,true,true,"","sector1 getVariable 'owner' == side _this and vehicle _this == _target"] ; This is a better solution to the addAction as it has submenus built in and the ability to diasable items (gray out). This should work nicely with my money script, so if you can't afford something it remains grayed out. I just don't know how to set conditions to activate or deactivate the "isActive" portion, yet. https://community.bistudio.com/wiki/showCommandingMenu // ["Title_in_menu", [assigned_key], "Submenu_name", CMD, [["expression",script-string]], "isVisible", "isActive" <, optional icon path> ] // isActive - Boolean 1 or 0 for yes or no - if "player does not have enough money" item is not active, it appears gray. ["M2A4 Slammer UP $1200", [2], "", -5, [["expression", "player sidechat ""Second"" "]], "1", "1", "\SlammerUp2_ca.paa"], Share this post Link to post Share on other sites