mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-17 18:13:34 +01:00
makes action buttons bindable to keybinds (#22390)
* makes action buttons bindable to keybinds * i'm just based like that * zamn * fix * More alterations * bruh * runtime fix * fixed up the jank * Update code/_onclick/hud/action_button.dm Co-authored-by: Gaxeer <44334376+Gaxeer@users.noreply.github.com> * Update code/modules/input/keybindings_procs.dm --------- Co-authored-by: Gaxeer <44334376+Gaxeer@users.noreply.github.com>
This commit is contained in:
@@ -12,5 +12,11 @@
|
||||
movement_kb_dirs[key] = KBM.move_dir
|
||||
else
|
||||
active_keybindings[key] += list(KB)
|
||||
if(!mob) // Clients can join before world/new is setup, so we gotta mob check em
|
||||
return active_keybindings
|
||||
for(var/datum/action/action as anything in mob.actions)
|
||||
if(action.button?.linked_keybind?.binded_to)
|
||||
var/datum/keybinding/mob/trigger_action_button/linked_bind = action.button.linked_keybind
|
||||
active_keybindings[linked_bind.binded_to] += list(linked_bind)
|
||||
|
||||
return active_keybindings
|
||||
|
||||
Reference in New Issue
Block a user