An open library of RPG Maker MZ plugins, powered by the community.

PGMZ - The Community-Driven Plugin Library for RPG Maker MZ

MZ plugins

Dark Plasma Custom Key Handler - DarkPlasma_CustomKeyHandler.js

Plugin desc : Adding custom keys to a window's handler

License : MIT License

Author : DarkPlasma

Website : https://github.com/munokura/DarkPlasma-MZ-Plugins/blob/main/DarkPlasma_CustomKeyHandler.js

Desc page : https://github.com/elleonard/DarkPlasma-MZ-Plugins/tree/release

Download Page : https://raw.githubusercontent.com/munokura/DarkPlasma-MZ-Plugins/main/DarkPlasma_CustomKeyHandler.js

File name : DarkPlasma_CustomKeyHandler.js

Help of plugin :

@target MZ
@url https://github.com/elleonard/DarkPlasma-MZ-Plugins/tree/release
@plugindesc Adding custom keys to a window's handler
@author DarkPlasma
@license MIT

@help
English Help Translator: munokura
This is an unofficial English translation of the plugin help,
created to support global RPG Maker users.
Feedback is welcome to improve translation quality
(see: https://github.com/munokura/DarkPlasma-MZ-Plugins ).
Original plugin by DarkPlasma.
Please check the latest official version at:
https://github.com/elleonard/DarkPlasma-MZ-Plugins/tree/release
-----

version: 1.3.0
Allows you to add a handler for pressing keys such as "shift."

This plugin does not function on its own.
Please use it together with another plugin that requires it.

The following is for plugin developers.
(Example) Add a shift key handler to all selectable windows with the handler
name "hoge":
Window_CustomKeyHandlerMixIn("shift", Window_Selectable.prototype, "hoge");
If the handler name is omitted, it will be the same as the key name.
By adding a handler to this window using, for example,
window.setHandler("hoge", method), you can make the shift key perform that
operation.

To check the enabled status of a key,
hook the isCustomKeyEnabled method of the target window class and
write a conditional expression to evaluate when the key is "hoge."

To change the operation sound,
define the customKeySound method of the target window class and
return an object of type MZ.AudioFile.

スポンサードリンク

-MZ plugins

Copyright© PGMZ - The Community-Driven Plugin Library for RPG Maker MZ , 2026 All Rights Reserved.