8000 Paper CommandAPI by DerEchtePilz · Pull Request #517 · CommandAPI/CommandAPI · GitHub
[go: up one dir, main page]

Skip to content

Paper CommandAPI #517

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

Merged
merged 18 commits into from
Jun 24, 2025
Merged

Paper CommandAPI #517

merged 18 commits into from
Jun 24, 2025

Conversation

DerEchtePilz
Copy link
Member
@DerEchtePilz DerEchtePilz commented Jan 19, 2024

This PR refactors parts of the CommandAPI so the Adventure library and Bungee library aren't used in the same .jar's anymore and Paper API and Spigot API also aren't used together anymore.
In order to do that, commandapi-bukkit-core only serves as a tool to access NMS so it can be shared and doesn't have to be implemented again for Paper and Spigot.
The new usable platforms are commandapi-paper-(core/shade/plugin) and commandapi-spigot-(core/shade/plugin).

This still requires a lot of work. I am fairly confident that these changes should already make a fairly functional CommandAPI for Paper and Spigot, however, there still is a lot of work left.

This should also invalidate #474 as this refactor puts them into different modules

TODO's:

  • Potentially come up with API to make use of Paper's Brigadier API. That would include:
    • No namespace handling for commands like these
    • Automatic plugin association
    • Probably would require changes to how commands are built or separate API that would make this easier
  • Update build script
  • Remove PaperImplementations.java
  • Work through CommandAPIBukkit and implement in CommandAPIPaper and CommandAPISpigot respectively.
  • Add Kotlin modules for Spigot and Paper (Component related arguments)
  • Make commandapi-annotations platform specific (Component related arguments)
  • Update documentation code to include at least a platform that provides component related arguments
  • Update tests to use CommandAPIPaper or CommandAPISpigot. Maybe even both, share tests and implement component related arguments for both platforms Nope, cancelling those. The original tests are still present but they won't work. After trying to port tests two times I do not really know what to do so if someone else at some point, possibly after this is merged, has an idea this could and should be implemented.
  • Update Velocity, apparently
  • Deal with The CommandAPI should use MinecraftServer#getCommands instead of MinecraftServer.vanillaCommandDispatcher #406 for the Paper-specific version
  • Make sure the minecraft namespace exists for commands on Paper
  • Documentation and changelog
  • Test Minecraft versions with the plugin only, shade version and non-shade version:
    • 1.16.5
    • 1.17
    • 1.17.1
    • 1.18, 1.18.1
    • 1.18.2
    • 1.19
    • 1.19.1, 1.19.2
    • 1.19.3
    • 1.19.4
    • 1.20, 1.20.1
    • 1.20.2
    • 1.20.3/4
    • 1.20.5/6 (On Paper, use the CommandAPI using commandapi-paper-shade-mojang-mapped)
    • 1.21 (On Paper, use the CommandAPI using commandapi-paper-shade-mojang-mapped)

@DerEchtePilz DerEchtePilz mentioned this pull request Jan 19, 2024
2 tasks
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch 2 times, most recently from 46558a5 to 9babcd2 Compare February 9, 2024 20:48
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch from bfbe182 to c5d49e1 Compare March 30, 2024 09:24
@DerEchtePilz DerEchtePilz linked an issue Mar 30, 2024 that may be closed by this pull request
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch from 4dba32a to 9f28b25 Compare March 30, 2024 13:12
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch 2 times, most recently from b088d05 to a93af70 Compare April 11, 2024 15:10
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch 5 times, most recently from 18e8c28 to f80d789 Compare May 7, 2024 18:49
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch from 36ca865 to acda2d1 Compare May 9, 2024 20:37
DerEchtePilz added a commit that referenced this pull request May 12, 2024
+ fixed exception appearing in server log, this isn't done with VarHandles but I think because this is a hotfix, it is fine for now.
I will handle all this properly on dev/commandapi-paper and #517
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch 7 times, most recently from f9a99ef to c357912 Compare May 14, 2024 13:17
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch from a81dd6b to 66db468 Compare May 29, 2024 15:44
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch 2 times, most recently from 40805bc to 8ea52a7 Compare May 20, 2025 15:27
@DerEchtePilz DerEchtePilz linked an issue Jun 2, 2025 that may be closed by this pull request
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch 2 times, most recently from 20daccf to 62f3317 Compare June 3, 2025 18:57
Copy link
Collaborator
@willkroboth willkroboth left a comment

Choose a reason for hiding this comment

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

Just some thoughts. It looks like the docs PR has some catching up to do.

@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch 2 times, most recently from 2469dd2 to 1772c26 Compare June 23, 2025 23:39
@DerEchtePilz DerEchtePilz force-pushed the dev/commandapi-paper branch from c98e516 to 970491e Compare June 24, 2025 00:11
@DerEchtePilz DerEchtePilz merged commit d22e28c into dev/dev Jun 24, 2025
4 checks passed
@DerEchtePilz DerEchtePilz mentioned this pull request Jun 24, 2025
6 tasks
@DerEchtePilz DerEchtePilz deleted the dev/commandapi-paper branch June 26, 2025 22:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants
0