Compare commits

..

2 commits

Author SHA1 Message Date
c22e95af3e
Add a polite notice if you don't have ProtocolLib
All checks were successful
/ deploy (push) Successful in 1m19s
2024-12-13 16:51:20 +01:00
8af95e3ac1
1.21.1 is not *required* 2024-12-13 16:50:34 +01:00
3 changed files with 10 additions and 2 deletions

View file

@ -12,7 +12,8 @@ Please report all suspicious behavior. You can do so on any of those:
Stuff no<sub><sup>t many</sup></sub> other plugins do.
Dependencies:
- **1.21.1**, mandatory as the plugin uses NMS for some stuff\
- **1.21.1**, recommended as the plugin uses NMS for some stuff \
However, it's not forced, so it may work on other versions. If you get an error, it's most often because of a module. Disable that module. \
Why not latest? The focus is on [a widely used version](https://bstats.org/global/bukkit) that has [good mod support](https://modrinth.com/modpack/fabulously-optimized/versions?c=release)
- [ProtocolLib](https://www.spigotmc.org/resources/protocollib.1997/)

View file

@ -34,6 +34,13 @@ public class TweaksPlugin extends MStatsPlugin {
public void onEnable() {
long start = System.nanoTime();
if (getServer().getPluginManager().getPlugin("ProtocolLib") == null) {
getLogger().severe("ProtocolLib is required for this plugin.");
getLogger().severe("https://www.spigotmc.org/resources/protocollib.1997/");
getServer().getPluginManager().disablePlugin(this);
return;
}
TweaksConfig config = TweaksConfig.load(this);
new Language(Locale.US); // TODO

View file

@ -5,7 +5,7 @@ website: https://www.spigotmc.org/resources/tweaks724.121057/
main: eu.m724.tweaks.TweaksPlugin
api-version: 1.21.1
depend: [ProtocolLib]
softdepend: [ProtocolLib]
libraries:
- eu.m724:mstats-spigot:0.1.0