MV Check for keyboard input for specific button (D on keyboard)

Hey everyone, In MV: I want to add a conditional branch that checks if a button is pressed. I have this working for enter with the following code: (Input.isPressed('ok'))

However, I want it to work for the D button on the keyboard but this doesn't work. I tried adding the button in rpg_core.js with:

Code:
  68: 'D',        // D

But doesn't seem to help. I did that based on this thread: https://forums.rpgmakerweb.com/index.php?threads/check-for-keyboard-input.105126/

So... How do I make this work for the D button?
That looks OK to me. Maybe you added the keyMapper entry in the wrong place?
  1. Add key code 68 (D) to the keymapper on game boot, e.g. load this code as a plugin:
    JavaScript:
    Input.keyMapper[68] = 'D';
  2. Then check if the button is pressed, e.g. using Conditional Branch > Script:
    JavaScript:
    Input.isPressed('D');
Test in a new project first, otherwise active plugins or core script edits may interfere. If it works there (it should) but not in your current project, then it's probably due to your plugins and/or core script edits.
@caethyril Thanks for your input. Now i'm pretty sure the issue is an interfering plugin. I'm looking for a different solution now (it's part of a puzzle).
I see! I guess a plugin is assigning a different name to key code 68?

Only the most recent key name will be used, so this can vary depending on your plugin load order. Simply replacing the key name with D will probably break the other plugin(s), though...

If you press F8 during test play, the console window should appear. Type this in and press Enter:
JavaScript:
Input.keyMapper[68]
This returns the game's name for key code 68. Use this name in your isPressed check! 😤

If it returns undefined, that indicates that the button has not been assigned a value (or some code somewhere has, for some reason, deleted that value).

Original thread: https://forums.rpgmakerweb.com/threads/check-for-keyboard-input-for-specific-button-d-on-keyboard.138370/