From 79114a90f56dd41e12e037541cb994b59cc7db69 Mon Sep 17 00:00:00 2001 From: CocoTheOwner Date: Thu, 21 Oct 2021 09:24:50 +0200 Subject: [PATCH] Print pregen details --- .../com/volmit/iris/core/commands/CommandPregen.java | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/volmit/iris/core/commands/CommandPregen.java b/src/main/java/com/volmit/iris/core/commands/CommandPregen.java index 03ed016d9..2dfb5ac4e 100644 --- a/src/main/java/com/volmit/iris/core/commands/CommandPregen.java +++ b/src/main/java/com/volmit/iris/core/commands/CommandPregen.java @@ -47,15 +47,18 @@ public class CommandPregen implements DecreeExecutor { sender().sendMessage(C.RED + "Please make sure the world is loaded & the engine is initialized. Generate a new chunk, for example."); } radius = Math.max(radius, 1024); + int w = (radius >> 9 + 1) * 2; IrisToolbelt.pregenerate(PregenTask .builder() .center(new Position2(center)) - .width((radius >> 9 + 1) * 2) - .height((radius >> 9 + 1) * 2) + .width(w) + .height(w) .build(), world); - sender().sendMessage(C.GREEN + "Successfully started the pregeneration task!"); + String msg = C.GREEN + "Pregen started in " + C.GOLD + world.getName() + C.GREEN + " of " + C.GOLD + w + C.GREEN + " by " + C.GOLD + w + C.GREEN + " blocks from " + C.GOLD + center.getX() + "," + center.getZ(); + sender().sendMessage(msg); + Iris.info(msg); } catch (Throwable e) { - sender().sendMessage(C.RED + "Epic fail"); + sender().sendMessage(C.RED + "Epic fail. See console."); Iris.reportError(e); e.printStackTrace(); }