Okay so I've got a bit of knowledge on how javascript works, I just need help on starting out, I'm trying to make a plugin that allows you to disable parts of the main menu(Not the whole thing) and reactivate them when you want in your story, the problem is in what to use where, like I don't know how to begin the function. i don't want to give up and I don't want to know HOW to do it just HOW to start it like which Hierarchy would i use first
MZ Help with Disabling certain parts of the Main Menu
Learning JavascriptIt depends on which menus, and which parts, and how you want to disable/enable it.
I would probably allocate a switch to each "conditional" part of each menu (a different switch for each one), which will be OFF by default and can be turned ON at the appropriate time in the game. Then I'd check the Scene... and Window... classes to see how the visible setting is used, and write the plugin to modify or add to that in some way.
I would probably allocate a switch to each "conditional" part of each menu (a different switch for each one), which will be OFF by default and can be turned ON at the appropriate time in the game. Then I'd check the Scene... and Window... classes to see how the visible setting is used, and write the plugin to modify or add to that in some way.
@Shaz Okay so I want to like disable the actor menu on the main menu for a temporary time using a plugin command in an event, so I want to know how to write the script so that I can disable and enable those main menu options with a plugin command something tells me there is going to be a if statement somewhere
I think using a switch would be much easier. However ...
You will need an internal variable on the window class or the scene class to hold the true/false value, instead of a switch, to determine whether it should be visible or not.
The logic to hide or display the window will be the same - it will just look at that internal variable rather than a switch.
And you will need to register the plugin commands and set up the functions to call them, to turn the internal variable on or off.
If you don't know how to do this, find a SIMPLE plugin that has plugin commands, and see how they did it. Maybe some of the default plugins that come with MZ.
You will need an internal variable on the window class or the scene class to hold the true/false value, instead of a switch, to determine whether it should be visible or not.
The logic to hide or display the window will be the same - it will just look at that internal variable rather than a switch.
And you will need to register the plugin commands and set up the functions to call them, to turn the internal variable on or off.
If you don't know how to do this, find a SIMPLE plugin that has plugin commands, and see how they did it. Maybe some of the default plugins that come with MZ.
@Shaz sadly i know when I have been beat you can close this thread js is just not for me.
Moderator note: Closed
Original thread: https://forums.rpgmakerweb.com/threads/help-with-disabling-certain-parts-of-the-main-menu.135955/