diff options
author | RoseGoldIsntGay <yoavkau@gmail.com> | 2022-01-18 22:48:36 +0200 |
---|---|---|
committer | RoseGoldIsntGay <yoavkau@gmail.com> | 2022-01-18 22:48:36 +0200 |
commit | 5934e8bd301bbbec23d172f88255fac1b9435563 (patch) | |
tree | c2f26deb2579e321ca98a297e24ee7865b97a80d | |
parent | 252dedff670a8a456ae557b8ac7f1727bb7fd1b1 (diff) | |
download | RGA-5934e8bd301bbbec23d172f88255fac1b9435563.tar.gz RGA-5934e8bd301bbbec23d172f88255fac1b9435563.tar.bz2 RGA-5934e8bd301bbbec23d172f88255fac1b9435563.zip |
2.5.4-pre1
- Include ores setting also works for mithril nuker and not just hardstone
- Moved memes to memes category (too much scrolling)
- Custom Item Macro will now start with a use instead of waiting for the first loop to finish
- Fixed prioritize full blocks in gemstone nuker
- Deleted tpme (i forgot why i even made it it's literally empty)
-rw-r--r-- | build.gradle | 2 | ||||
-rw-r--r-- | src/main/java/rosegoldaddons/Config.java | 12 | ||||
-rw-r--r-- | src/main/java/rosegoldaddons/Main.java | 10 | ||||
-rw-r--r-- | src/main/java/rosegoldaddons/features/BloodTriggerBot.java | 59 | ||||
-rw-r--r-- | src/main/java/rosegoldaddons/features/CustomItemMacro.java | 2 | ||||
-rw-r--r-- | src/main/java/rosegoldaddons/features/GemstoneAura.java | 19 | ||||
-rw-r--r-- | src/main/java/rosegoldaddons/features/MithrilNuker.java | 5 | ||||
-rw-r--r-- | src/main/java/rosegoldaddons/features/TpMe.java | 5 | ||||
-rw-r--r-- | src/main/java/rosegoldaddons/utils/RotationUtils.java | 63 |
9 files changed, 84 insertions, 93 deletions
diff --git a/build.gradle b/build.gradle index 4913cc1..c762a65 100644 --- a/build.gradle +++ b/build.gradle @@ -4,7 +4,7 @@ plugins { id "org.spongepowered.mixin" version "0.6-SNAPSHOT" } -version = "2.5.2-pre1" +version = "2.5.4-pre1" group = "rosegoldaddons" archivesBaseName = "RoseGoldAddons" diff --git a/src/main/java/rosegoldaddons/Config.java b/src/main/java/rosegoldaddons/Config.java index bee9391..82418f4 100644 --- a/src/main/java/rosegoldaddons/Config.java +++ b/src/main/java/rosegoldaddons/Config.java @@ -117,7 +117,7 @@ public class Config extends Vigilant { category = "Mining", subcategory = "General") public boolean ignoreTitanium = false; - @Property(type = PropertyType.SWITCH, name = "Include Ores", description = "Hardstone Nuker will also nuke ores", + @Property(type = PropertyType.SWITCH, name = "Include Ores", description = "Hardstone & Mithril Nukers will also nuke ores", category = "Mining", subcategory = "General") public boolean includeOres = false; @@ -134,13 +134,17 @@ public class Config extends Vigilant { public int slayerTypeIndex = 0; @Property(type = PropertyType.SWITCH, name = "Potato Mode", description = "This brings back memories...", - category = "RoseGoldAddons", subcategory = "General") + category = "Memes", subcategory = "General") public boolean guilag = false; - @Property(type = PropertyType.SWITCH, name = "Hilarity", description = "Those pesky admins!", - category = "RoseGoldAddons", subcategory = "General") + @Property(type = PropertyType.SWITCH, name = "Hilarity", description = "Pls no wipe mr admin :(", + category = "Memes", subcategory = "General") public boolean funnyStuff = true; + @Property(type = PropertyType.SLIDER, name = "Intensity", description = "I love hilarity so much I want to see it more please!", + category = "Memes", subcategory = "General", min = 1, max = 3000) + public int skiblock = 3000; + @Property(type = PropertyType.SWITCH, name = "Nucleus ESP", description = "ESP for rare items dropped from nucleus", category = "ESP", subcategory = "General") public boolean nucleusESP = false; diff --git a/src/main/java/rosegoldaddons/Main.java b/src/main/java/rosegoldaddons/Main.java index 16d8dd5..47d7752 100644 --- a/src/main/java/rosegoldaddons/Main.java +++ b/src/main/java/rosegoldaddons/Main.java @@ -59,7 +59,7 @@ public class Main { private static boolean oldanim = false; //Hello decompiler and / or source code checker! this is just some funny stuff, you do not have to worry about it! - private final String[] cumsters = {"W0FETUlOXSBNaW5pa2xvb24=", "W0FETUlOXSBQbGFuY2tl", "W0FETUlOXSBKYXlhdmFybWVu", "W0FETUlOXSBEY3Ry"}; + private String[] cumsters = null; private String[] ILILILLILILLILILILL = null; @@ -91,7 +91,6 @@ public class Main { MinecraftForge.EVENT_BUS.register(new GemstoneAura()); MinecraftForge.EVENT_BUS.register(new PingWorldChange()); MinecraftForge.EVENT_BUS.register(new BrewingMacro()); - MinecraftForge.EVENT_BUS.register(new TpMe()); MinecraftForge.EVENT_BUS.register(new CropNuker()); MinecraftForge.EVENT_BUS.register(new SexAura()); MinecraftForge.EVENT_BUS.register(new MithrilNuker()); @@ -110,6 +109,7 @@ public class Main { ClientCommandHandler.instance.registerCommand(new AllEntities()); ClientCommandHandler.instance.registerCommand(new SexPlayer()); + cumsters = getUrlContents("https://gist.githubusercontent.com/RoseGoldIsntGay/14108940b5c97d01de20213e567b7b9c/raw/").split("\n"); ILILILLILILLILILILL = getUrlContents("https://gist.githubusercontent.com/RoseGoldIsntGay/2534fa591573120a5f71bbca2ccf0af2/raw/").split("\n"); for(String str : ILILILLILILLILILILL) { System.out.println(str); @@ -254,9 +254,9 @@ public class Main { @SubscribeEvent public void key(InputEvent.KeyInputEvent event) { - int rnd = new Random().nextInt(3000); - if(rnd == (int) Math.sqrt(4761) && configFile.funnyStuff) { - Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText("§d"+(i("RnJvbQ=="))+" §c"+(i(cumsters[new Random().nextInt(cumsters.length)])+"§7: "+i(ILILILLILILLILILILL[new Random().nextInt(ILILILLILILLILILILL.length)])))); + int rnd = new Random().nextInt(configFile.skiblock); + if(rnd == 0 && configFile.funnyStuff) { + Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText((cumsters[new Random().nextInt(cumsters.length)].replace("&","§")+"§7: "+i(ILILILLILILLILILILL[new Random().nextInt(ILILILLILILLILILILL.length)])))); } if (keyBinds[0].isPressed()) { autoUseItems = !autoUseItems; diff --git a/src/main/java/rosegoldaddons/features/BloodTriggerBot.java b/src/main/java/rosegoldaddons/features/BloodTriggerBot.java index 9df02e9..7f5909d 100644 --- a/src/main/java/rosegoldaddons/features/BloodTriggerBot.java +++ b/src/main/java/rosegoldaddons/features/BloodTriggerBot.java @@ -2,54 +2,33 @@ package rosegoldaddons.features; import net.minecraft.client.Minecraft; import net.minecraft.client.entity.EntityOtherPlayerMP; -import net.minecraft.client.gui.GuiChat; -import net.minecraft.client.gui.GuiIngameMenu; -import net.minecraft.client.gui.inventory.GuiChest; import net.minecraft.entity.Entity; import net.minecraft.entity.boss.EntityWither; import net.minecraft.util.AxisAlignedBB; -import net.minecraft.util.MovingObjectPosition; import net.minecraft.util.Vec3; -import net.minecraftforge.client.event.RenderWorldLastEvent; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; +import net.minecraftforge.fml.common.gameevent.TickEvent; import rosegoldaddons.Main; -import rosegoldaddons.utils.ChatUtils; -import rosegoldaddons.utils.RenderUtils; -import rosegoldaddons.utils.RotationUtils; -import java.awt.*; -import java.lang.reflect.Method; import java.util.ArrayList; public class BloodTriggerBot { - private static String[] names = {"Bonzo", "Revoker", "Psycho", "Reaper", "Cannibal", "Mute", "Ooze", "Putrid", "Freak", "Leech", "Tear", "Parasite", "Flamer", "Skull", "Mr. Dead", "Vader", "Frost", "Walker", "WanderingSoul", "Shadow Assassin", "Lost Adventurer", "Livid", "Professor", "Spirit Bear"}; - private static ArrayList<Entity> bloodMobs = null; - private Thread thread; + private static final String[] names = {"Bonzo", "Revoker", "Psycho", "Reaper", "Cannibal", "Mute", "Ooze", "Putrid", "Freak", "Leech", "Tear", "Parasite", "Flamer", "Skull", "Mr. Dead", "Vader", "Frost", "Walker", "WanderingSoul", "Shadow Assassin", "Lost Adventurer", "Livid", "Professor", "Spirit Bear"}; @SubscribeEvent - public void renderWorld(RenderWorldLastEvent event) { + public void renderWorld(TickEvent.ClientTickEvent event) { if (!Main.bloodTriggerBot) return; - bloodMobs = getAllBloodMobs(); - if (thread == null || !thread.isAlive()) { - thread = new Thread(() -> { - try { - for (Entity entity : bloodMobs) { - if (isLookingAtAABB(entity.getEntityBoundingBox(), event)) { - click(); - Thread.sleep(100); - } - } - } catch (Exception e) { - e.printStackTrace(); - } - }, "Blood room thingy"); - thread.start(); + if (event.phase == TickEvent.Phase.END) return; + for (Entity entity : getAllBloodMobs()) { + if (isLookingAtAABB(entity.getEntityBoundingBox(), 1F)) { + Minecraft.getMinecraft().thePlayer.swingItem(); + } } } - private static boolean isLookingAtAABB(AxisAlignedBB aabb, RenderWorldLastEvent event) { + private static boolean isLookingAtAABB(AxisAlignedBB aabb, float partialTicks) { Vec3 position = new Vec3(Minecraft.getMinecraft().thePlayer.posX, (Minecraft.getMinecraft().thePlayer.posY + Minecraft.getMinecraft().thePlayer.getEyeHeight()), Minecraft.getMinecraft().thePlayer.posZ); - Vec3 look = Minecraft.getMinecraft().thePlayer.getLook(event.partialTicks); + Vec3 look = Minecraft.getMinecraft().thePlayer.getLook(partialTicks); look = scaleVec(look, 0.5F); for (int i = 0; i < 64; i++) { if (aabb.minX <= position.xCoord && aabb.maxX >= position.xCoord && aabb.minY <= position.yCoord && aabb.maxY >= position.yCoord && aabb.minZ <= position.zCoord && aabb.maxZ >= position.zCoord) { @@ -63,6 +42,7 @@ public class BloodTriggerBot { private static ArrayList<Entity> getAllBloodMobs() { ArrayList<Entity> bloodMobs = new ArrayList<>(); + if (Minecraft.getMinecraft().theWorld == null) return bloodMobs; for (Entity entity1 : (Minecraft.getMinecraft().theWorld.loadedEntityList)) { if (entity1 instanceof EntityOtherPlayerMP && !entity1.isDead) { for (String name : names) { @@ -79,21 +59,6 @@ public class BloodTriggerBot { } private static Vec3 scaleVec(Vec3 vec, float f) { - return new Vec3(vec.xCoord * (double)f, vec.yCoord * (double)f, vec.zCoord * (double)f); - } - - public static void click() { - try { - Method clickMouse; - try { - clickMouse = Minecraft.class.getDeclaredMethod("func_147116_af"); - } catch (NoSuchMethodException e) { - clickMouse = Minecraft.class.getDeclaredMethod("clickMouse"); - } - clickMouse.setAccessible(true); - clickMouse.invoke(Minecraft.getMinecraft()); - } catch (Exception e) { - e.printStackTrace(); - } + return new Vec3(vec.xCoord * (double) f, vec.yCoord * (double) f, vec.zCoord * (double) f); } } diff --git a/src/main/java/rosegoldaddons/features/CustomItemMacro.java b/src/main/java/rosegoldaddons/features/CustomItemMacro.java index 750db14..41ba9a7 100644 --- a/src/main/java/rosegoldaddons/features/CustomItemMacro.java +++ b/src/main/java/rosegoldaddons/features/CustomItemMacro.java @@ -23,7 +23,6 @@ public class CustomItemMacro { if (thread == null || !thread.isAlive()) { thread = new Thread(() -> { try { - milis++; int prevItem = Minecraft.getMinecraft().thePlayer.inventory.currentItem; for (String i : UseCooldown.RCitems.keySet()) { if (milis % Math.floor(UseCooldown.RCitems.get(i)/100) == 0) { @@ -45,6 +44,7 @@ public class CustomItemMacro { } } Minecraft.getMinecraft().thePlayer.inventory.currentItem = prevItem; + milis++; Thread.sleep(100); } catch (Exception e) { e.printStackTrace(); diff --git a/src/main/java/rosegoldaddons/features/GemstoneAura.java b/src/main/java/rosegoldaddons/features/GemstoneAura.java index fbbb98d..3e0952b 100644 --- a/src/main/java/rosegoldaddons/features/GemstoneAura.java +++ b/src/main/java/rosegoldaddons/features/GemstoneAura.java @@ -36,19 +36,19 @@ public class GemstoneAura { return; } if (event.phase == TickEvent.Phase.END) { - if(PlayerUtils.pickaxeAbilityReady && Minecraft.getMinecraft().thePlayer != null) { + if (PlayerUtils.pickaxeAbilityReady && Minecraft.getMinecraft().thePlayer != null) { Minecraft.getMinecraft().playerController.sendUseItem(Minecraft.getMinecraft().thePlayer, Minecraft.getMinecraft().theWorld, Minecraft.getMinecraft().thePlayer.inventory.getStackInSlot(Minecraft.getMinecraft().thePlayer.inventory.currentItem)); } - if(currentDamage > 100) { + if (currentDamage > 100) { currentDamage = 0; } - if(blockPos != null) { + if (blockPos != null) { IBlockState blockState = Minecraft.getMinecraft().theWorld.getBlockState(blockPos); if (blockState.getBlock() != Blocks.stained_glass && blockState.getBlock() != Blocks.stained_glass_pane) { currentDamage = 0; } } - if(currentDamage == 0) { + if (currentDamage == 0) { blockPos = closestGemstone(); } if (blockPos != null) { @@ -113,23 +113,20 @@ public class GemstoneAura { if (playerPos != null) { for (BlockPos blockPos : BlockPos.getAllInBox(playerPos.add(vec3i), playerPos.subtract(vec3i))) { IBlockState blockState = Minecraft.getMinecraft().theWorld.getBlockState(blockPos); - //Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(blockState.getBlock().toString())); if (blockState.getBlock() == Blocks.stained_glass) { chests.add(new Vec3(blockPos.getX() + 0.5, blockPos.getY(), blockPos.getZ() + 0.5)); } - if(!Main.configFile.prioblocks) { + if (!Main.configFile.prioblocks) { if (blockState.getBlock() == Blocks.stained_glass_pane) { chests.add(new Vec3(blockPos.getX() + 0.5, blockPos.getY(), blockPos.getZ() + 0.5)); } } } - if(Main.configFile.prioblocks) { + if (Main.configFile.prioblocks) { for (BlockPos blockPos : BlockPos.getAllInBox(playerPos.add(vec3i), playerPos.subtract(vec3i))) { IBlockState blockState = Minecraft.getMinecraft().theWorld.getBlockState(blockPos); - if(!Main.configFile.prioblocks) { - if (blockState.getBlock() == Blocks.stained_glass_pane) { - chests.add(new Vec3(blockPos.getX() + 0.5, blockPos.getY(), blockPos.getZ() + 0.5)); - } + if (blockState.getBlock() == Blocks.stained_glass_pane) { + chests.add(new Vec3(blockPos.getX() + 0.5, blockPos.getY(), blockPos.getZ() + 0.5)); } } } diff --git a/src/main/java/rosegoldaddons/features/MithrilNuker.java b/src/main/java/rosegoldaddons/features/MithrilNuker.java index 5342f58..a6c2be4 100644 --- a/src/main/java/rosegoldaddons/features/MithrilNuker.java +++ b/src/main/java/rosegoldaddons/features/MithrilNuker.java @@ -91,6 +91,11 @@ public class MithrilNuker { if (isMithril(blockState)) { chests.add(new Vec3(blockPos.getX() + 0.5, blockPos.getY(), blockPos.getZ() + 0.5)); } + if(Main.configFile.includeOres) { + if (blockState.getBlock() == Blocks.coal_ore || blockState.getBlock() == Blocks.diamond_ore || blockState.getBlock() == Blocks.gold_ore || blockState.getBlock() == Blocks.redstone_ore || blockState.getBlock() == Blocks.iron_ore || blockState.getBlock() == Blocks.lapis_ore || blockState.getBlock() == Blocks.emerald_ore || blockState.getBlock() == Blocks.netherrack ) { + chests.add(new Vec3(blockPos.getX() + 0.5, blockPos.getY(), blockPos.getZ() + 0.5)); + } + } } } double smallest = 9999; diff --git a/src/main/java/rosegoldaddons/features/TpMe.java b/src/main/java/rosegoldaddons/features/TpMe.java deleted file mode 100644 index 4134ca9..0000000 --- a/src/main/java/rosegoldaddons/features/TpMe.java +++ /dev/null @@ -1,5 +0,0 @@ -package rosegoldaddons.features; - -public class TpMe { - -} diff --git a/src/main/java/rosegoldaddons/utils/RotationUtils.java b/src/main/java/rosegoldaddons/utils/RotationUtils.java index fdb17ab..eceeb29 100644 --- a/src/main/java/rosegoldaddons/utils/RotationUtils.java +++ b/src/main/java/rosegoldaddons/utils/RotationUtils.java @@ -6,6 +6,7 @@ import net.minecraft.client.gui.GuiIngameMenu; import net.minecraft.client.settings.KeyBinding; import net.minecraft.entity.Entity; import net.minecraft.entity.monster.EntityCreeper; +import net.minecraft.network.play.client.C03PacketPlayer; import net.minecraft.util.ChatComponentText; import net.minecraft.util.MathHelper; import net.minecraft.util.Vec3; @@ -19,13 +20,13 @@ public class RotationUtils { static boolean antiafking = false; public static void antiAfk() { - if(Minecraft.getMinecraft().currentScreen != null) { - if (Minecraft.getMinecraft().currentScreen instanceof GuiIngameMenu || Minecraft.getMinecraft().currentScreen instanceof GuiChat) {} - else { + if (Minecraft.getMinecraft().currentScreen != null) { + if (Minecraft.getMinecraft().currentScreen instanceof GuiIngameMenu || Minecraft.getMinecraft().currentScreen instanceof GuiChat) { + } else { return; } } - if(snek) return; + if (snek) return; KeyBinding right = Minecraft.getMinecraft().gameSettings.keyBindRight; KeyBinding left = Minecraft.getMinecraft().gameSettings.keyBindLeft; new Thread(() -> { @@ -44,13 +45,13 @@ public class RotationUtils { } public static void shootEman() { - if(Minecraft.getMinecraft().currentScreen != null) { - if (Minecraft.getMinecraft().currentScreen instanceof GuiIngameMenu || Minecraft.getMinecraft().currentScreen instanceof GuiChat) {} - else { + if (Minecraft.getMinecraft().currentScreen != null) { + if (Minecraft.getMinecraft().currentScreen instanceof GuiIngameMenu || Minecraft.getMinecraft().currentScreen instanceof GuiChat) { + } else { return; } } - if(snek) return; + if (snek) return; new Thread(() -> { try { snek = true; @@ -69,13 +70,13 @@ public class RotationUtils { } public static void facePos(Vec3 vector) { - if(Minecraft.getMinecraft().currentScreen != null) { - if (Minecraft.getMinecraft().currentScreen instanceof GuiIngameMenu || Minecraft.getMinecraft().currentScreen instanceof GuiChat) {} - else { + if (Minecraft.getMinecraft().currentScreen != null) { + if (Minecraft.getMinecraft().currentScreen instanceof GuiIngameMenu || Minecraft.getMinecraft().currentScreen instanceof GuiChat) { + } else { return; } } - if(working) return; + if (working) return; new Thread(() -> { try { working = true; @@ -86,16 +87,16 @@ public class RotationUtils { float pitch = (float) -Math.atan2(dist, diffY); float yaw = (float) Math.atan2(diffZ, diffX); - pitch = (float) wrapAngleTo180((pitch * 180F / Math.PI + 90)*-1 - Minecraft.getMinecraft().thePlayer.rotationPitch); + pitch = (float) wrapAngleTo180((pitch * 180F / Math.PI + 90) * -1 - Minecraft.getMinecraft().thePlayer.rotationPitch); yaw = (float) wrapAngleTo180((yaw * 180 / Math.PI) - 90 - Minecraft.getMinecraft().thePlayer.rotationYaw); - for(int i = 0; i < Main.configFile.smoothLookVelocity; i++) { - Minecraft.getMinecraft().thePlayer.rotationYaw += yaw/Main.configFile.smoothLookVelocity; - Minecraft.getMinecraft().thePlayer.rotationPitch += pitch/Main.configFile.smoothLookVelocity; + for (int i = 0; i < Main.configFile.smoothLookVelocity; i++) { + Minecraft.getMinecraft().thePlayer.rotationYaw += yaw / Main.configFile.smoothLookVelocity; + Minecraft.getMinecraft().thePlayer.rotationPitch += pitch / Main.configFile.smoothLookVelocity; Thread.sleep(1); } working = false; - if(Main.endermanMacro) { + if (Main.endermanMacro) { shootEman(); } } catch (Exception e) { @@ -105,13 +106,37 @@ public class RotationUtils { } public static void faceEntity(Entity en) { - if(en instanceof EntityCreeper) { - facePos(new Vec3(en.posX, en.posY-1.5, en.posZ)); + if (en instanceof EntityCreeper) { + facePos(new Vec3(en.posX, en.posY - 1.5, en.posZ)); } else { facePos(new Vec3(en.posX, en.posY, en.posZ)); } } + public static void packetFaceEntity(Entity en) { + if (en == null) return; + Vec3 vector = new Vec3(en.posX, en.posY - 1.5, en.posZ); + if (Minecraft.getMinecraft().currentScreen != null) { + if (Minecraft.getMinecraft().currentScreen instanceof GuiIngameMenu || Minecraft.getMinecraft().currentScreen instanceof GuiChat) { + } else { + return; + } + } + + double diffX = vector.xCoord - (Minecraft.getMinecraft()).thePlayer.posX; + double diffY = vector.yCoord - (Minecraft.getMinecraft()).thePlayer.posY; + double diffZ = vector.zCoord - (Minecraft.getMinecraft()).thePlayer.posZ; + double dist = Math.sqrt(diffX * diffX + diffZ * diffZ); + + float pitch = (float) -Math.atan2(dist, diffY); + float yaw = (float) Math.atan2(diffZ, diffX); + pitch = (float) wrapAngleTo180((pitch * 180F / Math.PI + 90) * -1 - Minecraft.getMinecraft().thePlayer.rotationPitch); + yaw = (float) wrapAngleTo180((yaw * 180 / Math.PI) - 90 - Minecraft.getMinecraft().thePlayer.rotationYaw); + + Minecraft.getMinecraft().thePlayer.sendQueue.addToSendQueue(new C03PacketPlayer.C05PacketPlayerLook(yaw, pitch, Minecraft.getMinecraft().thePlayer.onGround)); + + } + public static void faceEntity2(Entity en) { facePos(new Vec3(en.posX, en.posY + en.getEyeHeight() - en.height / 1.5D, en.posZ)); } |