Rpgmakermv(16) YEP MainmenuManager

时间:2021-11-29 03:42:54

--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 原文:

============================================================================

For those who wish to alter the various aspects of the main menu commands
without needing to touch the source code can use this plugin to do so.
Although this plugin mostly ports the menu creation process to the Plugin
Manager parameters, it allows for a cleaner way to handle the menu command
management process.

============================================================================
How to Use This Plugin
============================================================================

Each section in the parameters is divided up into various parts. Each of
these parts play a role in how the menu command functions. Here's what each
part does:

Name
- This is how the command will appear visually in the main menu. This is an
eval, which means, it's code driven. If you want the command to appear just
as it is, use 'quotes' around it.

Symbol
- This is the identifier for the command. Each command should have a unique
symbol, so much as to not cause conflicts with each command. However, shared
symbols are perfectly fine as long as you're fine with them performing the
same function when selected.

Show
- This is an eval condition for whether or not the command shows up in the
main menu. If you wish for this to always show up, simply use 'true' without
the quotes.

Enabled
- This is an eval condition for whether or not the command is enabled. The
difference between showing a command and enabling a command is that a
command can show, but it can't be selected because it isn't enabled. If you
wish for this command to always be enabled, use 'true' without the quotes.

Ext
- Stands for extension. This serves as a secondary symbol for the command
and it can be used for pretty much anything. It has no direct impact on the
command unless the command's objective is related to the extension value.
The majority of commands do not need to make use of the Ext value.

Main Bind
- This is an eval function that is to be ran when this command is selected
straight from the main menu. The function that is to be bound to this
command needs to be accessible from Scene_Menu is some way or another. For
commands that are meant to select an actor first, use
'this.commandItem.bind(this)' without the quotes.

Actor Bind
- This is an eval function that is to be ran when an actor is selected after
choosing this command, usually to push a scene. This function isn't needed
for any menu commands that don't require selecting an actor.

============================================================================
Examples
============================================================================

The following are some examples to help you add/alter/change the way
commands appear for your main menu.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Name: TextManager.item
Symbol: item
Show: this.needsCommand('item')
Enabled: this.areMainCommandsEnabled()
Ext:
Main Bind: this.commandItem.bind(this)
Actor Bind:

The item command is made using the above example. 'TextManager.item' is how
the command name will appear. It draws the name information from the
database Text Manager entry for 'Item' and uses whatever you put into the
database in here. The symbol 'item' is used to make the item command's
unique identifier. In order for the command to show, it will run a
'needsCommand' function to check if it will appear. This 'needsCommand'
function is related to your database on whether or not you want the item to
appear there. In order for this command to be enabled, it will check for
whether or not the main commands are enabled, which is related to whether or
not there are actors in the current party. And finally, the line of code
'this.commandItem.bind(this)' is the command that will run once the item
entry is selected.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Name: TextManager.skill
Symbol: skill
Show: this.needsCommand('skill')
Enabled: this.areMainCommandsEnabled()
Ext:
Main Bind: this.commandPersonal.bind(this)
Actor Bind: SceneManager.push(Scene_Skill)

The skill command is made using the above example. 'TextManager.skill' is
how the command name will appear. It draws the name information from the
database Text Manager entry for 'Skill' and uses whatever you put into the
database in here. The symbol 'skill' is used to make the skill command's
unique identifier. In order for the command to show, it will run a line code
'needsCommand' function to check if it will appear. This 'needsCommand'
function is related to your database on whether or not you want the skill
option to appear there. In order for this command to be enabled, it will
check for whether or not the main commands are enabled, which is related to
whether or not there are actors in the current party. This time, the main
bind command is to send the player to the actor selection process using
'this.commandPersonal.bind(this)' instead. Once the player selects an actor, 'SceneManager.push(Scene_Skill)' is then ran to send the player to Scene_Skill to manage the actor's skills. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Name: 'Common Event 1' Symbol: common event Show: false Enabled: true Ext: 1 Main Bind: this.callCommonEvent.bind(this) Actor Bind: This is a customized command that is included by default with the plugin. This command's name is 'Common Event 1', but it can be changed to whatever you want by simply changing what's in between the 'quotes' in the parameter settings. The symbol is the identifier for all common events. However, by default, this common event item does not show in the main menu. If you want it to appear, set the Show option to 'true' without the quotes and it will appear. Because the Enabled option is 'true', the command can always be selected by the player. The Ext actually has a role with this command. The Ext determines which common event is to be played. In this example, the Ext value is 1, which means common event 1 will be ran when this command is selected. Should the Ext value equal to 25, it will be common event 25 that will run once this command is selected. The reason is because the Main Bind for this command option is 'this.callCommonEvent.bind(this)', which is a function included in this plugin to allow for common events to be ran. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ============================================================================ Changelog ============================================================================ Version 1.01: - Added 'Hide Actor Window', 'Hide Gold Window', 'Blurry Background' parameters for the plugin settings. Version 1.00: - Finished plugin!

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

译文:

================================================= ==========================

对于那些希望改变主菜单命令的各个方面的人
无需触摸源代码就可以使用这个插件来做到这一点。
虽然这个插件主要将菜单创建过程移植到插件
管理器参数,它允许更清晰的方式来处理菜单命令
管理过程。

================================================== ==========================
如何使用这个插件
================================================== ==========================

参数中的每个部分被分成不同的部分。每一个
这些部分在菜单命令的功能中扮演着一个角色。这是每个
部分是:

名称
- 这是命令将如何在主菜单中直观显示。这是一
eval,这意味着它是代码驱动的。如果你想命令只出现
照原样使用“引号”。

符号
- 这是命令的标识符。每个命令都应该有一个唯一的
符号,以至于不会与每个命令发生冲突。但是,共享
符号是完全正常的,只要你对他们表现良好
选中时功能相同。

显示
- 这是一个评估命令是否显示在内的评估条件
主菜单。如果您希望始终显示,只需使用“true”即可
报价。

启用
- 这是是否启用该命令的一个评估条件。该
显示命令和启用命令之间的区别在于a
命令可以显示,但不能被选中,因为它没有启用。如果你
希望此命令始终处于启用状态,请使用不带引号的“true”。

分机
- 代表延期。这是该命令的辅助符号
它可以用于任何东西。它对此没有直接影响
命令,除非命令的目标与扩展值相关。
大多数命令不需要使用Ext值。

主要绑定
- 这是一个在选择此命令时要运行的eval函数
直接从主菜单。这个绑定的功能
命令需要从Scene_Menu访问是某种方式。对于
用于首先选择演员的命令
'this.commandItem.bind(this)'没有引号。

演员绑定
- 这是一个eval函数,当一个演员被选中后,它将被运行
选择这个命令,通常是为了推动一个场景。这个功能是不需要的
用于任何不需要选择演员的菜单命令。

================================================== ==========================
例子
================================================== ==========================

以下是帮助您添加/更改/更改方式的示例
命令出现在您的主菜单中。

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

名称:TextManager.item
    符号:项目
      显示:this.needsCommand('item')
   启用:this.areMainCommandsEnabled()
       分机:
 主要绑定:this.commandItem.bind(this)
演员绑定:

item命令是使用上面的例子制作的。 'TextManager.item'是如何
命令名将会出现。它从中提取名称信息
数据库文本管理器条目的'项目',并使用任何你放入
数据库在这里。符号'item'用于制作项目命令
唯一标识符。为了显示该命令,它将运行一个
'needsCommand'函数检查它是否会出现。这个'needsCommand'
函数与您的数据库是否需要项目相关
出现在那里。为了启用此命令,它将检查
是否启用主要命令,这与是否相关
目前派对中没有演员。最后,代码行
'this.commandItem.bind(this)'是一次运行该项目的命令
条目被选中。

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

名称:TextManager.skill
    符号:技能
      显示:this.needsCommand('skill')
   启用:this.areMainCommandsEnabled()
       分机:
 主要绑定:this.commandPersonal.bind(this)
Actor Bind:SceneManager.push(Scene_Skill)

技能命令是使用上面的例子。 'TextManager.skill'是
如何显示命令名称。它从中提取名称信息
数据库文本管理器条目的'技能',并使用任何你放入
数据库在这里。符号“技能”用于制作技能指令
唯一标识符。为了显示该命令,它将运行一个行代码
'needsCommand'函数检查它是否会出现。这个'needsCommand'
函数与您的数据库有关是否需要该技能
选项出现在那里。为了启用此命令,它将会启用
检查主要命令是否被启用,这与相关
无论目前派对中是否有演员。这一次,主要
绑定命令是将播放器发送给使用的演员选择过程
“T改为“his.commandPersonal.bind(this)”。一旦玩家选择了一名演员,然后运行“SceneManager.push(Scene_Skill)”将该玩家发送到Scene_Skill以管理演员的技能。 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 名称:'Common Event 1'符号:普通事件显示:false启用:true Ext:1 Main Bind:this.callCommonEvent.bind(this)Actor Bind:这是一个默认包含在插件中的自定义命令。该命令的名称是'公共事件1',但只需更改参数设置中'引号'之间的内容即可将其更改为想要的任何内容。该符号是所有常见事件的标识符。但是,默认情况下,此常见事件项不会显示在主菜单中。如果你想让它出现,把Show选项设置为'true'而不用引号,它会出现。由于Enabled选项为'true',因此该命令始终可以由玩家选择。 Ext实际上在这个命令中有一个角色。 Ext决定要播放哪个常见事件。在这个例子中,Ext值是1,这意味着选择此命令时将运行常见事件1。如果Ext值等于25,则选择该命令后将运行的常见事件25。原因是因为这个命令的Main Bind选项是'this.callCommonEvent.bind(this)',这是一个包含在这个插件中的函数,允许运行常见的事件。 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ============ ================================================== ============== Changelog =================================== =========================================版本1.01: - 添加'隐藏演员视窗','隐藏金色窗口','模糊背景'参数。版本1.00: - 完成的插件!

------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------