diff options
author | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-12-10 03:11:30 +0100 |
---|---|---|
committer | hannibal2 <24389977+hannibal00212@users.noreply.github.com> | 2023-12-10 03:11:30 +0100 |
commit | 158693dc3fc2605889cde4c981fd0463f1738a9a (patch) | |
tree | 003ad7903f06772d9415f2ce9c6bafbb604b5096 /src/main/java/at | |
parent | 9f1adbac1a07f0102e3ca1d477124f70473a9e33 (diff) | |
download | skyhanni-158693dc3fc2605889cde4c981fd0463f1738a9a.tar.gz skyhanni-158693dc3fc2605889cde4c981fd0463f1738a9a.tar.bz2 skyhanni-158693dc3fc2605889cde4c981fd0463f1738a9a.zip |
Added support for /shworldedit left/right
Diffstat (limited to 'src/main/java/at')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt | 2 | ||||
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/test/WorldEdit.kt | 11 |
2 files changed, 12 insertions, 1 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt b/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt index 77b189589..3dba2e047 100644 --- a/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt +++ b/src/main/java/at/hannibal2/skyhanni/config/commands/Commands.kt @@ -278,7 +278,7 @@ object Commands { "shworldedit", "Select regions in the world", { WorldEdit.command(it) }, - { listOf("copy", "reset", "help") }) + { listOf("copy", "reset", "help", "left", "right") }) registerCommand( "shconfigsave", "Manually saving the config" diff --git a/src/main/java/at/hannibal2/skyhanni/test/WorldEdit.kt b/src/main/java/at/hannibal2/skyhanni/test/WorldEdit.kt index 283698668..8a26e474c 100644 --- a/src/main/java/at/hannibal2/skyhanni/test/WorldEdit.kt +++ b/src/main/java/at/hannibal2/skyhanni/test/WorldEdit.kt @@ -4,6 +4,7 @@ import at.hannibal2.skyhanni.data.ClickType import at.hannibal2.skyhanni.events.BlockClickEvent import at.hannibal2.skyhanni.events.withAlpha import at.hannibal2.skyhanni.utils.ClipboardUtils +import at.hannibal2.skyhanni.utils.LocationUtils import at.hannibal2.skyhanni.utils.LorenzUtils import at.hannibal2.skyhanni.utils.RenderUtils import at.hannibal2.skyhanni.utils.RenderUtils.expandBlock @@ -106,6 +107,16 @@ object WorldEdit { LorenzUtils.chat("Reset selected region") } + "left", "pos1" -> { + leftPos = LocationUtils.playerLocation().toBlockPos() + LorenzUtils.chat("Set left pos.") + } + + "right", "pos2" -> { + leftPos = LocationUtils.playerLocation().toBlockPos() + LorenzUtils.chat("Set right pos.") + } + else -> { LorenzUtils.chat("Unknown subcommand") } |