-
-
Notifications
You must be signed in to change notification settings - Fork 285
use verb macro for defining some admin verbs + realias tg ones #7508
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
LetterN
wants to merge
3
commits into
Citadel-Station-13:master
Choose a base branch
from
LetterN:verbify-all
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 2 commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 hidden or 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,40 @@ | ||
| // Re-aliased tg defines | ||
| #define ADMIN_VERB(verb_path_name, verb_permissions, verb_name, verb_desc, verb_category, verb_args...) \ | ||
| _ADMIN_VERB_DEF_INTERNAL(verb_path_name, verb_permissions, verb_name, verb_desc, verb_category, FALSE, ##verb_args) | ||
|
|
||
| #define ADMIN_VERB_ONLY_CONTEXT_MENU(verb_path_name, verb_permissions, verb_name, verb_args...) \ | ||
| _ADMIN_VERB_DEF_INTERNAL(verb_path_name, verb_permissions, verb_name, ADMIN_VERB_NO_DESCRIPTION, ADMIN_CATEGORY_HIDDEN, TRUE, ##verb_args) | ||
|
|
||
| #define ADMIN_VERB_AND_CONTEXT_MENU(verb_path_name, verb_permissions, verb_name, verb_desc, verb_category, verb_args...) \ | ||
| _ADMIN_VERB_DEF_INTERNAL(verb_path_name, verb_permissions, verb_name, verb_desc, verb_category, TRUE, ##verb_args) | ||
|
|
||
| /* | ||
| * This is an example of how to use the above macro: | ||
| * ``` | ||
| * ADMIN_VERB(name_of_verb, R_ADMIN, "Verb Name", "Verb Desc", "Verb Category", mob/target in world) | ||
| * to_chat(user, "Hello!") | ||
| * ``` | ||
| * Note the implied `client/user` argument that is injected into the verb. | ||
| * Also note that byond is shit and you cannot multi-line the macro call. | ||
| */ | ||
|
|
||
| /// Use this to mark your verb as not having a description. Should ONLY be used if you are also hiding the verb! | ||
| #define ADMIN_VERB_NO_DESCRIPTION "" | ||
| /// Used to verbs you do not want to show up in the master verb panel. | ||
| #define ADMIN_CATEGORY_HIDDEN null | ||
|
|
||
| // Admin verb categories | ||
| #define ADMIN_CATEGORY_MAIN "Admin" | ||
| #define ADMIN_CATEGORY_EVENTS "Events" | ||
| #define ADMIN_CATEGORY_FUN "Fun" | ||
| #define ADMIN_CATEGORY_GAME "Game" | ||
| #define ADMIN_CATEGORY_SHUTTLE "Shuttle" | ||
|
|
||
| // Special categories that are separated | ||
| #define ADMIN_CATEGORY_DEBUG "Debug" | ||
| #define ADMIN_CATEGORY_SERVER "Server" | ||
| #define ADMIN_CATEGORY_OBJECT "Object" | ||
| #define ADMIN_CATEGORY_MAPPING "Mapping" | ||
| #define ADMIN_CATEGORY_PROFILE "Profile" | ||
| #define ADMIN_CATEGORY_IPINTEL "IPIntel" | ||
|
|
||
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't realias macros if it just does the same thing
for context only just add a def that just nulls it
also, there's no need to replace the verb categories unless we're going to get a statpanel that doesn't treat them as verbs; they're all verbs internally, thus they are verb categories.
stuff like profile/ipintel should not be their own tabs, statpanel if needed should just parse the category like
Category.Subcategoryor somethingrest of PR is fine but this is duplicate
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
license
also category is just a rename