A
Admincraft6mo ago
cal

Lib question

Hi, im in the process of making a library for my new plugins and i was wondering before i get in too deep, are players likely to turn away from a plugin if they see a dependency? Or am i just worrying about nothing?
11 Replies
Admincraft Meta
Admincraft Meta6mo ago
Thanks for asking your question!
Make sure to provide as much helpful information as possible such as logs/what you tried and what your exact issue is
Make sure to mark solved when issue is solved!!!
/close !close !solved !answered
Requested by caldev#0
Skullians
Skullians6mo ago
eh not really anything to worry about I’d say you can either shade the lib into your new plugins or have it as an external provided plugin dependency Plugins like MyWorlds use external dependencies hell, so many plugins use protocollib
cal
calOP6mo ago
i just want to keep plugin size down by making a lib with all my most used methods if that makes sense or would there be no benefit in doing so?
Skullians
Skullians6mo ago
i mean go for it if you’re going to use it across multiple plugins, no point reinventing the wheel
cal
calOP6mo ago
fairs, would it be better to shade it in or have it externally?
Skullians
Skullians6mo ago
whatever you want shading will make the plugin size bigger
gero
gero6mo ago
There is a small library called Libby, which lets you load any dependency at runtime without shading it into the file. Basically the same thing as the library option in spigot 1.16.5 plus, but with support for 1.8 and any maven repo / jar file. https://github.com/AlessioDP/libby
GitHub
GitHub - AlessioDP/libby: A runtime dependency management library f...
A runtime dependency management library for plugins running in Java-based Minecraft server platforms. - AlessioDP/libby
Skullians
Skullians6mo ago
isn’t that literally spigot library loader although spigot library loader only works for maven central afaik
gero
gero6mo ago
Spigot Library Loader is useless for including your own library, because it is highly unlikely you will have the opportunity to upload it to Maven Central. Also, Spigot Library Loader is only available for 1.16.5+.
Skullians
Skullians6mo ago
mmh
gero
gero6mo ago
And as far as I know, Spigot Library Loader does not let you relocate the packages, which could lead to overlapping dependencies, but I'm not that sure on this one.

Did you find this page helpful?