diff --git a/scripts/server/keybind.js b/scripts/server/keybind.js index e445efbe..aa13505f 100644 --- a/scripts/server/keybind.js +++ b/scripts/server/keybind.js @@ -130,6 +130,7 @@ let bindableKeys = { function initKeyBindScript() { logToConsole(LOG_DEBUG, "[Asshat.KeyBind]: Initializing key bind script ..."); + getServerConfig().keyBind = loadKeyBindConfiguration(); logToConsole(LOG_DEBUG, "[Asshat.KeyBind]: Key bind script initialized!"); } @@ -306,4 +307,11 @@ function getKeyIdFromParams(params) { } } +// =========================================================================== + +function loadKeyBindConfiguration() { + let keyBindConfigFile = loadTextFile("config/keybind.json"); + return JSON.parse(keyBindConfigFile); +} + // =========================================================================== \ No newline at end of file