0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Mano_InputConfigとVisuMZ_1_OptionsCoreを併用する

Posted at

ツクールMV時代はYEP_OptionCore.jsと併用する際は特別な設定なしで動きました。
これはYEP_KeyboardConfigとGamepadConfigであるかのように情報を偽装することで、設定情報を勝手に使って動かしていたためです。
しかし、RPGツクールMZになりVisuMZへ移行された際に上記のプラグイン2種類に対応したパラメータが消えたことで専用の処理を追加する必要が出ました。

対応コードを勝手に書くとVisuMZに対するライセンス違反になるので、パラメータ用のデータを記載します。
まず、下記の画像の順にプラグインパラメータを開いていきます。
image.png
image.png
image.png
image.png
image.png
image.png
一番下の画像の内容になったら、テキストの部分に以下の内容を貼り付けます。
上の方がゲームパッド用の設定、下の方がキーボード用の設定です。
それぞれ個別に追加してください。

{"Symbol:str":"GamepadConfig","Icon:num":"245","TextStr:str":"Untitled","TextJS:func":"\"return 'GamePad setting';\"","Accessibility":"","ShowJS:func":"\"// Return Boolean\\nreturn Imported.Mano_InputConfig;\"","EnableJS:func":"\"// Return Boolean\\nreturn true;\"","ExtJS:func":"\"// Return Value\\nreturn 0;\"","Functions":"","DrawJS:func":"\"// Declare Constants\\n\\nconst symbol = arguments[0];\\nconst index = arguments[1];\\nconst title = this.commandName(index);\\nconst rect = this.itemLineRect(index);\\nconst quarterWidth = rect.width / 4;\\nconst halfWidth = rect.width / 2;\\nconst value = this.getConfigValue(symbol);\\n\\n// Draw Command Name\\nthis.resetFontSettings();\\nthis.changePaintOpacity(true);\\nthis.drawTextEx(title, rect.x, rect.y, halfWidth, \\\"left\\\");\"","ProcessOkJS:func":"\"// Declare Constants\\nMano_InputConfig.gotoGamepad();\"","CursorRightJS:func":"\"// Declare Constants\\nconst symbol = arguments[0];\\nconst value = this.getConfigValue(symbol);\\nconst lastValue = value;\\n\"","CursorLeftJS:func":"\"// Declare Constants\\nconst symbol = arguments[0];\\nconst value = this.getConfigValue(symbol);\\nconst lastValue = value;\"","Data":"","DefaultJS:func":"\"\"","SaveJS:func":"\"\"","LoadJS:func":"\"\""}
{"Symbol:str":"KeyboardConfig","Icon:num":"245","TextStr:str":"Untitled","TextJS:func":"\"return 'Keyboard setting';\"","Accessibility":"","ShowJS:func":"\"// Return Boolean\\nreturn Imported.Mano_InputConfig;\"","EnableJS:func":"\"// Return Boolean\\nreturn true;\"","ExtJS:func":"\"// Return Value\\nreturn 0;\"","Functions":"","DrawJS:func":"\"// Declare Constants\\n\\nconst symbol = arguments[0];\\nconst index = arguments[1];\\nconst title = this.commandName(index);\\nconst rect = this.itemLineRect(index);\\nconst quarterWidth = rect.width / 4;\\nconst halfWidth = rect.width / 2;\\nconst value = this.getConfigValue(symbol);\\n\\n// Draw Command Name\\nthis.resetFontSettings();\\nthis.changePaintOpacity(true);\\nthis.drawTextEx(title, rect.x, rect.y, halfWidth, \\\"left\\\");\"","ProcessOkJS:func":"\"// Declare Constants\\nMano_InputConfig.gotoKey();\"","CursorRightJS:func":"\"// Declare Constants\\nconst symbol = arguments[0];\\nconst value = this.getConfigValue(symbol);\\nconst lastValue = value;\\n\"","CursorLeftJS:func":"\"// Declare Constants\\nconst symbol = arguments[0];\\nconst value = this.getConfigValue(symbol);\\nconst lastValue = value;\"","Data":"","DefaultJS:func":"\"\"","SaveJS:func":"\"\"","LoadJS:func":"\"\""}
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?