Ver código fonte

Update client.tscript

Added execution of keybinds script, if generated by UI module
Sir-Skurpsalot 1 mês atrás
pai
commit
7b81f5de44

+ 5 - 1
Templates/BaseGame/game/core/clientServer/scripts/client/client.tscript

@@ -22,8 +22,12 @@ function initClient()
       
    moduleExec("initClient");
 
+   //keybinds stores user custom keybinds generated by the UI module (if installed), this should be the only place this is executed
+   if(isScriptFile(%prefPath @ "/keybinds." @ $TorqueScriptFileExtension)) 
+      exec(%prefPath @ "/keybinds." @ $TorqueScriptFileExtension);
+
    // Copy saved script prefs into C++ code.
    setDefaultFov( $pref::Player::defaultFov );
    setZoomSpeed( $pref::Player::zoomSpeed );
    loadModuleMaterials();
-}
+}