-
Notifications
You must be signed in to change notification settings - Fork 84
feat: add Brigadier support to Paper #427
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
base: master
Are you sure you want to change the base?
Conversation
This commit turned out a bit bigger than I would've wanted. Here is a list of changes: - added the Brigadier dependency to common - moved Brigadier command creation to common (used fabric as a template) - replaced the individual fabric/forge/neoforge Brigadier command implementations with the common impl - split ChunkyBukkit into AbstractChunkyBukkit for common logic, ChunkyBukkit for Spigot only, and ChunkyPaper for Paper only - added Paper Brigadier command implementation for the Paper plugin - added paper-plugin.yml to support this change
common/src/main/java/org/popcraft/chunky/command/suggestion/PatternSuggestionProvider.java
Outdated
Show resolved
Hide resolved
common/src/main/java/org/popcraft/chunky/command/suggestion/ShapeSuggestionProvider.java
Outdated
Show resolved
Hide resolved
common/src/main/java/org/popcraft/chunky/command/suggestion/SuggestionProviders.java
Outdated
Show resolved
Hide resolved
common/src/main/java/org/popcraft/chunky/command/suggestion/TrimModeSuggestionProvider.java
Outdated
Show resolved
Hide resolved
common/src/main/java/org/popcraft/chunky/command/brigadier/BrigadierChunkyCommand.java
Outdated
Show resolved
Hide resolved
common/src/main/java/org/popcraft/chunky/command/brigadier/BrigadierChunkyCommand.java
Outdated
Show resolved
Hide resolved
| name: ${name} | ||
| version: ${version} | ||
| main: ${group}.chunky.ChunkyBukkit | ||
| api-version: 1.21 |
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.
| api-version: 1.21 | |
| api-version: 1.21.1 |
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.
I am like 99% certain that version does not exist. api-version: 1.21 had something weird going on where it only started accepting "minor" version from like .5.
Or I am mistaking it for 1.20, in which case please call me out.
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.
The minor version being usable in the api-version was added in 1.20.5
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.
Okay, good to know, I was convinced it was 1.21. Too many versions 😂
| } | ||
| } | ||
|
|
||
| public Chunky getChunky() { |
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.
What's the purpose of shifting some methods and fields around in the ChunkyBukkit/BukkitPlayer/BukkitWorld classes? It seems to only create extra diff and confuse the git blame for the future
| } | ||
| } | ||
| } | ||
| } |
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.
re-add the newline at the end of file to reduce diff
This PR does a few things:
In order to achieve this, it split the Bukkit plugin main class into two classes, each with their accompanying (paper-)plugin.yml and own command handling.