Welcome to PGMZ! My goal is to make it easy for everyone to find and share great plugins for creating amazing games. As a plugin developer myself, I'm excited to grow this community with all of you.
Mano Input Config - Mano_InputConfig.js
Plugin desc : ゲームの操作に関する機能をまとめて管理します。
License : MIT License
Author : しぐれん(https://github.com/Sigureya/RPGmakerMV)
Website : https://github.com/Sigureya/RPGmakerMZ/blob/master/Mano_InputConfig.js
Desc page : https://raw.githubusercontent.com/Sigureya/RPGmakerMZ/master/Mano_InputConfig.js
Download Page : https://raw.githubusercontent.com/Sigureya/RPGmakerMZ/master/Mano_InputConfig.js
File name : Mano_InputConfig.js
Help of plugin :
* @plugindesc ゲームの操作に関する機能をまとめて管理します。
* ユーザーによる拡張も支援します。
* @author しぐれん(https://github.com/Sigureya/RPGmakerMV)
* @url https://raw.githubusercontent.com/Sigureya/RPGmakerMZ/master/Mano_InputConfig.js
*
* @target MZ
* @orderAfter VisuMZ_1_OptionsCore
* @orderAfter MOG_TitleSplashScreen
*
* @command GetButtonName
* @text GetButton/ボタン名の取得
* @desc 指定した操作がどのボタンにあるかを返します。
* Returns which button has the specified action.
* @arg symbol
* @type select
* @option ok(決定)
* @value ok
* @option cancel(取り消し)
* @value cancel
* @option shift(ダッシュ)
* @value shift
* @option menu(メニュー)
* @value menu
* @option pageup(前)
* @value pageup
* @option pagedown(次)
* @value pagedown
* @default ok
*
* @arg nameVariable
* @text ボタン名称/buttonName
* @desc ボタン名称を受け取る変数です。
* Variable to store the result.
* @type variable
* @default 0
* @command GetButtonNameEX
* @text GetButtonEX/ボタン名の取得
* @desc 指定した操作がどのボタンにあるかを返します。
* Returns which button has the specified action.
* @arg symbol
* @desc アクションのシンボル
*
* @arg nameVariable
* @desc ボタン名称を受け取る変数です。
* Variable to store the result.
* @type variable
* @default 0
*
* @command IsKeyboardValid
* @desc キーボードの設定が正しい場合、指定スイッチをONにします。
* @arg switchId
* @type switch
* @default 0
* @desc 結果を保存するスイッチ
* Where to save the results
*
* @command GamepadScene
* @text GamepadScene/ゲームパッド設定を開く
* @desc ゲームパッド設定のシーンを開きます。
* Open the gamepad settings scene.
*
* @command KeyboardScene
* @text KeyboardScene/キーボード設定を開く
* @desc キーボード設定のシーンを開きます。
* Open the keyboard settings scene.
*
* @param color
* @text 色設定/ColorSetting
* @type struct<ColorManager>
* @default {"normal":"#880000","mandatory":"#22e488","move":"#22e488"}
*
* @param basicOk
* @text 決定/ok
* @type struct<BasicSymbol>
* @default {"mandatory":"true","name":"{¥"jp¥":¥"決定¥",¥"en¥":¥"OK¥"}","keyText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}","helpText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}"}
*
* @param basicCancel
* @text 取り消し/cancle
* @type struct<BasicSymbol>
* @default {"mandatory":"true","name":"{¥"jp¥":¥"キャンセル¥",¥"en¥":¥"cancel¥"}","keyText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}","helpText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}"}
*
* @param basicShift
* @text ダッシュ/dash
* @type struct<BasicSymbol>
* @default {"mandatory":"true","name":"{¥"jp¥":¥"ダッシュ¥",¥"en¥":¥"dash¥"}","keyText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}","helpText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}"}
*
* @param basicMenu
* @text メニュー/menu
* @type struct<BasicSymbol>
* @default {"mandatory":"true","name":"{¥"jp¥":¥"メニュー¥",¥"en¥":¥"menu¥"}","keyText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}","helpText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}"}
*
* @param basicEscape
* @text メニュー(2)/menu(2)
* @type struct<BasicSymbol>
* @default {"mandatory":"true","name":"{¥"jp¥":¥"メニュー/キャンセル¥",¥"en¥":¥"menu/cancel¥"}","keyText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}","helpText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}"}
*
* @param basicPageup
* @text 次/next
* @type struct<BasicSymbol>
* @default {"mandatory":"true","name":"{¥"jp¥":¥"次¥",¥"en¥":¥"next¥"}","keyText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}","helpText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}"}
*
* @param basicPagedown
* @text 前/prev
* @type struct<BasicSymbol>
* @default {"mandatory":"true","name":"{¥"jp¥":¥"前¥",¥"en¥":¥"prev¥"}","keyText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}","helpText":"{¥"jp¥":¥"¥",¥"en¥":¥"¥"}"}
*
*
*
* @param mapperDelete
* @text 設定を消去/delete
* @type struct<MultiLangString>
* @default {"en":"delete","jp":"設定を消去"}
*
*
* @param extendsMapper
* @desc ボタンイベント・追加の入力設定の登録
* Registration of button events and additional input settings
* @text 入力拡張/inputExtension
* @type struct<InputDefine>[]
* @default []
*
* @param eventList
* @desc コモンイベントの呼び出し設定(簡単版)
* Registration of button events and additional input settings
* @text コモンイベント/CommonEvent
* @type struct<EventDefine>[]
* @default []
*
* @param GamepadIsNotConnectedText
* @text 未接続/GamepadIsNotConnected
* @desc ゲームパッドが接続されていない場合の文章です。
* This is the text when the gamepad is not connected.
* @type struct<MultiLangNote>
* @default {"jp":"¥"ゲームパッドが接続されていません¥¥nボタンを押して再度試してください¥"","en":"¥"The gamepad is not connected.¥¥nPress the button and try again.¥""}
*
* @param needButtonDetouchText
* @text ボタンから手を放すように促すメッセージ
* @desc キーコンフィグはボタンから手を離さない限り終了しません。
* 手を放すように促すメッセージを設定します。
* @type struct<MultiLangNote>
* @default {"jp":"¥"コンフィグを終了するために、¥¥nボタンから手を放してください。¥"","en":"¥"Release the button to exit the config.¥""}
*
*
*
* @param saveCommand
* @text 設定の保存/SaveSetting
* @type struct<MultiLangString>
* @default {"en":"seve setting","jp":"設定を保存"}
*
* @param saveValidTest
* @text 設定検証/Validating the Configuration
* @desc 入力設定の不備がある場合、保存を禁止。
* If the input settings are incomplete, save is prohibited.
* @type boolean
* @default true
*
* @param saveCommandWidth
* @text 幅/width
* @type number
* @default 4
* @parent saveCommand
*
* @param saveDescription
* @text 説明文/Description
* @type struct<MultiLangString>
* @default {"en":"seve setting","jp":"設定を保存"}
* @parent saveCommand
*
*
* @param resetCommand
* @type struct<MultiLangString>
* @default {"en":"reset","jp":"初期設定に戻す"}
*
* @param resetWidth
* @type number
* @default 4
* @parent resetCommand
*
* @param resetDescription
* @type struct<MultiLangString>
* @default {"en":"reset","jp":"初期設定に戻します。"}
* @parent resetCommand
*
*
* @param WASDCommand
* @type struct<MultiLangString>
* @default {"en":"WASD","jp":"WASD"}
* @param WASDwidth
* @text WASD Command Width
* @type number
* @default 3
* @parent WASDCommand
*
* @param WASDhelp
* @type struct<MultiLangString>
* @default {"en":"seve setting","jp":"WASDのキーで移動できるようにします。"}
* @parent WASDCommand
*
* @param changeKeyLayoutCommand
* @text キー配置/KeyLayout
* @type struct<MultiLangString>
* @default {"jp":"キー配置","en":"Key Layout"}
*
* @param changeKeyLayoutCommandWidth
* @type number
* @default 4
* @parent changeKeyLayoutCommand
*
*
*
* @param exitCommand
* @text やめる/exit
* @type struct<MultiLangString>
* @default {"en":"exit","jp":"やめる"}
*
* @param exitWidth
* @type number
* @default 4
* @parent exitCommand
* @param exitHelp
* @text 説明文
* @type struct<MultiLangString>
* @default {"en":"exit","jp":"変更を保存せずにやめる"}
* @parent exitCommand
*
* @param gamepadConfigCommandText
* @desc ゲームパッドコンフィグを開くコマンドの名前です
* @type struct<MultiLangString>
* @default {"en":"gamepad config","jp":"ゲームパッドコンフィグ"}
*
* @param keyConfigCommandText
* @desc キーコンフィグを開くコマンドの名前です
* @type struct<MultiLangString>
* @default {"en":"keyboard config","jp":"キーコンフィグ"}
*
* @param gamepadSceneBackground
* @type file
* @dir img/titles1/
*
* @param keySceneBackground
* @type file
* @dir img/titles1/
*
* @param SettingsForYEP_OptionsCore
* @type struct<DisguiseAsYEP>
* @default {"gamepad":"true","Keyboard":"true"}
*
* @help
* ※日本語テキストは下の方にあるのでスクロールしてください
*
* Loads the settings at game startup as initial values.
* Detects input changes regardless of where the plugin is installed.
* It is OK even if the button is modified by another plug-in.
*
* The config data set by this plug-in is recorded in the file.
* If you install a new plugin,
* Please reset the config with "Reset to default" after starting the game.
*
* ■ What to do if strange characters such as "? KEY: Symbol" are displayed
* Occurs because the input added by another plugin is unknown.
* If the above display is displayed,
* It can be handled by adding an element to extendsMapper.
* 1. Add an element
* 2. Try either of the following AB methods.
* Copy the character corresponding to A: KEY and paste it into Key Setting.
* B: Copy the characters corresponding to Symbol and paste them into symbol.
* Be careful not to confuse the case.
*
* ■ What to do if a display like unknow: XXXX appears
* The following causes are possible.
* -Symbols were set after the game started (after Scene_Boot)
* -Initialization process was not performed correctly
* It may be improved by moving this plugin down.
*
* ■ Button operation diffusion function
* If the operation is set by another plugin,
* May be set on only one of the gamepad / keyboard.
* In such a case, you can operate it from others by setting it in extendsMapper.
* For example, suppose that the operation is set when you press only T on the keyboard.
* If you want to set the operation for the buttons on the gamepad in this state, set as follows.
* Key setting: T
* Pad button: (any button number)
* By doing this, this plugin will read the behavior set for T on the keyboard and
* Set so that the same function can be used with the buttons on the gamepad.
* The same is true for the opposite.
*
* If the operation is set on both the keyboard and the gamepad,
* Determine which one to prioritize in the overwrite setting.
* When using manual symbol settings (for advanced users)
* Ignore the priority settings and use the contents set manually.
*
* ■ Common event call button
* extendsMapper has an item called "Events".
* If you set an event here, the event will be called when the button is pressed.
* You can use it to create a function to open the map when you press the button.
*
* ■All functions can be used without eval ()
* There are no items in this plugin that use eval ().
* If you're writing a JavaScript expression for use with eval (),
* you're wrong.
*
* ■ If you want to control the transition with a script
* Used when modifying other plugins or switching scenes directly with a script.
* SceneManager.push (Mano_InputConfig.Scene_GamepadConfig); // Gamepad Config
* SceneManager.push (Mano_InputConfig.Scene_KeyConfig); // Keyboard config
* You can now move to the specified scene.