[SOLVED] Separate :B keys

Hi!

I'm developing my first game and I have a problem. I need to separate the keys associated to the symbol ":B" (Esc, Num(0) and X) for them to do different stuff, but I have no idea about how to do it.

Does someone can help me?

Thanks in advance! 🙂
Start the game -> Press F1.

There is a button setting tab.
Thanks Death10, I already knew about that method.

The problem is that those changes affect to every VX Ace game and not only to my current project. 🙁
Try out this script.

http://cobbtocs.co.uk/wp/?p=387

Give the instructions a look and see if they can do what you need them to.
Thanks VegaKotes, but that script is useless for me. 🙁

That script allows you to use more keys from the keyboard but I don't want that. I need the following:

- Esc -> Call Scene_A

- Num(0) -> Call Scene_B

- X -> Do nothing

The problem is that all those keys are binded to symbol ":B" so all of them do the same.
Here's what you do.

Firstly have an event turn on a switch and disable menu access.

Put the following into a Common Event, and make sure that it's set to Parallel Process and that you're activating the switch it needs.

Conditional Branch (Condition is script)

---Keyboard.trigger?(0x1B) (This is Esc as defined in the script)

do Call Scene_A

Conditional Branch (Condition is script again)

---Keyboard.trigger?(0x30) (This is Num0 as defined in the script)

do Call Scene_B

Conditional Branch (Same as above)

---Keyboard.trigger?(0x58) (This is X as defined in the script)

do blank

If you do that X, 0, and Esc will still use the "Cancel" input but so long as you aren't using a cancel input they'll each do different things.

Aka, if you're in a shop, hitting any of the 3 will still cancel.

And probably run their event anyway...

Hmm, that could be a problem.

Let me know if it is.
edited.
Thank you very much VegaKotes ^^

I'm afraid I have the problem you mentioned. Inside the menu, I need the following:

- Esc -> Cancel

- Num(0) -> Custom Function

So the Common Event method won't work. 🙁

EDIT!

What about something like this? :distrust:

Code:
#==============================================================================# ** Window_Selectable#------------------------------------------------------------------------------# This window class contains cursor movement and scroll functions.#==============================================================================class Window_Selectable < Window_Base#--------------------------------------------------------------------------# * Handling Processing for OK and Cancel Etc.#--------------------------------------------------------------------------  def process_handling    return unless open? && active    return process_ok if ok_enabled? && Keyboard.trigger?(0x0D)    return process_cancel if cancel_enabled? && Keyboard.trigger?(0x1B)    return process_pagedown if handle?(:pagedown) && Input.trigger?(:R)    return process_pageup if handle?(:pageup) && Input.trigger?(:L)  endend
TOPIC SOLVED!!

Thank you very much, people! 🙂

P.S: For those who want to do the same, the way is:

#-------------------------------------------------------------------------- # * Handling Processing for OK and Cancel Etc. #-------------------------------------------------------------------------- def process_handling return unless open? && active return process_ok if(ok_enabled? && Input.trigger?🙂C) && Keyboard.press?(Keyboard::VK_RETURN)) return process_cancel if(cancel_enabled? && Input.trigger?🙂 && !Keyboard.press?(Keyboard::VK_KEYX)) return process_pagedown if handle?🙂pagedown) && Input.trigger?🙂R) return process_pageup if handle?🙂pageup) && Input.trigger?🙂L) endRegards! 😉

Original thread: https://forums.rpgmakerweb.com/threads/solved-separate-b-keys.15044/