From 2f1a76c21e8f87745095ab29aa03b5af2144d2d4 Mon Sep 17 00:00:00 2001 From: Ghommie <42542238+Ghommie@users.noreply.github.com> Date: Wed, 13 Nov 2019 23:57:49 +0100 Subject: [PATCH] Unmodularize keybindings. --- code/modules/keybindings/bindings_carbon.dm | 3 +++ code/modules/keybindings/bindings_human.dm | 12 +++++++++++- code/modules/keybindings/bindings_robot.dm | 12 +++++++++++- .../code/modules/keybindings/bindings_carbon.dm | 6 ------ .../code/modules/keybindings/bindings_human.dm | 13 ------------- .../code/modules/keybindings/bindings_robot.dm | 13 ------------- tgstation.dme | 3 --- 7 files changed, 25 insertions(+), 37 deletions(-) delete mode 100644 modular_citadel/code/modules/keybindings/bindings_carbon.dm delete mode 100644 modular_citadel/code/modules/keybindings/bindings_human.dm delete mode 100644 modular_citadel/code/modules/keybindings/bindings_robot.dm diff --git a/code/modules/keybindings/bindings_carbon.dm b/code/modules/keybindings/bindings_carbon.dm index d17f10e963..a982273c86 100644 --- a/code/modules/keybindings/bindings_carbon.dm +++ b/code/modules/keybindings/bindings_carbon.dm @@ -15,4 +15,7 @@ if("4") a_intent_change("harm") return + if("C") + toggle_combat_mode() + return return ..() \ No newline at end of file diff --git a/code/modules/keybindings/bindings_human.dm b/code/modules/keybindings/bindings_human.dm index 5d02d9aedb..38870c3840 100644 --- a/code/modules/keybindings/bindings_human.dm +++ b/code/modules/keybindings/bindings_human.dm @@ -1,4 +1,7 @@ /mob/living/carbon/human/key_down(_key, client/user) + if("Shift") + sprint_hotkey(TRUE) + return if(client.keys_held["Shift"]) switch(_key) if("E") // Put held thing in belt or take out most recent thing from belt @@ -56,4 +59,11 @@ return stored.attack_hand(src) // take out thing from backpack return - return ..() \ No newline at end of file + return ..() + +/mob/living/carbon/human/key_up(_key, client/user) + switch(_key) + if("Shift") + sprint_hotkey(FALSE) + return + return ..() diff --git a/code/modules/keybindings/bindings_robot.dm b/code/modules/keybindings/bindings_robot.dm index 2354f33c9e..29fb36fa65 100644 --- a/code/modules/keybindings/bindings_robot.dm +++ b/code/modules/keybindings/bindings_robot.dm @@ -9,4 +9,14 @@ if("Q") uneq_active() return - return ..() \ No newline at end of file + if("Shift") + sprint_hotkey(TRUE) + return + return ..() + +/mob/living/silicon/robot/key_up(_key, client/user) + switch(_key) + if("Shift") + sprint_hotkey(FALSE) + return + return ..() diff --git a/modular_citadel/code/modules/keybindings/bindings_carbon.dm b/modular_citadel/code/modules/keybindings/bindings_carbon.dm deleted file mode 100644 index d49cbcf452..0000000000 --- a/modular_citadel/code/modules/keybindings/bindings_carbon.dm +++ /dev/null @@ -1,6 +0,0 @@ -/mob/living/carbon/key_down(_key, client/user) - switch(_key) - if("C") - toggle_combat_mode() - return - return ..() diff --git a/modular_citadel/code/modules/keybindings/bindings_human.dm b/modular_citadel/code/modules/keybindings/bindings_human.dm deleted file mode 100644 index ffe88bd4a9..0000000000 --- a/modular_citadel/code/modules/keybindings/bindings_human.dm +++ /dev/null @@ -1,13 +0,0 @@ -/mob/living/carbon/human/key_down(_key, client/user) - switch(_key) - if("Shift") - sprint_hotkey(TRUE) - return - return ..() - -/mob/living/carbon/human/key_up(_key, client/user) - switch(_key) - if("Shift") - sprint_hotkey(FALSE) - return - return ..() diff --git a/modular_citadel/code/modules/keybindings/bindings_robot.dm b/modular_citadel/code/modules/keybindings/bindings_robot.dm deleted file mode 100644 index d3b6248f7d..0000000000 --- a/modular_citadel/code/modules/keybindings/bindings_robot.dm +++ /dev/null @@ -1,13 +0,0 @@ -/mob/living/silicon/robot/key_down(_key, client/user) - switch(_key) - if("Shift") - sprint_hotkey(TRUE) - return - return ..() - -/mob/living/silicon/robot/key_up(_key, client/user) - switch(_key) - if("Shift") - sprint_hotkey(FALSE) - return - return ..() diff --git a/tgstation.dme b/tgstation.dme index 9e52889df7..8c57babc01 100755 --- a/tgstation.dme +++ b/tgstation.dme @@ -3077,9 +3077,6 @@ #include "modular_citadel\code\modules\custom_loadout\read_from_file.dm" #include "modular_citadel\code\modules\food_and_drinks\snacks\meat.dm" #include "modular_citadel\code\modules\integrated_electronics\subtypes\manipulation.dm" -#include "modular_citadel\code\modules\keybindings\bindings_carbon.dm" -#include "modular_citadel\code\modules\keybindings\bindings_human.dm" -#include "modular_citadel\code\modules\keybindings\bindings_robot.dm" #include "modular_citadel\code\modules\mentor\follow.dm" #include "modular_citadel\code\modules\mentor\mentor.dm" #include "modular_citadel\code\modules\mentor\mentor_memo.dm"