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>
19 lines
498 B
Plaintext
19 lines
498 B
Plaintext
/datum/keybinding/emote
|
|
category = CATEGORY_EMOTE
|
|
weight = WEIGHT_EMOTE
|
|
keybind_signal = COMSIG_KB_EMOTE
|
|
var/emote_key
|
|
|
|
/datum/keybinding/emote/proc/link_to_emote(datum/emote/faketype)
|
|
hotkey_keys = list("Unbound")
|
|
classic_keys = list("Unbound")
|
|
emote_key = initial(faketype.key)
|
|
name = initial(faketype.key)
|
|
full_name = capitalize(initial(faketype.key))
|
|
|
|
/datum/keybinding/emote/down(client/user, turf/target)
|
|
. = ..()
|
|
if(.)
|
|
return
|
|
return user.mob.emote(emote_key, intentional=TRUE)
|