From d1c1efe7534f0a34219c29d49daf8c7c6dce8412 Mon Sep 17 00:00:00 2001 From: William278 Date: Thu, 8 Sep 2022 11:48:12 +0300 Subject: [PATCH 1/3] Load chunks via PaperLib asynchronously --- .../src/main/java/net/william278/huskhomes/BukkitHuskHomes.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bukkit/src/main/java/net/william278/huskhomes/BukkitHuskHomes.java b/bukkit/src/main/java/net/william278/huskhomes/BukkitHuskHomes.java index 4c638183..b2fedea9 100644 --- a/bukkit/src/main/java/net/william278/huskhomes/BukkitHuskHomes.java +++ b/bukkit/src/main/java/net/william278/huskhomes/BukkitHuskHomes.java @@ -421,7 +421,7 @@ public class BukkitHuskHomes extends JavaPlugin implements HuskHomes { } // Find a safe position and return - PaperLib.getChunkAtAsync(bukkitLocation).thenAccept(chunk -> + PaperLib.getChunkAtAsync(bukkitLocation).thenAcceptAsync(chunk -> future.complete(BukkitSafetyUtil.findSafeLocation(location.world, bukkitLocation, chunk.getChunkSnapshot()))).exceptionally(throwable -> { throwable.printStackTrace(); From 8e75a8dbdc05930acc6902ed385dbd655934dcf9 Mon Sep 17 00:00:00 2001 From: William278 Date: Thu, 8 Sep 2022 12:58:42 +0300 Subject: [PATCH 2/3] Fix back command using random teleport pricing --- .../java/net/william278/huskhomes/command/BackCommand.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/src/main/java/net/william278/huskhomes/command/BackCommand.java b/common/src/main/java/net/william278/huskhomes/command/BackCommand.java index 7b5286ac..d7aa0abb 100644 --- a/common/src/main/java/net/william278/huskhomes/command/BackCommand.java +++ b/common/src/main/java/net/william278/huskhomes/command/BackCommand.java @@ -22,9 +22,9 @@ public class BackCommand extends CommandBase { } // Teleport the player - plugin.getTeleportManager().timedTeleport(onlineUser, position, Settings.EconomyAction.RANDOM_TELEPORT) + plugin.getTeleportManager().timedTeleport(onlineUser, position, Settings.EconomyAction.BACK_COMMAND) .thenAccept(result -> plugin.getTeleportManager() - .finishTeleport(onlineUser, result, Settings.EconomyAction.RANDOM_TELEPORT)); + .finishTeleport(onlineUser, result, Settings.EconomyAction.BACK_COMMAND)); }, () -> plugin.getLocales().getLocale("error_no_last_position").ifPresent(onlineUser::sendMessage))); } From 9c9bd720a75ba51b225a46c40a6652b3ab76d689 Mon Sep 17 00:00:00 2001 From: William278 Date: Thu, 8 Sep 2022 13:00:19 +0300 Subject: [PATCH 3/3] Bump to 3.0.2 --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index a05d95ab..3e7c456d 100644 --- a/gradle.properties +++ b/gradle.properties @@ -3,7 +3,7 @@ org.gradle.jvmargs='-Dfile.encoding=UTF-8' org.gradle.daemon=true javaVersion=16 -plugin_version=3.0.1 +plugin_version=3.0.2 plugin_archive=huskhomes jedis_version=4.2.3