But I think it is quite an effort to implement it properly.
Yeah, it can be a bit of a pain to have keys be fully configurable. An easy compromise might be to have a set of keysets you choose from at the start of the game, and then you just read those to get the key you want. So, instead of doing something like:
// Checking for moving left: if (event.keyCode == ROT.VK_NUMPAD4) { move( -1, 0 ); }
...in your code, you would instead do something like:
// Somewhere during startup: var numpadKeySet = { keySetName: "Numeric Pad Keys", left: ROT.VK_NUMPAD4 }; var arrowKeysKeySet = { keySetName: "Arrow Keys", left: ROT.VK_LEFT }; // When the user selects a keyset: var currentKeySet = arrowKeysKeySet; // Checking for moving left: if (event.keyCode == currentKeySet.left) { move( -1, 0 ); }
Then, you could set a different keySet depending on the type of key bindings you want, and the behavior is abstracted away. Later, you could have a functionality that would let players define a custom keySet.
Do you know if the rules of the 7DRL-Challenge allow me to update my game by additional controls after the deadline?
There's another thread in the 7DRL forums about this you can read for more detail, but the short version is that it's okay to update the game as long as it's clear and feasible how the 7DRL reviewers can play the end-of-compo release version. So you could update it, but be sure to leave the original release version up and clearly marked for reviewers.