mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-01-17 12:35:26 +00:00
About The Pull Request
This PR removes intents and replaces them with a combat mode. An explanation of what this means can be found below
Major changes:
Disarm and Grab intents have been removed.
Harm/Help is now combat mode, toggled by F or 4 by default
The context/verb/popup menu now only works when you do shift+right-click
Right click is now disarm, both in and out of combat mode.
Grabbing is now on ctrl-click.
If you're in combat mode, and are currently grabbing/pulling someone, and ctrl-click somewhere else, it will not release the grab (To prevent misclicks)
Minor interaction changes:
Right click to dissasemble tables, racks, filing cabinets (When holding the right tool to do so)
Left click to stunbaton, right click to harmbaton
Right click to tip cows
Right click to malpractice surgery
Right click to hold people at gunpoint (if youre holding a gun)
Why It's Good For The Game
Intents heavily cripple both the code and the UI design of interactions. While I understand that a lot of people will dislike this PR as they are used to intents, they are one of our weakest links in terms of explaining to players how to do specific things, and require a lot more keypresses to do compared to this.
As an example, martial arts can now be done without having to juggle 1 2 3 and 4 to switch intents quickly.
As some of you who saw the first combat mode PR, the context menu used to be disabled in combat mode. In this version it is instead on shift-right click ensuring that you can always use it in the same way.
In this version, combat mode also no longer prevents you from attacking with items when you would so before, as this was something that was commonly complained about.
The full intention of this shift in control scheme is that right click will become "secondary interaction" for items, which prevents some of the awkward juggling we have now with item modes etcetera.
Changelog
cl Qustinnus
add: Intents have been replaced with a combat mode. For more info find the PR here: #56601
/cl
253 lines
6.8 KiB
Plaintext
253 lines
6.8 KiB
Plaintext
/datum/keybinding/mob
|
|
category = CATEGORY_HUMAN
|
|
weight = WEIGHT_MOB
|
|
|
|
/datum/keybinding/mob/stop_pulling
|
|
hotkey_keys = list("H", "Delete")
|
|
name = "stop_pulling"
|
|
full_name = "Stop pulling"
|
|
description = ""
|
|
keybind_signal = COMSIG_KB_MOB_STOPPULLING_DOWN
|
|
|
|
/datum/keybinding/mob/stop_pulling/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
var/mob/M = user.mob
|
|
if(!M.pulling)
|
|
to_chat(user, "<span class='notice'>You are not pulling anything.</span>")
|
|
else
|
|
M.stop_pulling()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/swap_hands
|
|
hotkey_keys = list("X", "Northeast") // PAGEUP
|
|
name = "swap_hands"
|
|
full_name = "Swap hands"
|
|
description = ""
|
|
keybind_signal = COMSIG_KB_MOB_SWAPHANDS_DOWN
|
|
|
|
/datum/keybinding/mob/swap_hands/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
var/mob/M = user.mob
|
|
M.swap_hand()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/activate_inhand
|
|
hotkey_keys = list("Z", "Southeast") // Southeast = PAGEDOWN
|
|
name = "activate_inhand"
|
|
full_name = "Activate in-hand"
|
|
description = "Uses whatever item you have inhand"
|
|
keybind_signal = COMSIG_KB_MOB_ACTIVATEINHAND_DOWN
|
|
|
|
/datum/keybinding/mob/activate_inhand/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
var/mob/M = user.mob
|
|
M.mode()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/drop_item
|
|
hotkey_keys = list("Q")
|
|
name = "drop_item"
|
|
full_name = "Drop Item"
|
|
description = ""
|
|
keybind_signal = COMSIG_KB_MOB_DROPITEM_DOWN
|
|
|
|
/datum/keybinding/mob/drop_item/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
if(iscyborg(user.mob)) //cyborgs can't drop items
|
|
return FALSE
|
|
var/mob/M = user.mob
|
|
var/obj/item/I = M.get_active_held_item()
|
|
if(!I)
|
|
to_chat(user, "<span class='warning'>You have nothing to drop in your hand!</span>")
|
|
else
|
|
user.mob.dropItemToGround(I)
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/toggle_move_intent
|
|
hotkey_keys = list("C")
|
|
name = "toggle_move_intent"
|
|
full_name = "Hold to toggle move intent"
|
|
description = "Held down to cycle to the other move intent, release to cycle back"
|
|
keybind_signal = COMSIG_KB_MOB_TOGGLEMOVEINTENT_DOWN
|
|
|
|
/datum/keybinding/mob/toggle_move_intent/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
var/mob/M = user.mob
|
|
M.toggle_move_intent()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/toggle_move_intent/up(client/user)
|
|
var/mob/M = user.mob
|
|
M.toggle_move_intent()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/toggle_move_intent_alternative
|
|
hotkey_keys = list("Unbound")
|
|
name = "toggle_move_intent_alt"
|
|
full_name = "press to cycle move intent"
|
|
description = "Pressing this cycle to the opposite move intent, does not cycle back"
|
|
keybind_signal = COMSIG_KB_MOB_TOGGLEMOVEINTENTALT_DOWN
|
|
|
|
/datum/keybinding/mob/toggle_move_intent_alternative/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
var/mob/M = user.mob
|
|
M.toggle_move_intent()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/target_head_cycle
|
|
hotkey_keys = list("Numpad8")
|
|
name = "target_head_cycle"
|
|
full_name = "Target: Cycle Head"
|
|
description = "Pressing this key targets the head, and continued presses will cycle to the eyes and mouth. This will impact where you hit people, and can be used for surgery."
|
|
keybind_signal = COMSIG_KB_MOB_TARGETCYCLEHEAD_DOWN
|
|
|
|
/datum/keybinding/mob/target_head_cycle/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.body_toggle_head()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/target_eyes
|
|
hotkey_keys = list("Numpad7")
|
|
name = "target_eyes"
|
|
full_name = "Target: Eyes"
|
|
description = "Pressing this key targets the eyes. This will impact where you hit people, and can be used for surgery."
|
|
keybind_signal = COMSIG_KB_MOB_TARGETEYES_DOWN
|
|
|
|
/datum/keybinding/mob/target_eyes/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.body_eyes()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/target_mouth
|
|
hotkey_keys = list("Numpad9")
|
|
name = "target_mouths"
|
|
full_name = "Target: Mouth"
|
|
description = "Pressing this key targets the mouth. This will impact where you hit people, and can be used for surgery."
|
|
keybind_signal = COMSIG_KB_MOB_TARGETMOUTH_DOWN
|
|
|
|
/datum/keybinding/mob/target_mouth/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.body_mouth()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/target_r_arm
|
|
hotkey_keys = list("Numpad4")
|
|
name = "target_r_arm"
|
|
full_name = "Target: right arm"
|
|
description = "Pressing this key targets the right arm. This will impact where you hit people, and can be used for surgery."
|
|
keybind_signal = COMSIG_KB_MOB_TARGETRIGHTARM_DOWN
|
|
|
|
/datum/keybinding/mob/target_r_arm/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.body_r_arm()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/target_body_chest
|
|
hotkey_keys = list("Numpad5")
|
|
name = "target_body_chest"
|
|
full_name = "Target: Body"
|
|
description = "Pressing this key targets the body. This will impact where you hit people, and can be used for surgery."
|
|
keybind_signal = COMSIG_KB_MOB_TARGETBODYCHEST_DOWN
|
|
|
|
/datum/keybinding/mob/target_body_chest/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.body_chest()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/target_left_arm
|
|
hotkey_keys = list("Numpad6")
|
|
name = "target_left_arm"
|
|
full_name = "Target: left arm"
|
|
description = "Pressing this key targets the body. This will impact where you hit people, and can be used for surgery."
|
|
keybind_signal = COMSIG_KB_MOB_TARGETLEFTARM_DOWN
|
|
|
|
/datum/keybinding/mob/target_left_arm/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.body_l_arm()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/target_right_leg
|
|
hotkey_keys = list("Numpad1")
|
|
name = "target_right_leg"
|
|
full_name = "Target: Right leg"
|
|
description = "Pressing this key targets the right leg. This will impact where you hit people, and can be used for surgery."
|
|
keybind_signal = COMSIG_KB_MOB_TARGETRIGHTLEG_DOWN
|
|
|
|
/datum/keybinding/mob/target_right_leg/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.body_r_leg()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/target_body_groin
|
|
hotkey_keys = list("Numpad2")
|
|
name = "target_body_groin"
|
|
full_name = "Target: Groin"
|
|
description = "Pressing this key targets the groin. This will impact where you hit people, and can be used for surgery."
|
|
keybind_signal = COMSIG_KB_MOB_TARGETBODYGROIN_DOWN
|
|
|
|
/datum/keybinding/mob/target_body_groin/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.body_groin()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/target_left_leg
|
|
hotkey_keys = list("Numpad3")
|
|
name = "target_left_leg"
|
|
full_name = "Target: left leg"
|
|
description = "Pressing this key targets the left leg. This will impact where you hit people, and can be used for surgery."
|
|
keybind_signal = COMSIG_KB_MOB_TARGETLEFTLEG_DOWN
|
|
|
|
/datum/keybinding/mob/target_left_leg/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.body_l_leg()
|
|
return TRUE
|
|
|
|
/datum/keybinding/mob/prevent_movement
|
|
hotkey_keys = list("Alt")
|
|
name = "block_movement"
|
|
full_name = "Block movement"
|
|
description = "Prevents you from moving"
|
|
keybind_signal = COMSIG_KB_MOB_BLOCKMOVEMENT_DOWN
|
|
|
|
/datum/keybinding/mob/prevent_movement/down(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.movement_locked = TRUE
|
|
|
|
/datum/keybinding/mob/prevent_movement/up(client/user)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
user.movement_locked = FALSE
|