aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/me/xmrvizzy/skyblocker/skyblock/dungeon/DungeonPuzzles.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/me/xmrvizzy/skyblocker/skyblock/dungeon/DungeonPuzzles.java')
-rw-r--r--src/main/java/me/xmrvizzy/skyblocker/skyblock/dungeon/DungeonPuzzles.java34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/main/java/me/xmrvizzy/skyblocker/skyblock/dungeon/DungeonPuzzles.java b/src/main/java/me/xmrvizzy/skyblocker/skyblock/dungeon/DungeonPuzzles.java
new file mode 100644
index 00000000..3fae82cd
--- /dev/null
+++ b/src/main/java/me/xmrvizzy/skyblocker/skyblock/dungeon/DungeonPuzzles.java
@@ -0,0 +1,34 @@
+package me.xmrvizzy.skyblocker.skyblock.dungeon;
+
+import net.minecraft.client.MinecraftClient;
+import net.minecraft.entity.decoration.ArmorStandEntity;
+import net.minecraft.text.Text;
+import net.minecraft.util.Formatting;
+
+public class DungeonPuzzles {
+
+ public static void threeWeirdos(String message) {
+ MinecraftClient client = MinecraftClient.getInstance();
+ if (client.player == null && client.world == null) return;
+
+ String[] solutions = {
+ "The reward is not in my chest!",
+ "At least one of them is lying, and the reward is not in",
+ "My chest doesn't have the reward. We are all telling the truth.",
+ "My chest has the reward and I'm telling the truth!",
+ "The reward isn't in any of our chests.",
+ "Both of them are telling the truth. Also,"
+ };
+
+ for (String s : solutions) {
+ if (message.contains(s)) {
+ String npc = message.substring(message.indexOf("]") + 4, message.indexOf(":") - 2);
+ client.world.getEntitiesByClass(ArmorStandEntity.class, client.player.getBoundingBox().expand(3), entity -> {
+ if (entity.hasCustomName() && entity.getCustomName().getString().contains(npc))
+ return true;
+ return false;
+ }).forEach(entity -> entity.setCustomName(Text.of(Formatting.GREEN + npc)));
+ }
+ }
+ }
+} \ No newline at end of file