diff options
| author | jani270 <69345714+jani270@users.noreply.github.com> | 2024-07-06 23:23:13 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-06 23:23:13 +0200 |
| commit | e83b8a597f0983f1de6a6ba0666dfdad359c3d5d (patch) | |
| tree | 0360444259c194688841df4e8f2ad2f21ac2bdea | |
| parent | 1066e4a3a44d585c02132a9b91cd0f6b2940ef22 (diff) | |
| download | notenoughupdates-e83b8a597f0983f1de6a6ba0666dfdad359c3d5d.tar.gz notenoughupdates-e83b8a597f0983f1de6a6ba0666dfdad359c3d5d.tar.bz2 notenoughupdates-e83b8a597f0983f1de6a6ba0666dfdad359c3d5d.zip | |
meta: Add Skyblock check to the NPC Exporter (#1222)
| -rw-r--r-- | src/main/kotlin/io/github/moulberry/notenoughupdates/recipes/generators/NPCLocationExporter.kt | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/main/kotlin/io/github/moulberry/notenoughupdates/recipes/generators/NPCLocationExporter.kt b/src/main/kotlin/io/github/moulberry/notenoughupdates/recipes/generators/NPCLocationExporter.kt index 2b8c99ff..ef989c93 100644 --- a/src/main/kotlin/io/github/moulberry/notenoughupdates/recipes/generators/NPCLocationExporter.kt +++ b/src/main/kotlin/io/github/moulberry/notenoughupdates/recipes/generators/NPCLocationExporter.kt @@ -97,7 +97,7 @@ class NPCLocationExporter { json["z"] = position.z json["island"] = island NotEnoughUpdates.INSTANCE.manager.writeJsonDefaultDir(json, "$id.json") - Utils.addChatMessage("Saved to file") + Utils.addChatMessage("§a[NEU] Saved to file") Minecraft.getMinecraft().displayGuiScreen(null) } @@ -125,15 +125,17 @@ class NPCLocationExporter { @SubscribeEvent fun onMouseClick(event: MouseEvent) { - if (event.buttonstate || event.button != 2 || !NotEnoughUpdates.INSTANCE.config.apiData.repositoryEditing) return + if (event.buttonstate || event.button != 2 || !NotEnoughUpdates.INSTANCE.config.apiData.repositoryEditing || + !NotEnoughUpdates.INSTANCE.hasSkyblockScoreboard() + ) return val location = SBInfo.getInstance().getLocation() if (location == null) { - Utils.addChatMessage("No location found") + Utils.addChatMessage("§c[NEU] No location found") return } val pointedEntity = Minecraft.getMinecraft().pointedEntity if (pointedEntity == null) { - Utils.addChatMessage("Could not find entity under cursor") + Utils.addChatMessage("§e[NEU] Could not find entity under cursor") return } if (pointedEntity is EntityVillager) { @@ -161,14 +163,14 @@ class NPCLocationExporter { ) return } - Utils.addChatMessage("Entity under cursor is not a player") + Utils.addChatMessage("§e[NEU] Entity under cursor is not a player") return } val uuid = pointedEntity.uniqueID val position = pointedEntity.position val skin = pointedEntity.locationSkin.resourcePath?.replace("skins/", "") if (skin == null) { - Utils.addChatMessage("Could not load skin") + Utils.addChatMessage("§c[NEU] Could not load skin") return } Minecraft.getMinecraft().displayGuiScreen(NPCNamePrompt(uuid, position, location, skin)) |
