-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Automatic Input Redirection The map element will now yield to the command bar for Classic input. The game will inform you of any macros not applied. It will also report extra stuff, I'll fix it later. * Tighten things up Player Panel reports input mode * Protected Macros * More macro magic * hate, let me tell you about hate let me tell you how much I've come to hate SSInput and TG's decisions since I began to stare into this code. There are roughly five hundred lines of code split across 15 files that power the keyloop. If the word hate were to replace every mere bit of every character of these hundreds of lines, it would not equal one one-billionth of the hate I feel for this system at this micro-instant. Hate. Hate. * Allows silencing the bad hotkey warning The code is inherently imperfect. * Proper multimacro * Update code/_compile_options.dm * Prevent Doublestriking keys * Remove unnecessary failsafe
- Loading branch information
Showing
24 changed files
with
299 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
/datum/keybinding/client | ||
category = CATEGORY_CLIENT | ||
weight = WEIGHT_HIGHEST | ||
|
||
|
||
/datum/keybinding/client/admin_help | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
/* | ||
* Macro Test Tools | ||
* I wrote these in a fit of agony because debugging the skin is an actual feat of self-flagelation | ||
* Some of them aren't useful, and were just part of me discovering what crimes TG does to the skin. | ||
* | ||
* dump_macroset_ids(): | ||
* * Dumps all elements of type macros (which are macrosets, according to the ref, but they contain macros. It's confusing, right?) | ||
* * This isn't particularly useful. It should almost always return just "default" | ||
* | ||
* dump_set(): | ||
* * Dumps the contents of the "default" macroset, Which is all currently bound macros, by name, essentially listing all bound macro handles. | ||
* | ||
* arbitrary_winget(cmd as text): | ||
* * A way to quickly run wingets, and get the output, since the debugger no likey sleepy procs. | ||
* | ||
* arbitrary_winset(cmd as text): | ||
* * Same as above, but for winsets. | ||
* | ||
* focuswatch(): | ||
* * Prints the current element with focus, this can be null if something else in the OS has focus outside of BYOND. Useful for seeing where the ball is | ||
* * in the demented juggling act TG decided was worth playing. | ||
* | ||
* winmon(cmd as text|null): | ||
* * Derived from focuswatch's code, it repeatedly runs the same winset on loop, dumping the output to chat, Useful for watching for the results | ||
* * of custom winsets. | ||
*/ | ||
|
||
#ifdef MACRO_TEST | ||
#warn !!UNSAFE!!: MacroTest Verbs Enabled, Do Not Merge. | ||
/client | ||
var/x_mt_watchingfocus = FALSE | ||
var/x_mt_winmon_enabled = FALSE | ||
var/list/x_mt_winmon_packet //Lazylist | ||
|
||
/// Dumps the list of all macros. This should almost always be just default | ||
/client/verb/dump_macroset_ids() | ||
set name = "mt Dump Macroset IDs" | ||
set category = "_MACRO_TEST" | ||
to_chat(usr, (winget(src, "", "macros") || "NULL (Bad. Incredibly. Incredibly bad.)")) | ||
|
||
/// List all children of default. Name for macros is their bound key. | ||
/client/verb/dump_set() | ||
set name = "mt Dump bindings" | ||
set category = "_MACRO_TEST" | ||
to_chat(usr, (winget(src, "default.*" , "name")|| "NULL (Bad. Real bad.)")) | ||
|
||
/// A slightly more pleasant way to execute free wingets. | ||
/client/verb/arbitrary_winget(cmd as text) | ||
set name = "awing" | ||
set desc = "Run an arbitrary Winset call, Space-separated arguments." | ||
set category = "_MACRO_TEST" | ||
var/list/parts = splittext(cmd, " ") | ||
to_chat(usr, (winget(src, parts[1], parts[2]) || "NULL (Bad Call?)")) | ||
|
||
/// A slightly more pleasant way to execute free winsets. | ||
/client/verb/arbitrary_winset(cmd as text) | ||
set name = "aswin" | ||
set desc = "Run an arbitrary Winset call, Space-separated arguments." | ||
set category = "_MACRO_TEST" | ||
var/list/parts = splittext(cmd, " ") | ||
winset(src, parts[1], parts[2]) | ||
to_chat(usr, ("CALLED: winset({client:[src.ckey]}, \"[parts[1]]\",\"[parts[2]]\")")) | ||
|
||
/// Will dump the currently focused skin element to chat. Used for tracking down focus juggling issues. | ||
/client/verb/focuswatch() | ||
set name = "mt toggle focus watch" | ||
set category = "_MACRO_TEST" | ||
if(x_mt_watchingfocus) | ||
x_mt_watchingfocus = FALSE | ||
return | ||
else | ||
x_mt_watchingfocus = TRUE | ||
while(x_mt_watchingfocus) | ||
// Live-report the element with focus. | ||
to_chat(usr, (winget(src, "", "focus") || "NULL (Entire game defocused?)")) | ||
sleep(0.5 SECONDS) //Every half second | ||
|
||
/client/verb/winmon(cmd as text|null) | ||
set name = "winmon" | ||
set desc = "Repeatedly run a winget to monitor it's value" | ||
set category = "_MACRO_TEST" | ||
if(x_mt_winmon_enabled || isnull(cmd)) | ||
x_mt_winmon_enabled = FALSE | ||
return | ||
else | ||
x_mt_winmon_enabled = TRUE | ||
var/list/parts = splittext(cmd, " ") | ||
x_mt_winmon_packet = parts | ||
while(x_mt_winmon_enabled) | ||
// Repeatedly rerun the same winget to watch the value | ||
var/winout = winget(src, x_mt_winmon_packet[1], x_mt_winmon_packet[2]) | ||
to_chat(usr, ( winout ? "WINMON:[winout]": "WINMON: NULL (Bad Call?)")) | ||
sleep(0.5 SECONDS) | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.