Jump to content
Ibragim A

[SOLVED] Edit "RscMainMenu" and other original menus

Recommended Posts

Hi, I tried to find the answer myself but no results so far.

Is there any way to modify and edit the original command menus such as "RscMainMenu" and others similar to it?

Can I add my own shooting mode or a new movement speed mode to them?

Share this post


Link to post
Share on other sites
11 minutes ago, .kju said:

https://community.bistudio.com/wiki/BIS_fnc_addCommMenuItem

or via config mode using 


command = -5;

to be able to call custom scripts - check how high command is done (RscHCGroupRootMenu)

 

you can "edit" the existing in overwriting entries or adding new at the end (but there is max 10 page menu i believe)

Thanks for the answer.

BIS_fnc_addCommMenuItem - this function adds a new option to a specific menu named "#User: BIS_fnc_addCommMenuItem_menu".

I know this method, but I want to understand if it is possible to add a new option to an existing menu, for example "RscMenuCombatMode".

Let's say I created a new combat mode and I want to add it to the original game menu, not to the custom one.
 

Share this post


Link to post
Share on other sites

as said via config mode with the given limitations mentioned

  • Thanks 1

Share this post


Link to post
Share on other sites
23 minutes ago, .kju said:

as said via config mode with the given limitations mentioned

Thanks for the hint, I'll try to do it.

Share this post


Link to post
Share on other sites
5 hours ago, .kju said:

as said via config mode with the given limitations mentioned

This is the first time I work with intervention in configs through discription, so I don't yet understand how to display the path to a specific menu in a description.ext.

The code I tried to do doesn't change anything in the menu.

Please explain to me how to add a new option to the menu in the discription file correctly.

/// Not working

class RscMenuCombatMode
	{
		class Items
			{
				class NewOption
					{
						command = -5;
						enable = "NotEmpty";
						shortcuts[] = {2};
						shortcutsAction = "CommandingMenu1";
						show = "IsLeader";
						title = "NewOption";
					};
			};
	};

 

Share this post


Link to post
Share on other sites

Only works in config mod - not mission desc.ext

Share this post


Link to post
Share on other sites
class RscMenuCombatMode
	{
		class Items
			{
				class NewOption
					{
						command = -5;
						enable = "NotEmpty";
						shortcuts[] = {6};
						shortcutsAction = "CommandingMenu5";
						show = "IsLeader";
						title = "NewOption_title";
					};
			};
	};

I putted this code to the config.cpp and got the following output:

 

Arma3-x64-2021-11-09-14-50-38-054.png

 

I would like you to teach me two things:

  • How do I move my option to fifth place?
  • How to define my own code in the configuration that the user will call through this option? (See my idea below)
class NewOption
  {
    command = -5;
    enable = "NotEmpty";
    shortcuts[] = {6};
    shortcutsAction = "CommandingMenu5";
    show = "IsLeader";
    title = "NewOption_title";

    script = "[] spawn somescript.sqf"; /// <--  I mean something like this.
  };

Hope you understand my, Thanks.

Share this post


Link to post
Share on other sites

Ok. I got the option to work, but still can't figure out how to move it to the fifth position.

class RscMenuCombatMode
	{
		class Items
			{
				class NewOption
					{
						command = -5;
						enable = "NotEmpty";
						shortcuts[] = {6};
						shortcutsAction = "CommandingMenu5";
						show = "IsLeader";
						title = "NewOption_title";
						
						class Params
							{								
								expression = "systemchat 'It works'";
							};
					};
			};
	};

 

Share this post


Link to post
Share on other sites

So I figured it out by myself.

class RscMenuCombatMode
	{
		class Items
			{
				class Stealth 
					{						
						
					};
				class Combat 
					{						
						
					};
				class Aware 
					{						
						
					};
				class Safe 
					{						
						
					};
				class NewOption
					{
						command = -5;
						enable = "NotEmpty";
						shortcuts[] = {6};
						shortcutsAction = "CommandingMenu5";
						priority = 0;
						show = "IsLeader";
						title = "NewOption_title";
						
						class Params
							{								
								expression = "systemchat 'It works'";
							};
					};
			};
	};

This code makes changes in "RscMenuCombatMode"  like this:
Arma3-x64-2021-11-09-17-46-19-297.png

  • Like 2

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×