AlpsBTE / Plot-System

An easy to use building system for the BuildTheEarth project.
https://jenkins.alps-bte.com/job/PlotSystem/
MIT License
20 stars 15 forks source link

[Bug] - [23:06:33 ERROR]: An error occurred while generating plot! #109

Open StoneMcYT opened 2 years ago

StoneMcYT commented 2 years ago

Description

did a flat sel poly like usal and this happens

[23:06:33 INFO]: [WorldGuard] (C-1) TNT ignition is PERMITTED.
[23:06:33 INFO]: [WorldGuard] (C-1) Lighters are PERMITTED.
[23:06:33 INFO]: [WorldGuard] (C-1) Lava fire is blocked.
[23:06:33 INFO]: [WorldGuard] (C-1) Fire spread is UNRESTRICTED.
[23:06:33 INFO]: [WorldGuard] Loaded configuration for world 'C-1'
[23:06:33 INFO]: [VoidGen] {"caves":false,"decoration":false,"mobs":false,"structures":false,"noise":false,"surface":false,"bedrock":false}
[23:06:33 INFO]: [Multiverse-Core] Loading World & Settings - 'C-1' - Env: NORMAL - Type: FLAT & generator: VoidGen:{"caves":false,"decoration":false,"mobs":false,"structures":false}
[23:06:33 ERROR]: An error occurred while generating plot!
java.io.IOException: Plot height is not supported
        at com.alpsbte.plotsystem.core.system.plot.world.CityPlotWorld.getWorldHeight(CityPlotWorld.java:83) ~[?:?]
        at com.alpsbte.plotsystem.core.system.plot.world.CityPlotWorld.getPlotHeight(CityPlotWorld.java:63) ~[?:?]
        at com.alpsbte.plotsystem.core.system.plot.generator.AbstractPlotGenerator.pasteSchematic(AbstractPlotGenerator.java:322) ~[?:?]
        at com.alpsbte.plotsystem.core.system.plot.generator.AbstractPlotGenerator.generateOutlines(AbstractPlotGenerator.java:167) ~[?:?]
        at com.alpsbte.plotsystem.core.system.plot.generator.AbstractPlotGenerator.<init>(AbstractPlotGenerator.java:118) ~[?:?]
        at com.alpsbte.plotsystem.core.system.plot.generator.AbstractPlotGenerator.<init>(AbstractPlotGenerator.java:96) ~[?:?]
        at com.alpsbte.plotsystem.core.system.plot.generator.AbstractPlotGenerator.<init>(AbstractPlotGenerator.java:86) ~[?:?]
        at com.alpsbte.plotsystem.core.system.plot.generator.DefaultPlotGenerator.<init>(DefaultPlotGenerator.java:55) ~[?:?]
        at com.alpsbte.plotsystem.core.system.plot.generator.DefaultPlotGenerator.<init>(DefaultPlotGenerator.java:51) ~[?:?]
        at com.alpsbte.plotsystem.core.menus.companion.CityProjectMenu.lambda$setPaginatedItemClickEventsAsync$9(CityProjectMenu.java:189) ~[?:?]
        at org.ipvp.canvas.MenuFunctionListener.passClickToSlot(MenuFunctionListener.java:251) ~[?:?]
        at org.ipvp.canvas.MenuFunctionListener.passClickToSlot(MenuFunctionListener.java:231) ~[?:?]
        at org.ipvp.canvas.MenuFunctionListener.passClickToSlot(MenuFunctionListener.java:225) ~[?:?]
        at org.ipvp.canvas.MenuFunctionListener.handleGuiClick(MenuFunctionListener.java:156) ~[?:?]
        at com.destroystokyo.paper.event.executor.asm.generated.GeneratedEventExecutor273.execute(Unknown Source) ~[?:?]
        at org.bukkit.plugin.EventExecutor$2.execute(EventExecutor.java:70) ~[patched_1.12.2.jar:git-Paper-1620]
        at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:78) ~[patched_1.12.2.jar:git-Paper-1620]
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) ~[patched_1.12.2.jar:git-Paper-1620]
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:513) ~[patched_1.12.2.jar:git-Paper-1620]
        at net.minecraft.server.v1_12_R1.PlayerConnection.a(PlayerConnection.java:2002) ~[patched_1.12.2.jar:git-Paper-1620]
        at net.minecraft.server.v1_12_R1.PacketPlayInWindowClick.a(SourceFile:33) ~[patched_1.12.2.jar:git-Paper-1620]
        at net.minecraft.server.v1_12_R1.PacketPlayInWindowClick.a(SourceFile:10) ~[patched_1.12.2.jar:git-Paper-1620]
        at net.minecraft.server.v1_12_R1.PlayerConnectionUtils.lambda$ensureMainThread$0(PlayerConnectionUtils.java:14) ~[patched_1.12.2.jar:git-Paper-1620]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:1.8.0_312]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_312]
        at net.minecraft.server.v1_12_R1.SystemUtils.a(SourceFile:46) ~[patched_1.12.2.jar:git-Paper-1620]
        at net.minecraft.server.v1_12_R1.MinecraftServer.D(MinecraftServer.java:850) ~[patched_1.12.2.jar:git-Paper-1620]
        at net.minecraft.server.v1_12_R1.DedicatedServer.D(DedicatedServer.java:423) ~[patched_1.12.2.jar:git-Paper-1620]
        at net.minecraft.server.v1_12_R1.MinecraftServer.C(MinecraftServer.java:774) ~[patched_1.12.2.jar:git-Paper-1620]
        at net.minecraft.server.v1_12_R1.MinecraftServer.run(MinecraftServer.java:666) ~[patched_1.12.2.jar:git-Paper-1620]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_312]
StoneMcYT commented 2 years ago

Interestingly we're too low Y cords of schm (this is in southeastern asia where the ylevels are usually around sealevel for cities/building area)

image

tintinkung commented 2 years ago

for more clarity if this has to do with the plotHeight variable I tried lifting the plot and recreating it, still wont works. is there a new plot-creating function within the new version i may have missed? our old plot from the old version still generates fine tho

XboxBedrock commented 2 years ago

Narrowed it down to this code, this is an application thrown exception, there could have been a much better job at making this clearer

// Plots created below min world height are not supported
if (plotHeight < MIN_WORLD_HEIGHT) throw new IOException("Plot height is not supported");

https://github.com/AlpsBTE/Plot-System/blob/main/src/main/java/com/alpsbte/plotsystem/core/system/plot/world/CityPlotWorld.java#L83

XboxBedrock commented 2 years ago

Move it all below 5

image

https://github.com/AlpsBTE/Plot-System/blob/main/src/main/java/com/alpsbte/plotsystem/core/system/plot/world/PlotWorld.java#L31

XboxBedrock commented 2 years ago

@LordTuxn This doesn't seem like great behavior and there should definitely be a plan to relocate plots vertically in a better way, and check if their Y range < 256 top to bottom and then move min y to 0, seems like a better way to go about it, and for why the min height is 5, no idea?

LordTuxn commented 2 years ago

I wanted to implement it but I totally forgot about it since it wasn't a problem for us. It was only a temporary fix. The idea behind the MinWorldHeight is that the plot will never generate at height 0 or 1 for example, because this is not really what you want for building.

Currently I don't really have time to implement it but I will try to fix it as soon as possible.

StoneMcYT commented 2 years ago

So i suppose ASEAN's plotsystem is down and we are forced to downgrade to a working version? For our bedrock and new builders to be able to build

XboxBedrock commented 2 years ago

I wanted to implement it but I totally forgot about it since it wasn't a problem for us. It was only a temporary fix. The idea behind the MinWorldHeight is that the plot will never generate at height 0 or 1 for example, because this is not really what you want for building.

Currently I don't really have time to implement it but I will try to fix it as soon as possible.

Sounds good! Definitely something to be fixed before the Global Plot System releases but I do understand there are other priorities present.

LordTuxn commented 2 years ago

So i suppose ASEAN's plotsystem is down and we are forced to downgrade to a working version? For our bedrock and new builders to be able to build

Focus Mode and Insirpation Mode should work fine.

StoneMcYT commented 2 years ago

So i suppose ASEAN's plotsystem is down and we are forced to downgrade to a working version? For our bedrock and new builders to be able to build

Focus Mode and Insirpation Mode should work fine.

Tested it these are plots made on the new version but plots made before the upgrade seems to work in focus mode

image

image

The working plot image