Q:

Making Keys Pass Completely Through Emacs

An Autohotkey remapping script I'm using uses the function keys F13-F24 to keep track of layers. This means that {F13 Down}, for example, may get sent as a virtual key code.
This works fine for most applications. However, Emacs recognizes the function keys and does not pass them through (even though they don't exist on my keyboard and I can't activate them external to Autohotkey). This is causing unwanted behavior when I switch layers.
I can make the "key undefined" messages go away by using
(global-set-key [f13] 'ignore)
(global-set-key [f14] 'ignore)
...

However, Emacs still registers the keys, and they will stop sequences for commands. For example, in Spacemacs one switches windows using Spc 0-9. To access the numbers, I press a key that sends {F13 down}, then press a letter key. Rather than Spacemacs interpreting this as Spc #, a message prints saying that Spc <f13> is undefined. Even though they are nil, Emacs still "recognizes" them.
What I would like to do would be to have Emacs completely ignore the F13-F24 keys. That is, if Emacs receives a keycode corresponding to some key from F13-F24, it doesn't even register it, but ignores it as if it had not been pressed.
I tried using
(define-key input-decode-map (kbd "<f13>") nil)
(define-key input-decode-map (kbd "<f14>") nil)
...

in my config file, but the keys still register. According to my understanding of Translation Keymaps, I thought this would work. I'm at a bit of a loss now as to how I might go about disabling these keys.
Help?

Edit: I have solved the issue on the Autohotkey end of things. Instead of using F13-F24 for keeping track of layers, I'm using unassigned virtual key codes. (See this thread). It's a bit harder to maintain, but there is no interference with Emacs.
I've gone ahead and accepted @Gilles' answer since it mostly worked on the Emacs side of things. There were intermittent problems with auxiliary modes/maps getting activated that I was never able to pinpoint. I seemed to only have problems switching windows with Spc <f13> <letter> = Spc # when I was going from window to window with no keypresses in between. If I pressed Esc every time I arrived at a window before using Spc # to go to a different one, everything worked fine.
I'm pretty new to programming in general and Emacs in particular, so someone more knowledgeable might be able to actually create full pass through on the Emacs side of things. Here's some links that looked like they would be useful if I knew what I was doing:

Keymap priority
Using an overriding minor mode or use-package bind*

A:

nil in input-decode-map (or any of the other translation maps) means “don't translate this key”, not “translate this key to an empty sequence”. Use an empty vector instead.
(define-key input-decode-map [f13] [])

This will effectively make Emacs ignore the key in most circumstances. For example, f13 won't interrupt a multi-key binding or a prefix argument. Some modes do read events at a lower level and will treat the key as undefined, for example f13 still interrupts incremental search or anything else that uses overriding-terminal-local-map. I don't know how Spacemacs will treat it.
I'm not sure whether that solves your actual problem, because I don't understand what you're trying to do from your question. If Emacs is doing something that prevents Autohotkey from seeing an event, this has to do with how the two programs process input events and cannot be solved through keymaps in Emacs.

