SeanOMik / TamableFoxes

SpigotMC Plugin that gives you the ability to tame foxes!
MIT License
27 stars 17 forks source link

[Feature] Request support for Folia #96

Closed Q2297045667 closed 1 year ago

Q2297045667 commented 1 year ago

Describe your feature request. https://github.com/PaperMC/Folia

Here is a summary of everything made with ChatGPT to save some time:

For plugin developers, there are a few key takeaways from the given text:

Folia introduces regionised multithreading, which means that plugins will require modification to function properly. Plugin developers should expect compatibility with existing plugins to be at zero.

Folia introduces new API additions, such as the RegionisedScheduler and EntityScheduler, which can help plugins run on the correct thread context.

To ensure compatibility with Folia, plugin developers must mark their plugin as compatible by placing "folia-supported: true" in the plugin.yml file. Additionally, plugins must take advantage of the RegionisedScheduler and EntityScheduler API to ensure correct behavior.

Plugins should not assume that they can access or modify data in other regions, as Folia regions tick in parallel and do not share data. Plugin developers should take advantage of the upcoming thread-check API to ensure correct behavior.

There are currently broken API, including the scoreboard API, and planned API changes, such as super aggressive thread checks, which may impact plugin development.

Overall, plugin developers should be prepared for significant changes in their plugins to ensure compatibility with Folia. They should take advantage of the new API additions and mark their plugin as compatible to ensure correct behavior. Additionally, they should be aware of the limitations and rules of Folia's regionised multithreading to avoid bugs and errors in their plugins.

Additional context no

SeanOMik commented 1 year ago

Folia seems like a cool project by the paper team! However, I don't think I'll be implementing support for it. Folia is meant to be for large servers with hundreds of concurrent players. Folia is recommended to run on a server with 16 cores (not threads) which limits the users running it besides very large servers.

Your message says how plugin devs should expect to rewrite a considerable amount of code

Plugin developers should expect compatibility with existing plugins to be at zero.

Overall, plugin developers should be prepared for significant changes in their plugins to ensure compatibility with Folia.

Supporting Folia would likely require a complete rewrite of the plugin. I'm unsure if there's any reason to do that if most Minecraft servers won't use Folia. This plugin is also pretty much complete, I've really only been maintaining it with the help of some PRs to keep it up to date with Minecraft. Thanks for the request though!