CCBlueX Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups

    Hello brothers, I made a regen script to test on the server allowed Hack but there is a problem that does not appear in the clickgui

    Scripts
    11
    33
    1003
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • I
      ItzHackzz last edited by

      var scriptName = "RegenNew";
      var scriptVersion = 1.0;
      var scriptAuthor = "ItzHackz";

      var ClientUtils = Java.type("net.minecraft.util.ClientUtils");
      var onUpdate = Java.type("net.minecraft.update.onUpdate");
      var Block = Java.type("net.minecraft.block.Block");
      var BlockAir = Java.type("net.minecraft.block.BlockAir");
      var BlockHopper = Java.type("net.minecraft.block.BlockHopper");
      var C03PacketPlayer = Java.type("net.minecraft.network.play.client.C03PacketPlayer");
      var Potion = Java.type("net.minecraft.potion.Potion");
      var AxisAlignedBB = Java.type("net.minecraft.util.AxisAlignedBB");
      var BlockPos = Java.type("net.minecraft.util.BlockPos");
      var MathHelper = Java.type("net.minecraft.util.MathHelper");

      function regen() {
      Health = value.createFloat('Health', 20, 1, 20);
      this.addValues = function(values) {
      values.add(Health);
      };
      this.getName = function() {
      return "RegenNew";
      };

      this.getDescription = function() {
          return "Test.";
      };
      
      this.getCategory = function() {
          return "Combat";
      };
      
      var packets = 5.0;
      var potionPackets = 8.5;
      var health = 9.9;
      var potion = true;
      
      
      this.onUpdate = function() {
          var i;
          if (this.potion) {
              if (ClientUtils.player().getActivePotionEffect(Potion.regeneration) != null && ClientUtils.player().getActivePotionEffect(Potion.regeneration).getDuration() > 0 && ClientUtils.player().getHealth() <= this.health * 2.0 && (ClientUtils.player().isCollidedVertically || this.isInsideBlock()) && event.getState().equals(State.POST)) {
                  for(i = 0; i < this.potionPackets; ++i) {
                      ClientUtils.player().getActivePotionEffect(Potion.regeneration).deincrementDuration();
                      ClientUtils.packet(new C03PacketPlayer(true));
                  }
              }
          } else if (ClientUtils.player().getHealth() <= this.health * 2.0 && (ClientUtils.player().isCollidedVertically || this.isInsideBlock()) && event.getState().equals(State.POST)) {
              for(i = 0; i < this.packets; ++i) {
                  ClientUtils.packet(new C03PacketPlayer(true));
              }
          }
      
      }
      
      function isInsideBlock() {
          for(var x = MathHelper.floor_double(ClientUtils.player().boundingBox.minX); x < MathHelper.floor_double(ClientUtils.player().boundingBox.maxX) + 1; ++x) {
              for(var y = MathHelper.floor_double(ClientUtils.player().boundingBox.minY); y < MathHelper.floor_double(ClientUtils.player().boundingBox.maxY) + 1; ++y) {
                  for(var z = MathHelper.floor_double(ClientUtils.player().boundingBox.minZ); z < MathHelper.floor_double(ClientUtils.player().boundingBox.maxZ) + 1; ++z) {
                      var block = ClientUtils.world().getBlockState(new BlockPos(x, y, z)).getBlock();
                      if (block != null && !(block instanceof BlockAir)) {
                          var boundingBox = block.getCollisionBoundingBox(ClientUtils.world(), new BlockPos(x, y, z), ClientUtils.world().getBlockState(new BlockPos(x, y, z)));
                          if (block instanceof BlockHopper) {
                              boundingBox = new AxisAlignedBB(x, y, z, (double)(x + 1), (double)(y + 1), (double)(z + 1));
                          }
                          if (boundingBox != null && ClientUtils.player().boundingBox.intersectsWith(boundingBox)) {
                              return true;
                          }
                      }
                  }
              }
          }
          return false;
      }
      
      function onLoad() {}
      
      function onEnable() {
          client = moduleManager.registerModule(regen);
      }
      
      function onDisable() {
          moduleManager.unregisterModule(client);
      }
      

      }

      1 Reply Last reply Reply Quote 0
      • Leejames2305
        Leejames2305 last edited by Leejames2305

        Stop claiming you 'coded' it when you just pasting the code from .class into .js without properly learning how to code.

        *Stop trying already, we all know that you are @Maeyse even though you change to a different forum account.

        hahayes I 3 Replies Last reply Reply Quote 1
        • hahayes
          hahayes @Leejames2305 last edited by hahayes

          @ItzHackzz epic code, love liquidbounce users who are skilled just like you

          @leejames2305 who is maeyse lol

          M 1 Reply Last reply Reply Quote 0
          • M
            mems Moderator @hahayes last edited by

            @hahayes a guy who wanted the exact same thing as the OP wants.

            1 Reply Last reply Reply Quote 0
            • I
              ItzHackzz @Leejames2305 last edited by

              @leejames2305 mayese? I do not know who it is

              DreamWasFucked 1 Reply Last reply Reply Quote 0
              • DreamWasFucked
                DreamWasFucked Banned @ItzHackzz last edited by

                @itzhackzz @Maeyse

                Maeyse 1 Reply Last reply Reply Quote 0
                • I
                  ItzHackzz @Leejames2305 last edited by

                  @leejames2305 James how can I get the class to just play to become JS? I tried to make this script in vs code on a regen crest basis

                  hahayes 1 Reply Last reply Reply Quote 0
                  • Maeyse
                    Maeyse @DreamWasFucked last edited by

                    @skidma Hi got the script?

                    hahayes 1 Reply Last reply Reply Quote 0
                    • hahayes
                      hahayes @ItzHackzz last edited by

                      @itzhackzz learn scriptapi

                      1 Reply Last reply Reply Quote 0
                      • hahayes
                        hahayes @Maeyse last edited by

                        Capture.PNG

                        @ItzHackzz 😳

                        I A 2 Replies Last reply Reply Quote 0
                        • I
                          idk last edited by

                          trash:axoblush: :axoangry: :axoangry:

                          1 Reply Last reply Reply Quote 0
                          • I
                            ItzHackzz @hahayes last edited by

                            @hahayes and man, what has to do with that? I still do not understand

                            I 1 Reply Last reply Reply Quote 0
                            • I
                              ItzHackzz @ItzHackzz last edited by

                              This post is deleted!
                              1 Reply Last reply Reply Quote 0
                              • A
                                Aftery last edited by

                                pov: turkish post

                                hahayes 1 Reply Last reply Reply Quote 0
                                • hahayes
                                  hahayes @Aftery last edited by

                                  @aftery what did he post

                                  A M 2 Replies Last reply Reply Quote 0
                                  • A
                                    Aftery @hahayes last edited by

                                    @hahayes dont remember dont care

                                    hahayes 1 Reply Last reply Reply Quote 0
                                    • M
                                      mems Moderator @hahayes last edited by

                                      @hahayes He posted some code.

                                      hahayes I 2 Replies Last reply Reply Quote 0
                                      • hahayes
                                        hahayes @Aftery last edited by

                                        @aftery rude

                                        A 1 Reply Last reply Reply Quote 0
                                        • hahayes
                                          hahayes @mems last edited by

                                          @mems thanks for proper response

                                          1 Reply Last reply Reply Quote 0
                                          • A
                                            Aftery @hahayes last edited by

                                            @hahayes yeah yeah hold on there ill get back to u when i finish in ur mom

                                            hahayes 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post
                                            About
                                            • Terms of Service
                                            • Privacy Policy
                                            • Status
                                            • Contact Us
                                            Downloads
                                            • Releases
                                            • Source code
                                            • License
                                            Docs
                                            • Tutorials
                                            • CustomHUD
                                            • AutoSettings
                                            • ScriptAPI
                                            Community
                                            • Forum
                                            • Guilded
                                            • YouTube
                                            • Twitter
                                            • D.Tube