Bit of help with the keyMapper

Im trying to add a couple of keys to my project.

I opened rpg_core.js, found Input.keyMapper, and added...

65: 'action',   // A80: 'x',         // X90: 'z',         // ZI tried using them in conditional branch and got nothing.

Input.isTriggered('action')I searched it in the forum and found the plugin request, but no specific instructions.

As far as I know I just needed add the key code and string value. any ideas as to what Im doing wrong?

em.png

Em1.png
Well what keys are you trying to add in? because from your list, assuming the comment part is the keyboard button, only 65: 'action' and 90: 'z' are correct. key code 80 is the p key not x.

Other then that it looks ok, so how is your event setup? if its not parallel it wont run.

My test:

Added this in a js

Input.keyMapper[121] = 'F10';Event page

http://i.imgur.com/X3zNakU.png
Also consider that the codes for x and X are not the same.  I suspect you'll have to put both in, if you want it to be case-insensitive.

88 (X) is already listed as 'escape', so you should be able to use 'escape' to detect X.  But that will also detect the real escape key.
Input.keyMapper[121] = 'F10';Had no idea I could add a key this way. Thanks 🙂

I actually meant to take the X out, it occurred to me I had that wrong when I found the Adobe page with the keyboard value.

Original thread: https://forums.rpgmakerweb.com/threads/bit-of-help-with-the-keymapper.50993/