Skip to content
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

Unified debug slash command names #19414

Merged
merged 1 commit into from Jun 6, 2021
Merged

Conversation

Mailaender
Copy link
Member

I use the debug chat commands a lot and what annoys me when using tab completion is that they all start with the same redundant word like /show or /debug so there is a high chance it picks the wrong one. This renames all of them to the clear and concise style of #11544 as /exits-overlay makes it clear what it is about and the dash between the nouns helps with readability. It doesn't change them too much so hopefully, so muscle memory stays mostly intact.

Copy link
Member

@abcdefg30 abcdefg30 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm that aside. It might be worth moving those out to string constants to avoid such errors.

OpenRA.Mods.Common/Commands/DebugVisualizationCommands.cs Outdated Show resolved Hide resolved
@pchote
Copy link
Member

pchote commented May 18, 2021

IMO adding a bunch of string constants that are each only used twice isn't a great solution for those files. A better approach would be to define a dictionary of name → (desc, handler) similar to how we do in LobbyCommands.

This brings the same benefits but with significantly less boilerplate.

@Mailaender
Copy link
Member Author

Updated as suggested.

Reorganize dev cheat command handling.
@teinarss teinarss merged commit 3980e4f into OpenRA:bleed Jun 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants