9 Years of SpigotMC | Spigot & BungeeCord 1.18-1.18.2 Release

Discussion in 'News and Announcements' started by md_5, Nov 22, 2021.

  1. Shaggy67


    Did something change with the structure of the JAR for 1.18? When I build spigot-1.18-pre8.jar, there is nothing inside the JAR under org.bukkit anymore, so my IDE says it can't resolve anything. It appears there's a bunch of stuff under the META-INF, but nothing anywhere else?

    Was this an expected change? Do I need to change how I do all of my imports?
  2. md_5

    Administrator Developer

    First of all, use the API, not NMS.
    Second, yes, use Maven/Gradle or pull the jar from the Spigot/Spigot-Server/target/; or extract it out.
  3. 1.18.45234.69 xD (like they did with 1.7.10 before!)
  4. Shaggy67


    I don't use NMS. Normally I would grab the jar file from the root directory of where I build from. I should be grabbing Spigot/Spigot-Server/target/spigot-1.18-pre8-R0.1-SNAPSHOT-bootstrap.jar instead?

    Was I doing it wrong all along, or was this something that changed in 1.18?
  5. Shaggy67


    Looks like that file has the same issue. Is it the spigot-1.18-pre8-R0.1-SNAPSHOT.jar file (without bootstrap) that I need instead?

    Was that changed, IE which ones shows up as spigot-1.18.-pre8.jar in the root directory? Looks like it is the bootstrap one that is showing up there now?
  6. Shaggy67


    Still same problem.


    import org.bukkit.entity.Player;

    Causes this:

    error: package org.bukkit.entity does not exist

    Opening the JAR file with 7zip shows that org/bukkit/entity does not exist.
    #86 Shaggy67, Nov 25, 2021
    Last edited: Nov 25, 2021
  7. md_5

    Administrator Developer

    All the jars / dependencies have now been separated (Mojang calls this 'bundler', we call it bootstrap as you've found out).
    If you don't use NMS you shouldn't really have been using this jar in the first place. Use the API jar (Spigot/Spigot-API/target). There is a -shaded jar there suitable for manual use, but really you should use Maven, gradle, or similar which does all this automatically.
    • Agree Agree x 1
    • Informative Informative x 1
  8. Shaggy67


    OK, thanks. I appreciate the help.
  9. Shaggy67


    Just so I understand...

    Which JAR should I use when running the server?

  10. md_5

    Administrator Developer

    It’s the bootstrap jar which is copied by buildtools to spigot-1.18.jar
  11. Shaggy67


    Perfect, thanks again for the help. I apologize for the dumb questions. I'm definitely old school when it comes to development, was doing everything manually up until now.
  12. Cool! I've been waiting for thisssssssss
  13. I embed my own log4j2.xml file in the Spigot .jar. Where do I put it now?
  14. I wish there was better documentation about development. Because knowing where to look is one thing, figuring it all out while learning the apps and adapting to big changes, I am struggling with it. I miss being 15 and just glancing at something and somehow knowing it all. I hardly retain anything these days. One maven change and nothing i have works as it did before and i spend hours trying to sort it out.

    All these differences with mojang mapping and obfuscation and things being called a() .. and then changing.
    • Agree Agree x 3
  15. [​IMG]

    Thank you md_5 for the amazing product you provide us with <3
  16. You show a picture of it failing to work for you.. and then that comment..

    What's with the sarcasm, what good does that do?

    Works for me with buildtools 138
  17. Same buildtools build, ran java -jar BuildTools.jar --rev 1.18-pre8 --remapped

    Code (Text):
    Loading BuildTools version: git-BuildTools-ec23d73-138 (#138)
    Java Version: Java 17
    Current Path: /e/BuildTools/.
    git version 2.30.2
    OS: Pop OS 21.04 (Linux distro, a ripoff of ubuntu)

    Not running once may be a fluke, not running twice may also be a fluke, but not running three times (each time I cleared the buildtools directory except for the buildtools jar and reran buildtools) and getting the same error is inexcusable.
  18. md_5

    Administrator Developer

    It's a bug, but also running a --remapped jar is not supported except in development. And calling a bug 'inexcusable' is just rude.
    Should be ok in the underlying spigot jar, but why are you embedding it, hasn't there always been a command line option to change it? In fact I just googled for the option and you mentioned it in your own thread 8 years ago! https://bukkit.org/threads/log-file-format-log4j2.209002/
    • Winner Winner x 3
  19. literally unplayable
    • Funny Funny x 1