Author: albertfish
Author Website:

Requirements: No addons required

Version: 2.1
Signed: Yes, serverkey included

Short description: This mod aims to make it easy to mod makers to add custom GUIs to the game menus.

Date: 2014-11-23 10:12


Comments: (0)
Rating:



 







Menu Extension

by
albertfish


Description:
This mod introduces a couple new buttons into the in game menu. These buttons can be expanded to reveal several other buttons that can be added in by mission makers and mod makers. These buttons can be used to open GUI displays through the menus. This mod aims to make it easy to mod makers to add custom GUIs to the game menus.

For mission makers and script makers, this can be a great alternative to having actions in the scroll wheel menu.


Features:
Ability to add buttons to the Mod Settings and Mission Settings menus
Accordion style expanding menus
Able to scroll thorugh button if there more than 10


Installation:
Extract into the ArmA 3 Directory, by default this is located in:
32-Bit - C:\Program Files\Steam/Steamapps\Common\ArmA 3\
64-Bit - C:\Program Files (x86)\Steam/Steamapps\Common\ArmA 3\
After extraction it should look like this:
Steam\Steamapps\Common\ArmA 3\@your_mod_folder_name\addons\

You can also use the "Arma 3 Alpha" folder in your "My Documents" folder. Your folder setup could than look like for example this:
mydocuments\Arma3 Alpha\@your_mod_folder_name1\addons\
mydocuments\Arma3 Alpha\@your_mod_folder_name2\addons\
mydocuments\Arma3 Alpha\@your_mod_folder_name2\addons\

When present place the "userconfig" folder into your game install folder, usually:
"C:\Program Files (x86)\Steam\steamapps\common\Arma 3".
You may already have "userconfig" folder from other addons and/or mods in which case it is safe to merge the contents from this archive.

You'll also need to add a Launch Parameter to Steam, in order to do so right-click on ArmA 3 Alpha and click Properties and then Set Launch Options. In the window that opens enter in -mod=@your_mod_folder_name
For using multiple mods you would then do so like this:
-mod=@mod_name;@mod_name2;@mod_name3;@mod_name4;@mod_name5

Note:
You can also use -nosplash to get rid of the splash art and intro videos.


And of course you can also enable and disable community made addons and mods through the in-game Options Expansions menu if you do not want to mess with startup parameters!

When the above information still does not provide you with enough to learn how to install custom addons and mods you can always ask in our Guide On Installing Mods.


Included files:
af_MenuExtension.pbo


Usage:
For Mod Makers:
To add a button to the Mod Settings menu, you have to make an entry into the ModSettingsMenuEntries class. The format is as follows:
class MenuExtension_Entries
{
	class MenuExtensionExample
	{
		buttonText = "Example Button";
		resource = "MEExampleDisplay";
                function = "fnc_ShowExampleDisply";
	};
};
Where
MenuExtensionExample is a class name of your choosing.
buttonText is the text that will appear on the button.
resource is the classname for the GUI you would like to launch.
function name of the custom function that will create the dialog. This can also be the name of a script you want to execute. This parameter is optional.

To check if the mod is installed you can do:
isClass(configFile >> "CfgPatches" >> "af_MenuExtension")

For Mission Makers:
To add a button to the Mission Settings menu you simply have to make a call to af_fnc_AddMenuItem.
For Example:
["Example Button", "MEExampleDisplay", "UIExample\show_gui.sqf;"] call af_fnc_AddMenuItem;
The first parameter is the text that will appear on the button.
The second parameter classname of the dialog that you are opening.
The third parameter is the function or script that will be executed when the button is clicked.

To delete a button from the Mission Settings menu you simply have to make a call to af_fnc_DeleteMenuItem.
For Example:
["Example Button"] call af_fnc_DeleteMenuItem;
The parameter is the text that is displayed on the button.


Media:



Armaholic.com has its own Youtube channel where we will cover the Community made releases.
Subscribe to the Armaholic.com Youtube channel


Notes:
Please let me know if you come across any issues with this mod.


Changelog:
v2.1
- Added a function option that allows this mod to call a function to create the dialog
- No longer requires you to use closeDisplay

v2.0
- Updated to work with the latest version of Arma 3
- Removed the pages when more than 10 buttons are added and replaced it with the ability to scroll
- Empty menus will no longer be displayed
- Now works in single player missions
- Removed the CBA dependency
- Changed function names to better follow the BIS convention

v1.0
- Initial Release


Forum topic:
- BI forums




Enable javascript to be able to download from Armaholic please!



Tags: No tags