BreweryTeam / BreweryX

An actively maintained, support given, and addon supported fork of Brewery with tons of extra features.
https://discord.gg/3FkNaNDnta
GNU General Public License v3.0
58 stars 21 forks source link

Folia Error, BreweryX v3.3.0 #41

Closed GoodrichDev closed 1 month ago

GoodrichDev commented 2 months ago
[03:57:13 INFO]: [Brewery] Minecraft version: 1.21
[03:57:13 INFO]: [Brewery] DataManager created: FlatFile
[03:57:13 ERROR]: Error occurred while enabling BreweryX v3.3.0 (Is it up to date?)
java.lang.NullPointerException: Cannot read field "captureTreeGeneration" because the return value of "net.minecraft.world.level.World.getCurrentWorldData()" is null
        at net.minecraft.world.level.Level.getBlockState(Level.java:1311) ~[?:?]
        at org.bukkit.craftbukkit.block.CraftBlock.getType(CraftBlock.java:244) ~[?:?]
        at BreweryX-3.3.0.jar/com.dre.brewery.BarrelBody.getBrokenBlock(BarrelBody.java:255) ~[BreweryX-3.3.0.jar:?]
        at BreweryX-3.3.0.jar/com.dre.brewery.BarrelBody.regenerateBounds(BarrelBody.java:238) ~[BreweryX-3.3.0.jar:?]
        at BreweryX-3.3.0.jar/com.dre.brewery.BarrelBody.<init>(BarrelBody.java:44) ~[BreweryX-3.3.0.jar:?]
        at BreweryX-3.3.0.jar/com.dre.brewery.Barrel.<init>(Barrel.java:106) ~[BreweryX-3.3.0.jar:?]
        at BreweryX-3.3.0.jar/com.dre.brewery.storage.impls.FlatFileStorage.getBarrel(FlatFileStorage.java:70) ~[BreweryX-3.3.0.jar:?]
        at BreweryX-3.3.0.jar/com.dre.brewery.storage.impls.FlatFileStorage.getAllBarrels(FlatFileStorage.java:83) ~[BreweryX-3.3.0.jar:?]
        at BreweryX-3.3.0.jar/com.dre.brewery.BreweryPlugin.onEnable(BreweryPlugin.java:163) ~[BreweryX-3.3.0.jar:?]
        at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:288) ~[paper-mojangapi-1.21.1-R0.1-SNAPSHOT.jar:?]
        at io.papermc.paper.plugin.manager.PaperPluginInstanceManager.enablePlugin(PaperPluginInstanceManager.java:202) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.enablePlugin(PaperPluginManagerImpl.java:109) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:520) ~[paper-mojangapi-1.21.1-R0.1-SNAPSHOT.jar:?]
        at org.bukkit.craftbukkit.CraftServer.enablePlugin(CraftServer.java:646) ~[?:?]
        at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:595) ~[?:?]
        at net.minecraft.server.MinecraftServer.loadWorld0(MinecraftServer.java:780) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at net.minecraft.server.MinecraftServer.loadLevel(MinecraftServer.java:527) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at net.minecraft.server.dedicated.DedicatedServer.initServer(DedicatedServer.java:329) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1281) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:357) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at java.base/java.lang.Thread.run(Thread.java:1583) ~[?:?]
[03:57:13 INFO]: [BreweryX] Disabling BreweryX v3.3.0
[03:57:13 INFO]: [Brewery] Closed connection from: FlatFileStorage
[03:57:13 INFO]: [Brewery] BreweryX disabled!
GoodrichDev commented 1 month ago
Folia Version 1.21.1-DEV on 1.21.1-R0.1-SNAPSHOT
GoodrichDev commented 1 month ago

@Jsinco this error has made BreweryX unloadable Any help would be great.

Jsinco commented 1 month ago

Update your BreweryX and try it out on Folia stable (1.21)

GoodrichDev commented 1 month ago

Will do, I was forking just now to see if I could track down the issue and fix it myself. I'll update here shortly. Could I add you on discord? georgeorwells1984

GoodrichDev commented 1 month ago

@Jsinco

[23:27:08 INFO]: [BreweryX] Enabling BreweryX v3.3.2
[23:27:08 INFO]: [Brewery] Minecraft version: 1.21
[23:27:08 INFO]: [Brewery] DataManager created: FlatFile
[23:27:08 ERROR]: Error occurred while enabling BreweryX v3.3.2 (Is it up to date?)
java.lang.NullPointerException: Cannot read field "captureTreeGeneration" because the return value of "net.minecraft.world.level.World.getCurrentWorldData()" is null
        at net.minecraft.world.level.Level.getBlockState(Level.java:1311) ~[?:?]
        at org.bukkit.craftbukkit.block.CraftBlock.getType(CraftBlock.java:244) ~[?:?]
        at BreweryX-3.3.2.jar/com.dre.brewery.BarrelBody.getBrokenBlock(BarrelBody.java:255) ~[BreweryX-3.3.2.jar:?]
        at BreweryX-3.3.2.jar/com.dre.brewery.BarrelBody.regenerateBounds(BarrelBody.java:238) ~[BreweryX-3.3.2.jar:?]
        at BreweryX-3.3.2.jar/com.dre.brewery.BarrelBody.<init>(BarrelBody.java:44) ~[BreweryX-3.3.2.jar:?]
        at BreweryX-3.3.2.jar/com.dre.brewery.Barrel.<init>(Barrel.java:106) ~[BreweryX-3.3.2.jar:?]
        at BreweryX-3.3.2.jar/com.dre.brewery.storage.impls.FlatFileStorage.getBarrel(FlatFileStorage.java:70) ~[BreweryX-3.3.2.jar:?]
        at BreweryX-3.3.2.jar/com.dre.brewery.storage.impls.FlatFileStorage.getAllBarrels(FlatFileStorage.java:83) ~[BreweryX-3.3.2.jar:?]
        at BreweryX-3.3.2.jar/com.dre.brewery.BreweryPlugin.onEnable(BreweryPlugin.java:163) ~[BreweryX-3.3.2.jar:?]
        at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:288) ~[paper-mojangapi-1.21.1-R0.1-SNAPSHOT.jar:?]
        at io.papermc.paper.plugin.manager.PaperPluginInstanceManager.enablePlugin(PaperPluginInstanceManager.java:202) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.enablePlugin(PaperPluginManagerImpl.java:109) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:520) ~[paper-mojangapi-1.21.1-R0.1-SNAPSHOT.jar:?]
        at org.bukkit.craftbukkit.CraftServer.enablePlugin(CraftServer.java:646) ~[?:?]
        at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:595) ~[?:?]
        at net.minecraft.server.MinecraftServer.loadWorld0(MinecraftServer.java:780) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at net.minecraft.server.MinecraftServer.loadLevel(MinecraftServer.java:527) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at net.minecraft.server.dedicated.DedicatedServer.initServer(DedicatedServer.java:329) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1281) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:357) ~[folia-1.21.1.jar:1.21.1-DEV-bfa3106]
        at java.base/java.lang.Thread.run(Thread.java:1583) ~[?:?]
[23:27:08 INFO]: [BreweryX] Disabling BreweryX v3.3.2
[23:27:08 INFO]: [Brewery] Closed connection from: FlatFileStorage
[23:27:08 INFO]: [Brewery] BreweryX disabled!
Jsinco commented 1 month ago

Use a stable release of folia

GoodrichDev commented 1 month ago

I do have a stable release, it was one I was advised to use by the Paper team? They won't be publishing releases and require builds to be made yourself. My folia build has been incredible stable, it seems this part of Brewery isn't code for Folia Support for 1.21?

Jsinco commented 1 month ago

1.21.1, as far as I can tell, is a dev branch

GoodrichDev commented 1 month ago

https://github.com/EarthPol/BreweryX/commit/d4a98ae31ef33200f9badf890e1cc13b61599a2b

This seems to have fixed my issue