From b05398ec3858a09ff1bdb5f6db3c9bb770fac51a Mon Sep 17 00:00:00 2001 From: syeyoung Date: Tue, 2 Feb 2021 23:06:56 +0900 Subject: MOR EDIT --- .../roomprocessor/GeneralRoomProcessor.java | 9 ------- .../chambers/color/ColorLeftProcessor.java | 4 ++-- .../chambers/color/ColorRightProcessor.java | 28 ---------------------- 3 files changed, 2 insertions(+), 39 deletions(-) diff --git a/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/GeneralRoomProcessor.java b/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/GeneralRoomProcessor.java index 9c646d23..301d60f5 100755 --- a/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/GeneralRoomProcessor.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/GeneralRoomProcessor.java @@ -128,12 +128,6 @@ public class GeneralRoomProcessor implements RoomProcessor { @Override public void onEntitySpawn(LivingEvent.LivingUpdateEvent updateEvent) { - if (updateEvent.entityLiving instanceof EntityArmorStand) { -// updateEvent.entityLiving.setInvisible(false); -// byte b0 = updateEvent.entityLiving.getDataWatcher().getWatchableObjectByte(10); -// b0 = (byte)(b0 & -17); -// updateEvent.entityLiving.getDataWatcher().updateObject(10, Byte.valueOf(b0)); - } } @Override @@ -143,9 +137,6 @@ public class GeneralRoomProcessor implements RoomProcessor { @Override public void onInteract(PlayerInteractEntityEvent event) { - if (event.getEntity() != null && event.getEntity() instanceof EntityArmorStand) { - System.out.println( event.getEntity().getInventory()[4].getTagCompound()); - } } @Override diff --git a/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/bombdefuse/chambers/color/ColorLeftProcessor.java b/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/bombdefuse/chambers/color/ColorLeftProcessor.java index e1881f62..24d18a88 100644 --- a/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/bombdefuse/chambers/color/ColorLeftProcessor.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/bombdefuse/chambers/color/ColorLeftProcessor.java @@ -89,7 +89,7 @@ public class ColorLeftProcessor extends GeneralDefuseChamberProcessor { @Override public void drawWorld(float partialTicks) { super.drawWorld(partialTicks); - RenderUtils.drawTextAtWorld(w1 == null ? "Request Not Received Yet" : "" , center.getX()+ 0.5f, center.getY(), center.getZ()+ 0.5f, 0xFFFFFFFF, 0.03F, false, false, partialTicks); + RenderUtils.drawTextAtWorld(w1 == null ? "Request Not Received Yet" : "Building- "+w1.getLocalizedName() +" / "+w2.getLocalizedName() +" / "+w3.getLocalizedName() , center.getX()+ 0.5f, center.getY(), center.getZ()+ 0.5f, 0xFFFFFFFF, 0.03F, false, false, partialTicks); RenderUtils.drawTextAtWorld(w1 == null ? "null" : w1.getLocalizedName(), b1p.getX()+ 0.5f, b1p.getY() + 0.2f, b1p.getZ()+ 0.5f, 0xFFFFFFFF, 0.03F, false, false, partialTicks); RenderUtils.drawTextAtWorld(w2 == null ? "null" : w2.getLocalizedName(), b2p.getX()+ 0.5f, b2p.getY() + 0.2f, b2p.getZ()+ 0.5f, 0xFFFFFFFF, 0.03F, false, false, partialTicks); @@ -118,7 +118,7 @@ public class ColorLeftProcessor extends GeneralDefuseChamberProcessor { if (!solutionBuilt) return; NBTTagCompound nbt = new NBTTagCompound(); nbt.setByte("a", (byte) 7); - int answer = s1 * 100 + s2 * 10 + s3; + int answer = s1 * 10000 + s2 * 100 + s3; nbt.setInteger("b", answer); getSolver().communicate(nbt); } diff --git a/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/bombdefuse/chambers/color/ColorRightProcessor.java b/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/bombdefuse/chambers/color/ColorRightProcessor.java index 8e094951..f6e1313c 100644 --- a/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/bombdefuse/chambers/color/ColorRightProcessor.java +++ b/src/main/java/kr/syeyoung/dungeonsguide/roomprocessor/bombdefuse/chambers/color/ColorRightProcessor.java @@ -96,34 +96,6 @@ public class ColorRightProcessor extends GeneralDefuseChamberProcessor { return (byte) (!integers.containsKey(str) ? 0 : integers.get(str)); } - private String lastColor = ""; - private ArrayList knownColors = new ArrayList(); - @Override - public void onEntitySpawn(LivingEvent.LivingUpdateEvent updateEvent) { - if (updateEvent.entityLiving instanceof EntityArmorStand) { - try { - ItemStack item = updateEvent.entityLiving.getInventory()[4]; - NBTTagList list = item.getTagCompound().getCompoundTag("SkullOwner").getCompoundTag("Properties").getTagList("textures", 10); - String str = ((NBTTagCompound) list.get(0)).getString("Value"); - - if (!lastColor.equals(str) && !knownColors.contains(str)) { - System.out.println("---------------------"); - System.out.println(str); - System.out.println(str); - knownColors.add(str); - System.out.println(str); - System.out.println("---------------------2"); - for (String str2 : knownColors) { - System.out.println(str2); - } - System.out.println("---------------------3"); - e.sendDebugChat(new ChatComponentText("right processor new color detec")); - } - lastColor = str; - } catch (Exception e) {} - } - } - private static final Map integers = new HashMap(); private static final BiMap colors = HashBiMap.create(); static { -- cgit