mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-13 11:12:14 +00:00
## About The Pull Request Semi WIP cus I need to probably make an issue report for lummox, but apart from that ready for review Uses the new mouse-pos so we can combine it with screen size and size to estimate very accurately the mouse position in turf terms. In future also will need to add a way to continously poll the users mouse pos but this alone is very useful ## Why It's Good For The Game This isnt used yet, but the benefits are pretty damn obvious (hitting E and dashing towards where your mouse??? 1990s features?????) ## Changelog 🆑 refactor: Added the possibility for keybindings to report the turf they clicked on. /🆑 --------- Co-authored-by: TiviPlus <572233640+TiviPlus@users.noreply.com>
59 lines
1.7 KiB
Plaintext
59 lines
1.7 KiB
Plaintext
/datum/keybinding/client/communication
|
|
category = CATEGORY_COMMUNICATION
|
|
|
|
/datum/keybinding/client/communication/say
|
|
hotkey_keys = list("T")
|
|
name = SAY_CHANNEL
|
|
full_name = "IC Say"
|
|
keybind_signal = COMSIG_KB_CLIENT_SAY_DOWN
|
|
|
|
/datum/keybinding/client/communication/say/down(client/user, turf/target)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
winset(user, null, "command=[user.tgui_say_create_open_command(SAY_CHANNEL)];")
|
|
winset(user, "tgui_say.browser", "focus=true")
|
|
return TRUE
|
|
|
|
/datum/keybinding/client/communication/radio
|
|
hotkey_keys = list("Y")
|
|
name = RADIO_CHANNEL
|
|
full_name = "IC Radio (;)"
|
|
keybind_signal = COMSIG_KB_CLIENT_RADIO_DOWN
|
|
|
|
/datum/keybinding/client/communication/radio/down(client/user, turf/target)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
winset(user, null, "command=[user.tgui_say_create_open_command(RADIO_CHANNEL)]")
|
|
winset(user, "tgui_say.browser", "focus=true")
|
|
return TRUE
|
|
|
|
/datum/keybinding/client/communication/ooc
|
|
hotkey_keys = list("O")
|
|
name = OOC_CHANNEL
|
|
full_name = "Out Of Character Say (OOC)"
|
|
keybind_signal = COMSIG_KB_CLIENT_OOC_DOWN
|
|
|
|
/datum/keybinding/client/communication/ooc/down(client/user, turf/target)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
winset(user, null, "command=[user.tgui_say_create_open_command(OOC_CHANNEL)]")
|
|
winset(user, "tgui_say.browser", "focus=true")
|
|
return TRUE
|
|
|
|
/datum/keybinding/client/communication/me
|
|
hotkey_keys = list("M")
|
|
name = ME_CHANNEL
|
|
full_name = "Custom Emote (/Me)"
|
|
keybind_signal = COMSIG_KB_CLIENT_ME_DOWN
|
|
|
|
/datum/keybinding/client/communication/me/down(client/user, turf/target)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
winset(user, null, "command=[user.tgui_say_create_open_command(ME_CHANNEL)]")
|
|
winset(user, "tgui_say.browser", "focus=true")
|
|
return TRUE
|