CCBlueX Forum

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

    [SCRIPT] BridgeHelper 1.0.0

    Scripts
    9
    14
    987
    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.
    • Vonr
      Vonr last edited by Vonr

      BridgeHelper
      the useless script no one needed

      Using too many unneeded imports and avoiding the usage of any utils and packets, I have managed to make BridgeHelper, aka BlockSpammer, TriggerbotScaffold, and RightClickAutoClickerButWorse.

      Essentially, BridgeHelper will place blocks if and when possible. That's it.

      BridgeHelper Settings:

      - Mode <DEFAULT: Both>
          - Horizontal (TriggerbotScaffold, for flat bridging)
          - Vertical (TriggerbotTower, for towering with arthritis I guess)
          - Both (BlockSpammer, for inclined bridging)
      - Delay <DEFAULT: false>
          - Ticks <DEFAULT: 0>
      - Range <DEFAULT: 4.0 blocks>
      - EnsureAntiGravity <DEFAULT: true>
      

      Download:
      bridgehelper.js

      /// api_version=2
      var script = registerScript({
          name: "BridgeHelper",
          version: "1.0.0",
          authors: ["Qther"]
      });
      
      "use strict";
      
      var Items = Java.type("net.minecraft.init.Items");
      var ItemBlock = Java.type("net.minecraft.item.ItemBlock");
      var Blocks = Java.type("net.minecraft.init.Blocks");
      var BlockFalling = Java.type("net.minecraft.block.BlockFalling");
      var MovingObjectPosition = Java.type("net.minecraft.util.MovingObjectPosition");
      var Material = Java.type("net.minecraft.block.material.Material");
      var Vec3 = Java.type("net.minecraft.util.Vec3");
      var EnumFacing = Java.type("net.minecraft.util.EnumFacing");
      
      var delay = 0;
      var horizontalFaces = [EnumFacing.NORTH, EnumFacing.SOUTH, EnumFacing.EAST, EnumFacing.WEST];
      
      script.registerModule({
          name: "BridgeHelper",
          description: "Automatically places blocks",
          category: "World",
          settings: {
              Mode: Setting.list({
                  name: "Mode",
                  default: "Both",
                  values: ["Horizontal", "Vertical", "Both"]
              }),
              DelayB: Setting.boolean({
                  name: "Delay",
                  default: false
              }),
              Delay: Setting.integer({
                  name: "Ticks",
                  min: 0,
                  max: 20,
                  default: 0
              }),
              Range: Setting.float({
                  name: "Range",
                  min: 0.0,
                  max: 8.0,
                  default: 4.0
              }),
              EnsureNewtonIsNotObeyedByHeldItem: Setting.boolean({
                  name: "EnsureAntiGravity",
                  default: true
              })
          }
      }, function (module) {
          module.on("enable", function () {
              delay = 0;
          });
      
          module.on("disable", function () {
              delay = 0;
          });
      
          module.on("update", function () {
              if (module.settings.DelayB.get() && delay != 0) { // DelayB is true and delay is not 0
                  --delay;
              } 
              else {
                  var heldItemStack = mc.thePlayer.inventory.getCurrentItem();
                  var heldItem = heldItemStack.getItem();
                  var block;
                  if (heldItem instanceof ItemBlock) {
                      var mop = mc.objectMouseOver;
                      
                      if (mop.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK) {
      
                          block = heldItem.block;
                          var blockPos = mop.getBlockPos();
                          var hitSide = mop.sideHit;
                          var blockHit = mc.theWorld.getBlockState(blockPos).getBlock();
                          var hitVec = mop.hitVec;
                          var eyeVec = mc.thePlayer.getPositionEyes(1.0);
                          var isHorizontalFace = horizontalFaces.indexOf(hitSide) != -1;
          
                          if (((module.settings.Mode.get() === "Horizontal" && isHorizontalFace) ||       // Mode is Horizontal and hitSide is horizontal face, or
                                  (module.settings.Mode.get() === "Vertical" && !isHorizontalFace) ||     // Mode is Vertical and hitSide is not horizontal face, or
                                  (module.settings.Mode.get() === "Both")) &&                             // Mode is Both.
      
                              blockHit.getMaterial() != Material.air &&                                   // blockHit's material is not air.
      
                              !(module.settings.EnsureNewtonIsNotObeyedByHeldItem.get() &&                // If EnsureAntiGravity is true,
                                  block instanceof BlockFalling) &&                                       // block is not an instance of BlockFalling.
      
                              eyeVec.distanceTo(hitVec) <= module.settings.Range.get()) {                 // Distance from hitVec to eyeVec is less than Range.
                              
                              if (mc.playerController.onPlayerRightClick(mc.thePlayer, mc.theWorld, heldItemStack, blockPos, hitSide, hitVec)) {
                                  mc.thePlayer.swingItem();
                                  //mc.rightClickDelayTimer = module.settings.Delay.get();
                                  delay = module.settings.Delay.get(); // Reset delay
                              }
                          }
                          delay = module.settings.Delay.get(); // Reset delay
                      }
                  }
              }
          });
      });
      
      G 1 Reply Last reply Reply Quote 1
      • scorpion3013
        scorpion3013 Moderator last edited by

        How about you submit your script to the script website? https://liquidbounce.net/scripts/

        1 Reply Last reply Reply Quote 1
        • Vonr
          Vonr last edited by

          dont exactly have a suitable image to go with it

          Foreheadchan_ A exit scammed 3 Replies Last reply Reply Quote 0
          • G
            Gabriel @Vonr last edited by

            @vonr Nice.

            1 Reply Last reply Reply Quote 0
            • Foreheadchan_
              Foreheadchan_ @Vonr last edited by

              @vonr said in [SCRIPT] BridgeHelper 1.0.0:

              dont exactly have a suitable image to go with it

              you WANT an image?

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

                @vonr 12a1c8ae-0083-4815-b4a7-8575184fa02d-image.png

                1 Reply Last reply Reply Quote 0
                • exit scammed
                  exit scammed @Vonr last edited by

                  @vonr 1ab04ab1-7a89-445e-a3bf-ddd0f80bca35-image.png

                  Vonr 1 Reply Last reply Reply Quote 0
                  • Vonr
                    Vonr @exit scammed last edited by

                    lmao what

                    exit scammed 1 Reply Last reply Reply Quote 0
                    • exit scammed
                      exit scammed @Vonr last edited by

                      @vonr randomly asking google for an image of "bridge helper"

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

                        piece of art, right

                        Untitled.png

                        Vonr END3R1355 2 Replies Last reply Reply Quote 2
                        • Vonr
                          Vonr @mems last edited by

                          @mems absolutely, the script is kinda outdated though because I've made it too op to release lol.

                          Vonr 1 Reply Last reply Reply Quote 0
                          • Vonr
                            Vonr @Vonr last edited by

                            turns out liquidbounce.net hates me and doesn't allow me to login

                            1 Reply Last reply Reply Quote 0
                            • END3R1355
                              END3R1355 Banned @mems last edited by

                              @mems did u draw it

                              if so then u have cool drawing skills

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

                                @e-nder1355 necropost hehe

                                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