mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-17 18:13:34 +01:00
SQL entry for hotkey mode
This commit is contained in:
@@ -55,7 +55,7 @@
|
||||
ooccolor = sanitize_hexcolor(ooccolor, initial(ooccolor))
|
||||
UI_style = sanitize_inlist(UI_style, list("White", "Midnight"), initial(UI_style))
|
||||
default_slot = sanitize_integer(default_slot, 1, max_save_slots, initial(default_slot))
|
||||
toggles = sanitize_integer(toggles, 0, 2097151, initial(toggles))
|
||||
toggles = sanitize_integer(toggles, 0, 4194304, initial(toggles))
|
||||
sound = sanitize_integer(sound, 0, 65535, initial(sound))
|
||||
UI_style_color = sanitize_hexcolor(UI_style_color, initial(UI_style_color))
|
||||
UI_style_alpha = sanitize_integer(UI_style_alpha, 0, 255, initial(UI_style_alpha))
|
||||
|
||||
@@ -243,3 +243,11 @@
|
||||
else
|
||||
to_chat(usr, "<span class='notice'>You have disabled text popup limiting.")
|
||||
return
|
||||
/client/verb/togglehotkeys()
|
||||
set name = "Toggle Hotkey Mode"
|
||||
set category = "Preferences"
|
||||
set desc = "Toggles Hotkey Mode"
|
||||
prefs.toggles ^= HOTKEYS
|
||||
prefs.save_preferences(src)
|
||||
to_chat(src, "You will [(prefs.toggles & HOTKEYS) ? "no longer" : "now"] use hotkey mode.")
|
||||
feedback_add_details("admin_verb","HOTKEYS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
/client/verb/keyDown(_key as text)
|
||||
set instant = TRUE
|
||||
set hidden = TRUE
|
||||
|
||||
to_chat(src,"You pressed:", _key)
|
||||
keys_held[_key] = world.time
|
||||
var/movement = SSinput.movement_keys[_key]
|
||||
if(!(next_move_dir_sub & movement) && !keys_held["Ctrl"])
|
||||
@@ -34,7 +34,7 @@
|
||||
/client/verb/keyUp(_key as text)
|
||||
set instant = TRUE
|
||||
set hidden = TRUE
|
||||
|
||||
to_chat(src, "You released:", _key)
|
||||
keys_held -= _key
|
||||
var/movement = SSinput.movement_keys[_key]
|
||||
if(!(next_move_dir_add & movement))
|
||||
|
||||
@@ -46,5 +46,7 @@
|
||||
|
||||
if(prefs.toggles & HOTKEYS)
|
||||
winset(src, null, "input.focus=true input.background-color=[COLOR_INPUT_ENABLED] mainwindow.macro=default")
|
||||
to_chat(src, "Using default macro")
|
||||
else
|
||||
winset(src, null, "input.focus=true input.background-color=[COLOR_INPUT_ENABLED] mainwindow.macro=old_default")
|
||||
to_chat(src, "GOD HECKING HECK HECK")
|
||||
|
||||
Reference in New Issue
Block a user